Important: The information in this document is obsolete and should not be used for new development.
Chapter 5 - Collection Manager
This chapter describes the Collection Manager, which provides an abstract data type you can use to store collections of information. Read this chapter if you need to work with some advanced features of QuickDraw GX printing, including print dialog boxes, or if you want to create collections for purposes specific to your application.Before reading this chapter, you might want to familiarize yourself with the information in the chapter "Resource Manager" in Inside Macintosh: More Macintosh Toolbox. For some examples of how the Collection Manager is used by other parts of QuickDraw GX, you should read the chapter "Page Formatting and Dialog Box Customization" in Inside Macintosh: QuickDraw GX Printing.
This chapter introduces the collection object as an abstract data type and describes the properties of this object. It then shows how to use the functions provided by the Collection Manager to
This chapter also contains reference information for all data types, functions, and resources associated with the Collection Manager.
- create and manipulate collection objects
- add information to a collection object
- retrieve information from a collection object
- store a collection object to disk and retrieve a collection object from disk
Chapter Contents
- About the Collection Manager
- Collection Objects
- Collection Items
- Collection Attributes
- Methods of Identifying Collection Items
- Using the Collection Manager
- Determining Whether the Collection Manager Is Available
- Creating or Disposing of a Collection
- Cloning or Copying a Collection
- Changing the Default Attributes of a Collection
- Adding Items to a Collection
- Determining the Collection Index of an Item
- Determining the Tag and ID of an Item
- Determining the Size of an Item's Variable-Length Data
- Getting and Setting the Attributes of an Item
- Replacing Items in a Collection
- Removing Items From a Collection
- Retrieving the Variable-Length Data From an Item
- Examining the Collection Tags of a Collection
- Flattening and Unflattening a Collection
- Reading Collections From and Writing Collections to Disk
- Reading a Collection From a Collection Resource
- Installing an Exception Procedure
- Collection Manager Reference
- Data Types
- Collection Objects
- Collection Tags
- Optional Return Value Constants
- Attributes Masks
- Attribute Bit Numbers
- Attribute Bit Masks
- Functions
- Creating and Disposing of Collection Objects
- Cloning and Copying Collection Objects
- Getting and Setting the Exception Procedure for a Collection
- Getting and Setting the Default Attributes for a Collection
- Adding and Replacing Items in a Collection
- Removing Items From a Collection
- Counting Items in a Collection
- Retrieving the Variable-Length Data From an Item
- Getting Information About a Collection Item
- Editing Item Attributes
- Getting Information About Collection Tags
- Flattening and Unflattening a Collection
- Working With Macintosh Memory Manager Handles
- Reading Collections From Resource Files
- Application-Defined Functions
- Resources
- The Collection Resource
- Summary of the Collection Manager
- Data Types
- Optional Return Value Constants
- Attributes Masks
- Attribute Bit Numbers
- Attribute Bit Masks
- Functions
- Creating and Disposing of Collection Objects
- Cloning and Copying Collection Objects
- Getting and Setting the Exception Procedure for a Collection
- Getting and Setting the Default Attributes for a Collection
- Adding and Replacing Items in a Collection
- Removing Items From a Collection
- Counting Items in a Collection
- Retrieving the Variable-Length Data From an Item
- Getting Information About a Collection Item
- Editing Item Attributes
- Getting Information About Collection Tags
- Flattening and Unflattening a Collection
- Working With Macintosh Memory Manager Handles
- Reading Collections From Resource Files
- Application-Defined Functions
- Resources
- The Collection Resource