Drag[en]gine Game Engine  1.21
deErrorTrace Class Reference

Error Trace. More...

#include <deErrorTrace.h>

Public Member Functions

Constructors and Destructors
 deErrorTrace ()
 Create new error trace object. More...
 
 ~deErrorTrace ()
 Clean up error trace object. More...
 
Management
const decStringGetError () const
 Error. More...
 
void SetError (const char *error)
 Set error. More...
 
void Clear ()
 Clears the error trace. More...
 
Trace Point Management
bool HasPoints () const
 Determines if there exist trace points. More...
 
bool IsEmpty () const
 Trace is empty. More...
 
int GetPointCount () const
 Count of trace points. More...
 
deErrorTracePointGetPoint (int index) const
 Indexed trace point. More...
 
void AddPoint (deErrorTracePoint *point)
 Adds a new trace point. More...
 
void RemoveAllPoints ()
 Removes all trace points. More...
 
Convenience Functions
deErrorTracePointAddAndSetIfEmpty (const char *error, deLoadableModule *sourceModule, const char *sourceFunc, int sourceLine)
 Add given error to the trace and sets the error if there exists no trace point yet. More...
 
deErrorTracePointAddPoint (deLoadableModule *sourceModule, const char *sourceFunc, int sourceLine)
 Add new trace point with the given information. More...
 
void PrintTrace (deLogger &logger)
 Print error trace out to the given logger. More...
 

Detailed Description

Error Trace.

An Error Trace object contains a list of Error Trace Point objects. describing the path of an error that occurred in the engine.

Constructor & Destructor Documentation

◆ deErrorTrace()

deErrorTrace::deErrorTrace ( )

Create new error trace object.

◆ ~deErrorTrace()

deErrorTrace::~deErrorTrace ( )

Clean up error trace object.

Member Function Documentation

◆ AddAndSetIfEmpty()

deErrorTracePoint* deErrorTrace::AddAndSetIfEmpty ( const char *  error,
deLoadableModule sourceModule,
const char *  sourceFunc,
int  sourceLine 
)

Add given error to the trace and sets the error if there exists no trace point yet.

Returns the new trace point if added or NULL otherwise.

◆ AddPoint() [1/2]

void deErrorTrace::AddPoint ( deErrorTracePoint point)

Adds a new trace point.

◆ AddPoint() [2/2]

deErrorTracePoint* deErrorTrace::AddPoint ( deLoadableModule sourceModule,
const char *  sourceFunc,
int  sourceLine 
)

Add new trace point with the given information.

◆ Clear()

void deErrorTrace::Clear ( )

Clears the error trace.

◆ GetError()

const decString& deErrorTrace::GetError ( ) const
inline

Error.

◆ GetPoint()

deErrorTracePoint* deErrorTrace::GetPoint ( int  index) const

Indexed trace point.

◆ GetPointCount()

int deErrorTrace::GetPointCount ( ) const
inline

Count of trace points.

◆ HasPoints()

bool deErrorTrace::HasPoints ( ) const
inline

Determines if there exist trace points.

◆ IsEmpty()

bool deErrorTrace::IsEmpty ( ) const
inline

Trace is empty.

◆ PrintTrace()

void deErrorTrace::PrintTrace ( deLogger logger)

Print error trace out to the given logger.

This is more of a temporary function and should not be used.

◆ RemoveAllPoints()

void deErrorTrace::RemoveAllPoints ( )

Removes all trace points.

◆ SetError()

void deErrorTrace::SetError ( const char *  error)

Set error.


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