Important: The information in this document is obsolete and should not be used for new development.
Routines for ComponentsThis section describes the Component Manager routines that are used by components. It also discusses routines a component or application can use to register a component. This section first describes the routines for registering components then describes the routines that allow your component to
Note that version 3 and above of the Component Manager supports automatic version control, the unregister request, and icon families. You should test the version number before using any of these features. You can use the
- extract the parameters from a component parameters record and invoke a subroutine of your component with these parameters
- manage open connections
- associate storage with a specific connection
- pass error information to the Component Manager for later use by the calling application
- store and retrieve your component's reference constant
- open and close its resource file
- call other components
- capture other components
- target a component instance
Gestaltfunction with the
gestaltComponentMgrselector to do this. When you specify this selector,
Gestaltreturns in the
responseparameter a 32-bit value indicating the version of the Component Manager that is installed.
If you are developing an application that uses components but does not register them, you do not have to read this material, though it may be interesting to you. For a discussion of the Component Manager routines that support applications that use components, see "Routines for Applications" beginning on page 6-39.
If you are developing an application that registers components, you should read the next section, "Registering Components." You may also find the other topics in this section interesting.
If you are developing a component, you should read this entire section. For more information about creating components, see "Creating Components" beginning on page 6-12.
Several of the routines discussed in this section use the component parameters record. For a complete description of that structure, see "Data Structures for Components" beginning on page 6-50. For information on the distinction between component identifiers and component instances, see page 6-38.
- Any of the routines discussed in this section that require a component identifier also accept a component instance. Similarly, you can supply a component identifier to any routine that requires a component instance (except for the
DelegateComponentCallfunction). If you do this, you must always coerce the data type appropriately. For more information, see "Component Identifiers and Component Instances" on page 6-38.
- Registering Components
- Dispatching to Component Routines
- Managing Component Connections
- Setting Component Errors
- Working With Component Reference Constants
- Accessing a Component's Resource File
- Calling Other Components
- Capturing Components
- Targeting a Component Instance
- Changing the Default Search Order