Versions des environnements
AFAIK, the return type is part of the signature of a method and cannot change. However, it could return an object. In that object, you would have the 4 responses types and a flag to tell which one to use.
HTH
>I would like to write one method that takes one parameter, based on the data contained in that parameter I would like that method to return a variable with one of 4 possible datatypes.
>Is this impossible?
>How can I work around it?
Précédent
Suivant
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