Orfeo Toolbox  4.0
Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Private Attributes | List of all members
otb::StandardOneLineFilterWatcher Class Reference

This class shows the percentage progress execution of the pipeline filtering process. More...

#include <otbStandardOneLineFilterWatcher.h>

+ Inheritance diagram for otb::StandardOneLineFilterWatcher:
+ Collaboration diagram for otb::StandardOneLineFilterWatcher:

Public Member Functions

 StandardOneLineFilterWatcher (itk::ProcessObject *process, const char *comment="")
 
 StandardOneLineFilterWatcher (itk::ProcessObject *process, const std::string &comment="")
 
 StandardOneLineFilterWatcher ()
 
std::string GetComment ()
 
const char * GetNameOfClass ()
 
itk::ProcessObjectGetProcess ()
 
const int & GetStars () const
 
itk::TimeProbeGetTimeProbe ()
 
void SetStars (int count)
 

Protected Types

typedef
itk::SimpleMemberCommand
< FilterWatcherBase
CommandType
 

Protected Member Functions

virtual void EndFilter ()
 
virtual void EndFilterCallback ()
 
virtual void ShowProgress ()
 
virtual void ShowProgressCallback ()
 
virtual void StartFilter ()
 
virtual void StartFilterCallback ()
 

Protected Attributes

std::string m_Comment
 
bool m_Ended
 
CommandType::Pointer m_EndFilterCommand
 
unsigned long m_EndTag
 
itk::ProcessObject::Pointer m_Process
 
CommandType::Pointer m_ProgressFilterCommand
 
unsigned long m_ProgressTag
 
bool m_Started
 
CommandType::Pointer m_StartFilterCommand
 
unsigned long m_StartTag
 
itk::TimeProbe m_TimeProbe
 

Private Attributes

int m_CurrentNbStars
 
int m_StarsCount
 

Detailed Description

This class shows the percentage progress execution of the pipeline filtering process.

This class is based on Observer design patter Abstract class ProcessObject is the subject Event are observers

Usage example:

FilterType::Pointer thresholdFilter = FilterType::New();
StandardOneLineFilterWatcher watcher(thresholdFilter, "Threshold");
See Also
itk::SimpleFilterWatcher
otb::fltkFilterWatcher

Definition at line 49 of file otbStandardOneLineFilterWatcher.h.

Member Typedef Documentation

Internal type

Definition at line 133 of file otbFilterWatcherBase.h.

Constructor & Destructor Documentation

otb::StandardOneLineFilterWatcher::StandardOneLineFilterWatcher ( itk::ProcessObject process,
const char *  comment = "" 
)

Constructor. Takes a ProcessObject to monitor and an optional comment string that is prepended to each event message.

Definition at line 34 of file otbStandardOneLineFilterWatcher.cxx.

otb::StandardOneLineFilterWatcher::StandardOneLineFilterWatcher ( itk::ProcessObject process,
const std::string &  comment = "" 
)

Definition at line 43 of file otbStandardOneLineFilterWatcher.cxx.

otb::StandardOneLineFilterWatcher::StandardOneLineFilterWatcher ( )

Default constructor

Definition at line 27 of file otbStandardOneLineFilterWatcher.cxx.

Member Function Documentation

void otb::StandardOneLineFilterWatcher::EndFilter ( )
protectedvirtual

Callback method to show the EndEvent

Implements otb::FilterWatcherBase.

Definition at line 101 of file otbStandardOneLineFilterWatcher.cxx.

virtual void otb::FilterWatcherBase::EndFilterCallback ( )
inlineprotectedvirtualinherited
std::string otb::FilterWatcherBase::GetComment ( )
inlineinherited

Get the comment for the watcher.

Definition at line 75 of file otbFilterWatcherBase.h.

References otb::FilterWatcherBase::m_Comment.

const char* otb::FilterWatcherBase::GetNameOfClass ( )
inlineinherited
itk::ProcessObject* otb::FilterWatcherBase::GetProcess ( )
inlineinherited

Methods to access member data Get a pointer to the process object being watched.

Definition at line 69 of file otbFilterWatcherBase.h.

References itk::SmartPointer< TObjectType >::GetPointer(), and otb::FilterWatcherBase::m_Process.

const int& otb::StandardOneLineFilterWatcher::GetStars ( ) const
inline

Definition at line 69 of file otbStandardOneLineFilterWatcher.h.

References m_StarsCount.

itk::TimeProbe& otb::FilterWatcherBase::GetTimeProbe ( )
inlineinherited

Get a reference to the TimeProbe

Definition at line 81 of file otbFilterWatcherBase.h.

References otb::FilterWatcherBase::m_TimeProbe.

void otb::StandardOneLineFilterWatcher::SetStars ( int  count)
inline

Get/Set number of stars

Definition at line 65 of file otbStandardOneLineFilterWatcher.h.

References m_StarsCount.

void otb::StandardOneLineFilterWatcher::ShowProgress ( )
protectedvirtual

Callback method to show the ProgressEvent

Implements otb::FilterWatcherBase.

Definition at line 53 of file otbStandardOneLineFilterWatcher.cxx.

References itk::blanks.

virtual void otb::FilterWatcherBase::ShowProgressCallback ( )
inlineprotectedvirtualinherited

Callback method to show the ProgressEvent

Definition at line 89 of file otbFilterWatcherBase.h.

References otb::FilterWatcherBase::ShowProgress().

Referenced by otb::FilterWatcherBase::FilterWatcherBase(), and otb::FilterWatcherBase::operator=().

void otb::StandardOneLineFilterWatcher::StartFilter ( )
protectedvirtual

Callback method to show the StartEvent

Implements otb::FilterWatcherBase.

Definition at line 94 of file otbStandardOneLineFilterWatcher.cxx.

virtual void otb::FilterWatcherBase::StartFilterCallback ( )
inlineprotectedvirtualinherited

Member Data Documentation

std::string otb::FilterWatcherBase::m_Comment
protectedinherited
int otb::StandardOneLineFilterWatcher::m_CurrentNbStars
private

Definition at line 90 of file otbStandardOneLineFilterWatcher.h.

bool otb::FilterWatcherBase::m_Ended
protectedinherited

Some filters (for ex. persistents) invoke the EndEvent several times Work around this by remembering if it was called or not

Definition at line 159 of file otbFilterWatcherBase.h.

Referenced by otb::FilterWatcherBase::EndFilterCallback().

CommandType::Pointer otb::FilterWatcherBase::m_EndFilterCommand
protectedinherited

End filter callback

Definition at line 139 of file otbFilterWatcherBase.h.

unsigned long otb::FilterWatcherBase::m_EndTag
protectedinherited

End observer

Definition at line 148 of file otbFilterWatcherBase.h.

itk::ProcessObject::Pointer otb::FilterWatcherBase::m_Process
protectedinherited
CommandType::Pointer otb::FilterWatcherBase::m_ProgressFilterCommand
protectedinherited

Progress filter callback

Definition at line 142 of file otbFilterWatcherBase.h.

unsigned long otb::FilterWatcherBase::m_ProgressTag
protectedinherited

Progress observer

Definition at line 151 of file otbFilterWatcherBase.h.

int otb::StandardOneLineFilterWatcher::m_StarsCount
private

Stars coutning

Definition at line 88 of file otbStandardOneLineFilterWatcher.h.

Referenced by GetStars(), and SetStars().

bool otb::FilterWatcherBase::m_Started
protectedinherited

Some filters (for ex. persistents) invoke the StartEvent several times Work around this by remembering if it was called or not

Definition at line 155 of file otbFilterWatcherBase.h.

Referenced by otb::FilterWatcherBase::StartFilterCallback().

CommandType::Pointer otb::FilterWatcherBase::m_StartFilterCommand
protectedinherited

Start filter callback

Definition at line 136 of file otbFilterWatcherBase.h.

unsigned long otb::FilterWatcherBase::m_StartTag
protectedinherited

Start oberserver

Definition at line 145 of file otbFilterWatcherBase.h.

itk::TimeProbe otb::FilterWatcherBase::m_TimeProbe
protectedinherited

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

Generated at Sat Mar 8 2014 18:59:32 for Orfeo Toolbox with doxygen 1.8.3.1