![]() |
Public API Reference |
#include <csapplicationframework.h>
Inheritance diagram for csApplicationFramework:
Public Methods | |
virtual | ~csApplicationFramework () |
Destructor. More... | |
operator iObjectRegistry * () | |
Allow a csApplicationFramework object to be used as an iObjectRegistry*. More... | |
bool | Open () |
Open plugins and open application window. More... | |
Static Public Methods | |
void | Quit (void) |
Quit running the appliation. More... | |
iObjectRegistry * | GetObjectRegistry () |
Returns a pointer to the object registry. More... | |
void | SetApplicationName (char *name) |
Set the application's string name identifier. More... | |
void | ProcessQueue () |
Start event queue. More... | |
bool | DisplayError (const char *description) |
Display an error notification. More... | |
void | DisplayInfo (const char *description) |
Display an information notification. More... | |
Protected Methods | |
csApplicationFramework () | |
Constructor. More... | |
virtual bool | OnInitialize (int argc, char *argv[])=0 |
Initialize the subclassed csApplicationFramework object. More... | |
virtual bool | Application ()=0 |
Perform application logic. More... | |
virtual void | OnExit () |
Perform any end of program processing. More... |
// Example.h class myDerivedEngine : public csApplicationFramework { public: myDerivedEngine(); virtual bool OnInitialize(); virtual bool Application(); }; extern myDerivedEngine myApp; //-------------------------- // Example.cpp // File scope myDerivedEngine myApp; myDerivedEngine::myDerivedEngine() : myDerivedEngine() { SetApplicationName ("crystal.space.example.app"); } myDerivedEngine::OnIntialize() { // Request plugins, initialize any global non-CS data and structures return true; } myDerivedEngine::Application() { // Perform initialization of CS data and structures, set event handler, // load world, etc. if ( ! Open()) { return false; } ProcessQueue(); return true; }
This class is derived from csInitializer for convenience, allowing overridden members to call csInitializer methods without qualifying them with csInitializer::.
This class is not related to csApp or other classes related to the CSWS.
Definition at line 98 of file csapplicationframework.h.
|
Constructor.
|
|
Destructor.
|
|
Perform application logic.
|
|
Display an error notification.
Definition at line 311 of file csapplicationframework.h. |
|
Display an information notification.
Definition at line 325 of file csapplicationframework.h. |
|
Returns a pointer to the object registry.
Definition at line 245 of file csapplicationframework.h. |
|
Perform any end of program processing. /remarks This method is called after the crystal space engine has been shut down, just before the framework is about to end the program. Unlike the other overridables of this class, you need not bother overriding this method. In general, this is provided to allow end of program debugging support. |
|
Initialize the subclassed csApplicationFramework object.
|
|
Open plugins and open application window.
Definition at line 260 of file csapplicationframework.h. References csInitializer::OpenApplication. |
|
Allow a csApplicationFramework object to be used as an iObjectRegistry*.
Definition at line 255 of file csapplicationframework.h. |
|
Start event queue.
Definition at line 284 of file csapplicationframework.h. |
|
Quit running the appliation.
|
|
Set the application's string name identifier.
Definition at line 274 of file csapplicationframework.h. |