MOA Developer's Guide
MOA Interfaces | MOA Methods | MOA Types and Misc API
IMoaCallback
Interface ID: IID_IMoaCallback
Pointer type: PIMoaCallback
Inheritance: IMoaUnknown
Header file: moaxtra.h
Description
-
-
This standard MOA interface is implemented by the application's
callback object for the use of Xtras. It provides methods for
accessing other interfaces belonging to the application, for acquiring
and releasing resources for use by the Xtra, for accessing the
application cache, and for creating instances of MOA classes and
interfaces. All MOA objects have an instance variable, pCallback,
that refers to this interface of the application's callback object.
Methods
Creating an instance
-
- MoaCreateInstance()
Getting a cache
-
- MoaGetCache()
Using Resources
-
- MoaBeginUsingResources()
MoaEndUsingResources()
Syntax
-
- MoaBeginUsingResources(PIMoaCallbackThis,
MoaFileReffileRef,
XtraResourceCookie FAR *pSaveCookie)
Parameters
-
This
- Pointer to the
IMoaCallback
interface
fileRef
MoaFileRef
File reference
pSaveCookie
XtraResourceCookie FAR *
Resource cookie for the
file
Returns
-
- XtraResourceCookie
Description
-
- Opens, if necessary, and returns an identifier for the resources
in the file represented by fileRef. When it opens your Xtra, MOA
creates the global gXtraFileRef to refers to your Xtra's file
(global within the namespace of your Xtra). Pass this global as
the fileRef parameter. The parameter pSaveCookie returns a reference
to the resource file to use in calling the method MoaEndUsingResources().
Syntax
-
- MoaCreateInstance(PIMoaCallback This,
-
ConstPMoaClassID pClassID,
ConstPMoaInterfaceID pInterfaceID,
PPMoaVoid ppvOb)
Parameters
-
This
- Pointer to the
IMoaCallback
interface
pClassID
ConstPMoaClassID
CLSID for the class being instantiated
pInterfaceID
ConstPMoaInterfaceID
IID for the interface being
instantiated
ppvOb
PPMoaVoid
Pointer to interface of type pInterfaceID
Returns
-
MoaError
Description
-
- Create and initialize an object of the class with CLSID pClassID,
and return a pointer to the interface with IID pInterfaceID. MOA
will choose the class and interface from the correct Xtra, and
return a pointer to the interface in ppUnknown. In the event of
duplicate class ID's, the Xtra containing the most recent version
will be used (according to the information provided when the Xtra
is loaded).
Syntax
-
- MoaEndUsingResources(PIMoaCallbackThis,
MoaFileReffileRef,
XtraResourceCookiesaveCookie)
Parameters
-
This
- Pointer to the
IMoaCallback
interface
fileRef
MoaFileRef
File reference
saveCookie
XtraResourceCookie
Resource cookie for the file
Returns
-
- void
Description
-
- Closes the resource file represented by fileRef and previously
opened with the MoaBeginUsingResources() method.
Syntax
-
- MoaGetCache(PIMoaCallbackThis)
Parameters
-
This
- Pointer to the
IMoaCallback
interface
Returns
-
- IMoaCache Applications
interface
Description
-
- Call this method to access the application cache from within your Xtra.
Copyright © 1995-2007 Adobe Macromedia Software LLC, Inc.