开发者

Is it possible to create private property in Objective-C?

开发者 https://www.devze.com 2023-01-15 11:25 出处:网络
Is it possible to create private property in Objective-C? I do know that a kind of private property functionalit开发者_StackOverflow社区y could be implemented in another way but I\'m interested in par

Is it possible to create private property in Objective-C? I do know that a kind of private property functionalit开发者_StackOverflow社区y could be implemented in another way but I'm interested in particular question. Thanks.


Yes, you can, but the code will looks a little bit strange. And it will only give you some warning if you call, you have to check for the warnings yourself

in your implementation file .m

@interface YourObject ()

@property (nonatomic, retain) NSMutableArray *infoArray;

@end
0

精彩评论

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