Hi everyone
I have a configuration class in my objective-c app which reads a PLIST file with configuration data. I would then like to be able to read the value for any key with a single function, something like this:
- () getValueforKey:(NSString *)key {
some magic here....
return value;
}
The issue: Some of the values in the config file are Strings, others are ints or even Dictionaries. As you can see I left the return-type blank in this example as I do not know what to write there. Is there any way that a function can return different types of data, and if so, how do I declare this?
Thanks a lot!