![]() |
AEDisposeToken |
||||
Header: | AEObjects.h | Carbon status: | Supported | |
Deallocates the memory used by a token.
OSErr AEDisposeToken ( AEDesc *theToken );
A pointer to the token to dispose of. On successful return, the pointer is set to the null descriptor.
A result code.
Your application calls the AEResolve function to resolve an object specifier record, with the help of the object accessor functions described in Object Accessor Callbacks and the application object callback functions described in Object Callback Functions.
When AEResolve returns a final token to your event handler as the result of the resolution of an object specifier record, your application must deallocate the memory used by the token. When your application calls the AEDisposeToken function, the Apple Event Manager first calls your applications token disposal function, if you have provided one. The token disposal function is described in OSLDisposeTokenProcPtr.
If you havent provided a token disposal function, or if your applications token disposal function returns errAEEventNotHandled as the function result, the Apple Event Manager calls the system token disposal function if one is available. If there is no system token disposal function or the function returns errAEEventNotHandled as the function result, the Apple Event Manager calls the AEDisposeDesc function to dispose of the token.
A Carbon application should not install an object callback function in a system object accessor dispatch table with the goal that the function will get called when other applications access objectsthis wont necessarily work. See Apple Event Dispatching (to be supplied later) for more information.
Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.
© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)