Hoops Visualize HPS  version 2018-SP2
Hoops Visualize HPS 3D Rendering Engine
Looking for a senior C++ dev?
I'm looking for work. Hire me!
HPS::EmergencyHandler Class Referenceabstract

#include <hps.h>

Public Member Functions

 EmergencyHandler ()
 A constructor for an EmergencyHandler. More...
 
virtual ~EmergencyHandler ()
 
intptr_t GetClassID () const
 Returns a unique identifier that is shared by all objects of the same class. More...
 
virtual void Handle (char const *message, HPS::Emergency::Code code)=0
 Visualize will call the EmergencyHandler::Handle method if any of the handler-enabling conditions are reached. More...
 

Static Public Member Functions

static void * operator new (size_t in_size)
 
static void operator delete (void *in_ptr, size_t in_size) throw ()
 

Detailed Description

The EmergencyHandler class is the base class for an custom EmergencyHandler. An EmergencyHandler allows the developer to provide custom logic to handle 'emergency' situations. For example, one can set a soft memory limit using HPS::Database::SetSoftMemoryLimit. If that limit is hit, Visualize will call the EmergencyHandler.


An EmergencyHandler is set by calling HPS::Database::SetEmergencyHandler. Only one EmergencyHandler can be set on the Database. If you try to set a second handler, the first one will be overwritten.


The default emergency handler will print a few diagnostics to stdout (when run in debug mode), but will make no attempt to recover from the emergency condition.

Constructor & Destructor Documentation

◆ EmergencyHandler()

HPS::EmergencyHandler::EmergencyHandler ( )
inline

A constructor for an EmergencyHandler.

◆ ~EmergencyHandler()

virtual HPS::EmergencyHandler::~EmergencyHandler ( )
virtual

Member Function Documentation

◆ GetClassID()

intptr_t HPS::EmergencyHandler::GetClassID ( ) const

Returns a unique identifier that is shared by all objects of the same class.

◆ Handle()

virtual void HPS::EmergencyHandler::Handle ( char const *  message,
HPS::Emergency::Code  code 
)
pure virtual

Visualize will call the EmergencyHandler::Handle method if any of the handler-enabling conditions are reached.

The Emergency::Code value describes the type of condition.

◆ operator delete()

static void HPS::EmergencyHandler::operator delete ( void *  in_ptr,
size_t  in_size 
)
throw (
)
inlinestatic
Here is the call graph for this function:

◆ operator new()

static void* HPS::EmergencyHandler::operator new ( size_t  in_size)
inlinestatic
Here is the call graph for this function:

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