开发者

Accessing an NSMutableArray in another class from a class

What would be the best way to access an NSMutableArray and its associated objects from within a开发者_开发知识库 different class? Should I write accessor methods to return the components I need or can I somehow assign a pointer to it from within the class I need to access it from?


this is pretty dependent upon the situation. I personally favor properties for stuff like this. You can just declare an @property, and then @synthesize it in the implementation file. Very little code.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜