Possible Duplicate:
Objective C Equivalent of PHP’s “Variable Variables”
I have created a method in objective C which looks like this:
- (void) startBuildingXArray: (NSMutableArray *) arrayName:(int) senderID;
BUT, here is the tricky part. The particular arrayName argument depends on what the senderID is. Specifically, each arrayName has a number at the end of it (i.e. array1, array2, etc.) that matches the senderID in this method. Is there a way to dynamically add in an integer to the end of array name as a parameter? Or an entirely different and better way to yield the same result?
In other words, what I want to create is this sort of a situation:
- (void) startBuildingXArray: (NSMutableArray *) arrayName+(senderID):(int) senderID;
Of course that is not in any way valid code, I'm just trying to demonstrate what I want to happen. Can anyone suggest any sort of solution?