I would like to include and use this category in my project (lets call it target project). While I want to learn about categories in general, I do need help including the category specified in the link. I haven’t done this before so I need detailed instructions addressing the four questions and any other essential information:
- After I copy the project into my Xcode do I need to run it?
- In my target project do I need to include it as a library or include it some other way?
- What needs to go in my target project class header file?
- What needs to go in my target project implementation file?
If you are using a static library, which I don’t believe you are, all of your dependencies must be compiled using the
-all_loadlinker flag (see Technical Q&A QA1490Building Objective-C static libraries with categories, or else you will run into the ‘Unknown Selector’ issue.
Other than that, you simply include the
.hand.m(or .h and .a in the case of a static library) files of the category, and all frameworks that may be required by the category, and you move on with your project.