Apple Developer Connection
Member Login Log In | Not a Member? Contact ADC

Next Page > Hide TOC

Introduction to Resource Programming Guide

Contents:

Organization of This Document
See Also


Applied to computer programs, resources are data files that accompany a program’s executable code. You can use resources to simplify the job of programming and also to reduce the amount of time it takes to develop your applications. Instead of programmatically creating images or the controls associated with your user interface, you can create resource files that contain the data for those items. When loaded at runtime, the resource-loading routines use the data in the resource file to create the objects or data structures your code requested.

Resources are also an intimate part of the internationalization process for Mac OS X applications. Rather than hard-coding strings and other user-visible content in your application, you should place that content in external resource files. Localizing your application then becomes a simple process of creating a new copy of those resource files for each supported language and dropping them inside the appropriate directories in your application bundle. The Mac OS X bundle organization makes sure that the resources your application requests match the language preferences of the current user.

This document provides information about the types of resources supported in Mac OS X applications and how you use those resources in your code. This document does not focus on the resource-creation process. Most resources are created using either third-party applications or the developer tools provided in the /Developer/Applications directory. Although this document focuses on the use of resources in bundled applications, most of the information also applies to other types of Mac OS X packages, such as frameworks and plug-ins.

Before reading this document, you should be familiar with the organizational structure imposed by application bundles. Understanding this structure makes it easier to organize and find the resource files your application uses. For information on the structure of bundles, see Bundle Programming Guide.

Organization of This Document

This document includes the following chapters:

See Also

The following ADC Reference Library documents are conceptually related to Resource Programming Guide:



Next Page > Hide TOC


Last updated: 2007-09-04




Did this document help you?
Yes: Tell us what works for you.

It’s good, but: Report typos, inaccuracies, and so forth.

It wasn’t helpful: Tell us what would have helped.
Get information on Apple products.
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Copyright © 2007 Apple Inc.
All rights reserved. | Terms of use | Privacy Notice