>Are methods considered "overloaded" if they return different types?
Not as far as I know, the parameters control whether they are overloaded.
>Maybe another way to do this is to have one method that returns a basic Object that could then be cast to the appropriate type after it is returned.
There do seem to be a few solutions to this, I have kind of stepped back from my original goal now and have got a working solution, however, my main goal was to be able to call overloaded methods and governing the return type by passing the type as a parameter.
Kev
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement