InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
SCScriptProvider Class Reference
Inheritance diagram for SCScriptProvider:
CScriptProviderCPMUnknown< IScriptProvider >IScriptProviderIPMUnknown

Public Member Functions

 SCScriptProvider (IPMUnknown *boss)
 
 ~SCScriptProvider ()
 
virtual ErrorCode HandleMethod (ScriptID methodID, IScriptRequestData *data, IScript *parent)
 
virtual ErrorCode AccessProperty (ScriptID propID, IScriptRequestData *data, IScript *parent)
 

Additional Inherited Members

- Public Types inherited from IScriptProvider
enum  { kDefaultIID = IID_ISCRIPTPROVIDER }
 
- Protected Types inherited from CScriptProvider
typedef CPMUnknown
< IScriptProvider
Inherited
 
- Protected Member Functions inherited from CScriptProvider
 CScriptProvider (IPMUnknown *boss)
 
virtual void GetObject (IScriptRequestData *data, IScript *parent)
 
virtual void HandleMethodOnObjects (ScriptID methodID, IScriptRequestData *data, const ScriptList &scriptList)
 
virtual void AccessPropertyOnObjects (ScriptID propID, IScriptRequestData *data, const ScriptList &scriptList)
 
virtual void AccessProperties (IScriptRequestData *data, IScript *script)
 
virtual ErrorCode PreAccessProperty (ScriptID propID, IScriptRequestData *data, IScript *script)
 
virtual ErrorCode PostAccessProperty (ScriptID propID, IScriptRequestData *data, IScript *script)
 
virtual ErrorCode PreAccessProperties (IScriptRequestData *data, IScript *script)
 
virtual ErrorCode PostAccessProperties (IScriptRequestData *data, IScript *script)
 
virtual ErrorCode AccessParent (ScriptID propID, IScriptRequestData *data, IScript *script)
 
- Protected Attributes inherited from CPMUnknown< IScriptProvider >
HelperInterface fHelperInterface
 

Detailed Description

Demonstrates extending the Application script object, adding both a method and a property.

To see the interaction between a script and this plug-in, use the following extendscript:

var said = "hello"; app.speak(said); var yourresponse = app.response; app.speak(yourresponse);

Constructor & Destructor Documentation

SCScriptProvider::SCScriptProvider (IPMUnknownboss)
inline
Constructor.

Parameters
bossinterface ptr from boss object on which this interface is aggregated.
SCScriptProvider::~SCScriptProvider ()
inline

Destructor. Does nothing.

Member Function Documentation

ErrorCode SCScriptProvider::AccessProperty (ScriptID propID,
IScriptRequestDatadata,
IScriptparent 
)
virtual
This method is called if a provider can handle a property.

Parameters
propIDidentifies the ID of the property to handle.
dataidentifies an interface pointer used to extract data.
parentidentifies an interface pointer on the script object representing the parent of the application object.

Reimplemented from CScriptProvider.

Binds the C implementation class onto its ImplementationID making the C code callable by the application *ErrorCode SCScriptProvider::HandleMethod (ScriptID methodID,
IScriptRequestDatadata,
IScriptparent 
)
virtual
This method is called if a provider can handle an method.

Parameters
methodIDidentifies the ID of the method to handle.
dataidentifies an interface pointer used to extract data.
parentidentifies an interface pointer on the script object representing the parent of the application object.

Reimplemented from CScriptProvider.