OSG  3.4.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
osg::NotifyHandler Class Referenceabstract

#include <Notify.h>

Inheritance diagram for osg::NotifyHandler:
Inheritance graph
[legend]
Collaboration diagram for osg::NotifyHandler:
Collaboration graph
[legend]

Public Member Functions

virtual void notify (osg::NotifySeverity severity, const char *message)=0
 
- Public Member Functions inherited from osg::Referenced
 Referenced ()
 
 Referenced (bool threadSafeRefUnref)
 
 Referenced (const Referenced &)
 
Referencedoperator= (const Referenced &)
 
virtual void setThreadSafeRefUnref (bool threadSafe)
 
bool getThreadSafeRefUnref () const
 
OpenThreads::MutexgetRefMutex () const
 
int ref () const
 
int unref () const
 
int unref_nodelete () const
 
int referenceCount () const
 
ObserverSetgetObserverSet () const
 
ObserverSetgetOrCreateObserverSet () const
 
void addObserver (Observer *observer) const
 
void removeObserver (Observer *observer) const
 

Additional Inherited Members

- Static Public Member Functions inherited from osg::Referenced
static OpenThreads::MutexgetGlobalReferencedMutex ()
 
static void setThreadSafeReferenceCounting (bool enableThreadSafeReferenceCounting)
 
static bool getThreadSafeReferenceCounting ()
 
static void setDeleteHandler (DeleteHandler *handler)
 
static DeleteHandlergetDeleteHandler ()
 
- Protected Member Functions inherited from osg::Referenced
virtual ~Referenced ()
 
void signalObserversAndDelete (bool signalDelete, bool doDelete) const
 
void deleteUsingDeleteHandler () const
 
- Protected Attributes inherited from osg::Referenced
OpenThreads::AtomicPtr _observerSet
 
OpenThreads::Atomic _refCount
 

Detailed Description

Handler processing output of notification stream. It acts as a sink to notification messages. It is called when notification stream needs to be synchronized (i.e. after osg::notify() << std::endl). StandardNotifyHandler is used by default, it writes notifications to stderr (severity <= WARN) or stdout (severity > WARN). Notifications can be redirected to other sinks such as GUI widgets or windows debugger (WinDebugNotifyHandler) with custom handlers. Use setNotifyHandler to set custom handler. Note that osg notification API is not thread safe although notification handler is called from many threads. When incorporating handlers into GUI widgets you must take care of thread safety on your own.

See also
setNotifyHandler

Definition at line 104 of file Notify.h.

Member Function Documentation

virtual void osg::NotifyHandler::notify ( osg::NotifySeverity  severity,
const char *  message 
)
pure virtual

Implemented in osg::StandardNotifyHandler.


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