iphone - Objective-C when to declare what methods in @interface -
when , methods should declared in @interface
section of class? understand, methods describe class should declared in @interface
section, other "helper" methods should not declared. correct understanding side?
you should add methods .h file when want external class have access (public methods).
when they're private (only used internally class) put them in .m file.
anyway, it's pattern. objective-c works messages, if don't set method in .h file external file can access it, @ least auto-complete won't show it.
Comments
Post a Comment