Difference between revisions of "ISXDK:ISXInterface"

From Lavish Software Wiki
Jump to navigation Jump to search
 
Line 1: Line 1:
 
== Overview ==
 
== Overview ==
 +
ISXInterface is the actual extension interface.  The pointer to the instance of your main class, derived from ISXInterface, is given to Inner Space.  This provides Inner Space with its main line of communicating with your extension.  As you can see below, there is not much to it.  You must supply the Initialize and Shutdown routines, and that's about it.
 +
 
== Functions ==
 
== Functions ==
 
=== GetVersion ===
 
=== GetVersion ===
virtual unsigned long GetVersion() {return ISXDK_VERSION;}
+
virtual unsigned long GetVersion() {return ISXDK_VERSION;}
 +
This function is automatically provided, and is used by Inner Space to ensure compatibility between it and your extension.  You should not override or modify this function.
 +
 
 
=== Initialize ===
 
=== Initialize ===
virtual bool Initialize(ISInterface *pISInterface)=0;
+
virtual bool Initialize(ISInterface *pISInterface)=0;
 +
This function is called when your extension is properly loaded and should perform any initialization routines.  This would include adding any commands, data types, Top-Level Objects, services, connecting to existing services, and so on.  All initialization should be done here, and not in the constructor for the class!
 +
 
 
=== Shutdown ===
 
=== Shutdown ===
virtual void Shutdown()=0;
+
virtual void Shutdown()=0;
 +
This function is called when your extension is being unloaded and should perform any shutdown routines.  This would include removing any commands, data types, Top-Level Objects, services, disconnecting from services, and so on.  All shutdown should be done here, and now in the destructor for the class!
 +
 
 
=== See Also ===
 
=== See Also ===
 
*[[ISXDK]]
 
*[[ISXDK]]
  
 
[[Category:ISXDK]]
 
[[Category:ISXDK]]

Latest revision as of 20:54, 16 July 2005

Overview

ISXInterface is the actual extension interface. The pointer to the instance of your main class, derived from ISXInterface, is given to Inner Space. This provides Inner Space with its main line of communicating with your extension. As you can see below, there is not much to it. You must supply the Initialize and Shutdown routines, and that's about it.

Functions

GetVersion

virtual unsigned long GetVersion() {return ISXDK_VERSION;}

This function is automatically provided, and is used by Inner Space to ensure compatibility between it and your extension. You should not override or modify this function.

Initialize

virtual bool Initialize(ISInterface *pISInterface)=0;

This function is called when your extension is properly loaded and should perform any initialization routines. This would include adding any commands, data types, Top-Level Objects, services, connecting to existing services, and so on. All initialization should be done here, and not in the constructor for the class!

Shutdown

virtual void Shutdown()=0;

This function is called when your extension is being unloaded and should perform any shutdown routines. This would include removing any commands, data types, Top-Level Objects, services, disconnecting from services, and so on. All shutdown should be done here, and now in the destructor for the class!

See Also