NDEVR
API Documentation
GraphicsException

A common exeption thrown when an issue occurs within the NDEVR Graphics Engine. More...

Inheritance diagram for GraphicsException:
[legend]
Collaboration diagram for GraphicsException:
[legend]

Public Types

enum  GraphicsExceptionType { e_general , e_device_lost }
 Categories of graphics exceptions. More...

Public Member Functions

 GraphicsException (const TranslatedString &error)
 Constructs a graphics exception with an error message.
 GraphicsException (const TranslatedString &error, const TranslatedString &category)
 Constructs a graphics exception with an error message and category.
void setMessage (const TranslatedString &message) final override
 Sets the exception message.
void setType (GraphicsExceptionType type)
 Sets the exception type.
GraphicsExceptionType type () const
 Returns the exception type.

Protected Attributes

GraphicsExceptionType m_type
 The type of this graphics exception.

Detailed Description

A common exeption thrown when an issue occurs within the NDEVR Graphics Engine.


Definition at line 45 of file GraphicsException.h.

Member Enumeration Documentation

◆ GraphicsExceptionType

Categories of graphics exceptions.

Enumerator
e_general 

General graphics error.

e_device_lost 

The graphics device was lost and must be reinitialized.

Definition at line 49 of file GraphicsException.h.

Constructor & Destructor Documentation

◆ GraphicsException() [1/2]

GraphicsException::GraphicsException ( const TranslatedString & error)
explicit

Constructs a graphics exception with an error message.

Parameters
[in]errorThe error description.

◆ GraphicsException() [2/2]

GraphicsException::GraphicsException ( const TranslatedString & error,
const TranslatedString & category )

Constructs a graphics exception with an error message and category.

Parameters
[in]errorThe error description.
[in]categoryThe error category.

Member Function Documentation

◆ setMessage()

void GraphicsException::setMessage ( const TranslatedString & message)
finaloverridevirtual

Sets the exception message.

Parameters
[in]messageThe message text.

Reimplemented from Exception.

◆ setType()

void GraphicsException::setType ( GraphicsExceptionType type)

Sets the exception type.

Parameters
[in]typeThe exception type.

References type().

◆ type()

GraphicsExceptionType GraphicsException::type ( ) const

Returns the exception type.

Returns
The exception type.

Referenced by setType().


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