问题
I see @package a lot in Apple's header files, but for the life of me, I can't find an authoritative source that describes its meaning.
回答1:
@package is a scope declaration for a particular class member. There are four:
@public: Accessible everywhere.@protected: Accessible within the class that defines it and inheriting classes.@private: Accessible within the class that defines it.@package: In 64-bit, like@public, but only within the same framework; in 32-bit, identical to@public.
See this developer doc for more information.
来源:https://stackoverflow.com/questions/1345571/what-is-the-package-compiler-directive-for-in-cocoa