Treating instances of an interface type as a different subclass