Introduction to Framework Programming Guide
OS X makes extensive use of frameworks to distribute shared code and resources, such as the interfaces to the system itself. You can create frameworks of your own to provide shared code and resources to one or more of your company’s applications. You can also create frameworks containing class libraries or add-on modules with the intention of distributing them to other developers.
The information in this document provides the background you need to create frameworks and the steps needed to create them in Xcode. Although creating frameworks is not difficult, there are some guidelines you should follow when doing so. Xcode simplifies the creation process by helping you create the framework bundle and manage the information and placement of files in that bundle. However, this document also provides additional information about how to perform many less obvious tasks.
Organization of This Document
This document contains the following articles:
What are Frameworks? provides background information about what frameworks are and how they’re used.
Anatomy of Framework Bundles describes the basic structure of frameworks, including umbrella frameworks.
Framework Versions describes the system used to manage different framework versions and how you specify version information when you create a framework.
Frameworks and Binding explains how framework symbols are bound to an application at runtime. It also explains how to improve the load time of your framework through the use of prebinding.
Frameworks and Weak Linking explains the concept of “weak-linking” for framework symbols and shows you how to use this feature with both your own frameworks and third-party frameworks.
Guidelines for Creating Frameworks provides guidelines on the best practices to use for creating frameworks.
Creating a Framework shows how to create public frameworks and private embedded frameworks using Xcode.
Initializing a Framework at Runtime shows how to create a load-time initialization routine for your framework.
Exporting Your Framework Interface shows how to limit the symbols exported by your framework to the exact set you want.
Installing Your Framework explains the conventions for where to install your custom frameworks.
Including Frameworks shows the basic ways to use frameworks in applications.