oaObserver<oaViewType> Class Template Reference

Inheritance diagram for oaObserver<oaViewType>:

oaBaseObserver


Public Methods

 oaObserver (oaUInt4 priorityIn, oaBoolean enabledIn=true)
virtual ~oaObserver ()
virtual void onPostCreate (oaViewType *viewType)

Static Public Methods

oaBoolean hasObservers ()

Detailed Description

template<>
class oaObserver<oaViewType>

This base template class can be used to derive observers for oaViewType objects. It supports postCreate event notifications.

Scoped observers are also available for oaViewType objects.

See oaObserver for information on using OpenAccess observer template classes to derive and instantiate observers in an application.


Constructor & Destructor Documentation

oaObserver<oaViewType>::oaObserver oaUInt4    priorityIn,
oaBoolean    enabledIn = true
 

This is the oaVersionedObserver<oaViewType, oacObserverVersion1> constructor. If multiple observers exist for a given oaViewType notification event, observers with a lower priorityIn value are called before those with a higher value.

Parameters:
priorityIn Priority of this observer relative to other oaViewType observers.
enabledIn Determines whether this observer is called when an observed event occurs.

oaObserver<oaViewType>::~oaObserver   [virtual]
 

This is the destructor for the oaObserver<oaViewType> class. This function destroys this oaObserver<oaViewType> object, deactivating and deleting this observer from the ViewType observer list, and freeing all resources associated with this observer.


Member Function Documentation

oaBoolean oaObserver<oaViewType>::hasObservers   [inline, static]
 

This function returns true if any observers for this type are active.

void oaObserver<oaViewType>::onPostCreate oaViewType *    viewType [virtual]
 

This function is called after an oaViewType object has been created. The application's derived observer class should implement this function to receive notification after an oaViewType object is created.

Parameters:
viewType A pointer to the created oaViewType object.


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

Return to top of page