OpenStructure
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Protected Member Functions
DataObserver Class Reference

#include <data_observer.hh>

Public Member Functions

 DataObserver (const ImageHandle &d)
 DataObserver (const DataObserver &o)
DataObserveroperator= (const DataObserver &o)
virtual ~DataObserver ()
virtual void ObserverUpdate ()
virtual void ObserverUpdate (const Extent &)
virtual void ObserverUpdate (const Point &)
virtual void ObserverRelease ()=0
void ObserverInvalidate ()
virtual const ImageHandleGetObservedData () const
bool IsDataValid () const

Protected Member Functions

void SetObservedData (const ImageHandle &d)
bool is_valid () const

Detailed Description

Abstract base class of data observer.

Definition at line 59 of file data_observer.hh.


Constructor & Destructor Documentation

DataObserver ( const ImageHandle d)

constructor

requires reference to data, then attaches itself to data

DataObserver ( const DataObserver o)
virtual ~DataObserver ( )
virtual

Member Function Documentation

virtual const ImageHandle& GetObservedData ( ) const
virtual

Returns data that is observed.

bool is_valid ( ) const
protected
bool IsDataValid ( ) const
inline

Definition at line 96 of file data_observer.hh.

void ObserverInvalidate ( )

Called after ObserverRelease.

virtual void ObserverRelease ( )
pure virtual

Called if data is released from memory.

virtual void ObserverUpdate ( )
virtual

called upon data change, noop by default

virtual void ObserverUpdate ( const Extent )
virtual

special update, calls ObserverUpdate() by default

virtual void ObserverUpdate ( const Point )
virtual

special update, calls ObserverUpdate() by default

DataObserver& operator= ( const DataObserver o)
void SetObservedData ( const ImageHandle d)
protected

Set new data to observe.

Automatically unregister previously observed data


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