Drag[en]gine Game Engine  1.0
deBaseCrashRecoveryModule Class Referenceabstract

Base Crash Recovery Module. More...

#include <deBaseCrashRecoveryModule.h>

Inheritance diagram for deBaseCrashRecoveryModule:
deBaseModule

Public Member Functions

Constructors and Destructors
 deBaseCrashRecoveryModule (deLoadableModule &loadableModule)
 
virtual ~deBaseCrashRecoveryModule ()
 
Module Management
virtual bool Init ()=0
 
virtual void CleanUp ()=0
 
Management
virtual bool RecoverFromError ()=0
 
- Public Member Functions inherited from deBaseModule
 deBaseModule (deLoadableModule &loadableModule)
 Creates a new base module. More...
 
virtual ~deBaseModule ()
 Cleans up the base module. More...
 
virtual int GetParameterCount () const
 Retrieves the count of parameters. More...
 
virtual void GetParameterInfo (int index, deModuleParameter *parameter) const
 Retrieves the informations about the given indexec parameter. More...
 
virtual int FindParameter (const char *name) const
 Retrieves the index of the parameter with the given name or -1 if not found. More...
 
virtual float GetParameterValue (int index) const
 Retrieves the value of the parameter at the given index. More...
 
virtual void SetParameterValue (int index, float value)
 Sets the parameter of the parameter at the given index. More...
 
virtual void SendCommand (const decUnicodeArgumentList &command, decUnicodeString &answer)
 Sends a command to the module and retrieves an answer from it. More...
 
void LogInfo (const char *message)
 Outputs an information message on the console. More...
 
void LogInfoFormat (const char *message,...)
 Outputs a formated information message on the console. More...
 
void LogInfoFormatUsing (const char *message, va_list args)
 Outputs a formated information message on the console. More...
 
void LogWarn (const char *message)
 Outputs a warning message on the console. More...
 
void LogWarnFormat (const char *message,...)
 Outputs a formated warning message on the console. More...
 
void LogWarnFormatUsing (const char *message, va_list args)
 Outputs a formated warning message on the console. More...
 
void LogError (const char *message)
 Outputs an error message on the console. More...
 
void LogErrorFormat (const char *message,...)
 Outputs a formated error message on the console. More...
 
void LogErrorFormatUsing (const char *message, va_list args)
 Outputs a formated error message on the console. More...
 
void LogException (const deException &exception)
 Outputs an exception as error message on the console. More...
 
deEngineGetGameEngine () const
 Retrieves the game engine object. More...
 
deLoadableModuleGetLoadableModule () const
 Retrieves the loadable module. More...
 
deOSGetOS () const
 Retrieves the os object from the game engine. More...
 
deVirtualFileSystemGetVFS () const
 Retrieves the module virtual file system. More...
 
deErrorTracePointSetErrorTrace (const char *error, const char *sourceFunc, int sourceLine)
 Adds a new trace point and sets the error if the trace is empty. More...
 
deErrorTracePointSetErrorTrace (const deException &exception)
 Adds a new trace point and sets the error if the trace is empty. More...
 
deErrorTracePointAddErrorTracePoint (const char *sourceFunc, int sourceLine)
 Adds a new trace point to the engine error trace with an empty error. More...
 

Detailed Description

Base Crash Recovery Module.

Author
Pl├╝ss Roland
Version
1.0
Date
2008 Crash Recovery Modules are responsible for handling errors during the execution of the game engine. If anyone of the single type modules fails the crash recovery module is fired up to allow the user to locate the error and recover from it. Errors in the crash recovery module itself lead to an immediate termination of the engine hence this is the module to pay special attention to in terms of error safeness.

Constructor & Destructor Documentation

◆ deBaseCrashRecoveryModule()

deBaseCrashRecoveryModule::deBaseCrashRecoveryModule ( deLoadableModule loadableModule)

Creates a new module.

◆ ~deBaseCrashRecoveryModule()

virtual deBaseCrashRecoveryModule::~deBaseCrashRecoveryModule ( )
virtual

Cleans up the module.

Member Function Documentation

◆ CleanUp()

virtual void deBaseCrashRecoveryModule::CleanUp ( )
pure virtual

Shuts down the crash recovery module and cleans up.

◆ Init()

virtual bool deBaseCrashRecoveryModule::Init ( )
pure virtual

Initializes the crash recovery module.

◆ RecoverFromError()

virtual bool deBaseCrashRecoveryModule::RecoverFromError ( )
pure virtual

Takes over the run time in the case of an error. The modules has to either provide its own event queues ( in the case of ToolKits ) or to operate the event queues of the deOS object itself. Once the engine has reached a state where execution can continue as before this function has to exit with a true value. If false is returned a non recoverable error is assumed and the engine is shut down gracefully.


The documentation for this class was generated from the following file: