Reputation: 5510
I have a method that returns a NSMutableArray.. I am calling this method from another class and I would like to know how to put the returning NSMutableArray into a receiving object thats in the class thats called it.
myClass.m
- (NSMutableArray *)getMutableArray
{
// Do some stuff
return myMutableArray
}
mycallingClass.m
- (void)getMeMyMutableArray {
// not really sure what to do here.. but something like.....
// initialize class
myClass *mc = [[myClass alloc] init];
// call myClass method
[mc getMutableArray]; // how do I get the returning value into a mutableArray in this class?
}
Hopefully this makes sense.. Any help would be appreciated
Upvotes: 0
Views: 56