OpenStructure
Public Member Functions | Protected Member Functions
DataObserver Class Referenceabstract

#include <data_observer.hh>

Inherited by Argand, DataViewerPanelBase, and ParentDataObserver.

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() [1/2]

DataObserver ( const ImageHandle d)

constructor

requires reference to data, then attaches itself to data

◆ DataObserver() [2/2]

DataObserver ( const DataObserver o)

◆ ~DataObserver()

virtual ~DataObserver ( )
virtual

Member Function Documentation

◆ GetObservedData()

virtual const ImageHandle& GetObservedData ( ) const
virtual

Returns data that is observed.

◆ is_valid()

bool is_valid ( ) const
protected

◆ IsDataValid()

bool IsDataValid ( ) const
inline

Definition at line 96 of file data_observer.hh.

◆ ObserverInvalidate()

void ObserverInvalidate ( )

Called after ObserverRelease.

◆ ObserverRelease()

virtual void ObserverRelease ( )
pure virtual

Called if data is released from memory.

Implemented in ParentDataObserver, DataViewerPanelBase, and Argand.

◆ ObserverUpdate() [1/3]

virtual void ObserverUpdate ( )
virtual

called upon data change, noop by default

Reimplemented in FFTPanel, DataViewerPanelBase, and Argand.

◆ ObserverUpdate() [2/3]

virtual void ObserverUpdate ( const Extent )
virtual

special update, calls ObserverUpdate() by default

Reimplemented in DataViewerPanelBase, and Argand.

◆ ObserverUpdate() [3/3]

virtual void ObserverUpdate ( const Point )
virtual

special update, calls ObserverUpdate() by default

Reimplemented in DataViewerPanelBase, and Argand.

◆ operator=()

DataObserver& operator= ( const DataObserver o)

◆ SetObservedData()

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: