Orfeo Toolbox  3.16
Public Types | Public Member Functions | Static Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Private Member Functions | Static Private Member Functions | Private Attributes
otb::ParserImpl Class Reference
+ Inheritance diagram for otb::ParserImpl:
+ Collaboration diagram for otb::ParserImpl:

List of all members.

Public Types

typedef itk::SmartPointer
< const Self
ConstPointer
typedef mu::Parser::exception_type ExceptionType
typedef itk::SmartPointer< SelfPointer
typedef ParserImpl Self
typedef itk::LightObject Superclass
typedef double ValueType

Public Member Functions

bool CheckExpr ()
void ClearVar ()
virtual ::itk::LightObject::Pointer CreateAnother (void) const
void DefineVar (const std::string &sName, ValueType *fVar)
virtual void Delete ()
ValueType Eval ()
virtual void ExceptionHandler (ExceptionType &e)
virtual void ExceptionHandlerDebug (ExceptionType &e)
const std::string & GetExpr () const
Parser::FunctionMapType GetFunList () const
virtual const char * GetNameOfClass () const
virtual int GetReferenceCount () const
const std::map< std::string,
ValueType * > & 
GetVar () const
virtual void InitConst ()
virtual void InitFun ()
void Print (std::ostream &os, Indent indent=0) const
virtual void Register () const
virtual void SetExpr (const std::string &Expression)
virtual void SetReferenceCount (int)
virtual void UnRegister () const

Static Public Member Functions

static void BreakOnError ()
static Pointer New ()

Protected Types

typedef int InternalReferenceCountType

Protected Member Functions

 ParserImpl ()
virtual ~ParserImpl ()
virtual void PrintHeader (std::ostream &os, Indent indent) const
virtual void PrintSelf (std::ostream &os, itk::Indent indent) const
virtual void PrintTrailer (std::ostream &os, Indent indent) const

Protected Attributes

InternalReferenceCountType m_ReferenceCount
SimpleFastMutexLock m_ReferenceCountLock

Private Member Functions

 ParserImpl (const Self &)
void operator= (const Self &)

Static Private Member Functions

static ValueType NDVI (ValueType r, ValueType niri)

Private Attributes

mu::Parser m_MuParser

Detailed Description

Definition at line 28 of file otbParser.cxx.


Member Typedef Documentation

Reimplemented from itk::LightObject.

Definition at line 35 of file otbParser.cxx.

typedef mu::Parser::exception_type otb::ParserImpl::ExceptionType

Definition at line 45 of file otbParser.cxx.

typedef int itk::LightObject::InternalReferenceCountType
protectedinherited

Define the type of the reference count according to the target. This allows the use of atomic operations

Definition at line 137 of file itkLightObject.h.

Reimplemented from itk::LightObject.

Definition at line 34 of file otbParser.cxx.

Standard class typedefs.

Reimplemented from itk::LightObject.

Definition at line 32 of file otbParser.cxx.

Definition at line 33 of file otbParser.cxx.

Convenient type definitions

Definition at line 41 of file otbParser.cxx.


Constructor & Destructor Documentation

otb::ParserImpl::ParserImpl ( )
inlineprotected

Definition at line 177 of file otbParser.cxx.

virtual otb::ParserImpl::~ParserImpl ( )
inlineprotectedvirtual

Definition at line 183 of file otbParser.cxx.

otb::ParserImpl::ParserImpl ( const Self )
private

Member Function Documentation

void itk::LightObject::BreakOnError ( )
staticinherited

This method is called when itkExceptionMacro executes. It allows the debugger to break on error.

Definition at line 149 of file itkLightObject.cxx.

bool otb::ParserImpl::CheckExpr ( )
inline

Check Expression

Definition at line 120 of file otbParser.cxx.

void otb::ParserImpl::ClearVar ( )
inline

Clear all the defined variables

Definition at line 102 of file otbParser.cxx.

virtual::itk::LightObject::Pointer otb::ParserImpl::CreateAnother ( void  ) const
virtual

Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class.

Reimplemented from itk::LightObject.

void otb::ParserImpl::DefineVar ( const std::string &  sName,
ValueType fVar 
)
inline

Define a variable

Definition at line 89 of file otbParser.cxx.

void itk::LightObject::Delete ( )
virtualinherited

Delete an itk object. This method should always be used to delete an object when the new operator was used to create it. Using the C delete method will not work with reference counting.

Delete a itk object. This method should always be used to delete an object when the new operator was used to create it. Using the C++ delete method will not work with reference counting.

Definition at line 88 of file itkLightObject.cxx.

ValueType otb::ParserImpl::Eval ( )
inline

Trigger the parsing

Definition at line 73 of file otbParser.cxx.

virtual void otb::ParserImpl::ExceptionHandler ( ExceptionType e)
inlinevirtual

Convert parser specific exception into itk exception

Definition at line 152 of file otbParser.cxx.

virtual void otb::ParserImpl::ExceptionHandlerDebug ( ExceptionType e)
inlinevirtual

Convert parser specific exception into itk debug macro

Definition at line 164 of file otbParser.cxx.

References otbGenericMsgDebugMacro.

const std::string& otb::ParserImpl::GetExpr ( ) const
inline

Return the expression to be parsed

Definition at line 108 of file otbParser.cxx.

Parser::FunctionMapType otb::ParserImpl::GetFunList ( ) const
inline

Definition at line 137 of file otbParser.cxx.

virtual const char* otb::ParserImpl::GetNameOfClass ( ) const
virtual

Run-time type information (and related methods)

Reimplemented from itk::LightObject.

virtual int itk::LightObject::GetReferenceCount ( ) const
inlinevirtualinherited

Gets the reference count on this object.

Definition at line 105 of file itkLightObject.h.

const std::map<std::string, ValueType*>& otb::ParserImpl::GetVar ( ) const
inline

Return the list of variables

Definition at line 114 of file otbParser.cxx.

virtual void otb::ParserImpl::InitConst ( )
inlinevirtual

Initialize user defined constants

Definition at line 48 of file otbParser.cxx.

References otb::CONST_E, otb::CONST_EULER, otb::CONST_LN10, otb::CONST_LN2, otb::CONST_LOG10E, otb::CONST_LOG2E, and otb::CONST_PI.

virtual void otb::ParserImpl::InitFun ( )
inlinevirtual

Initialize user defined functions

Definition at line 60 of file otbParser.cxx.

static ValueType otb::ParserImpl::NDVI ( ValueType  r,
ValueType  niri 
)
inlinestaticprivate

Definition at line 200 of file otbParser.cxx.

static Pointer otb::ParserImpl::New ( )
static

New macro for creation of through a Smart Pointer

Reimplemented from itk::LightObject.

void otb::ParserImpl::operator= ( const Self )
private
void itk::LightObject::Print ( std::ostream &  os,
Indent  indent = 0 
) const
inherited

Cause the object to print itself out.

Avoid DLL boundary problems. This function will be common to all itk objects. It just calls the header/self/trailer virtual print methods, which can be overriden by subclasses (any itk object).

Definition at line 135 of file itkLightObject.cxx.

References itk::Indent::GetNextIndent().

Referenced by itk::operator<<().

void itk::LightObject::PrintHeader ( std::ostream &  os,
Indent  indent 
) const
protectedvirtualinherited

Define a default print header for all objects.

Definition at line 320 of file itkLightObject.cxx.

virtual void otb::ParserImpl::PrintSelf ( std::ostream &  os,
itk::Indent  indent 
) const
inlineprotectedvirtual

Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Chaining method to print an object's instance variables, as well as its superclasses.

Reimplemented from itk::LightObject.

Definition at line 187 of file otbParser.cxx.

void itk::LightObject::PrintTrailer ( std::ostream &  os,
Indent  indent 
) const
protectedvirtualinherited

Define a default print trailer for all objects.

Definition at line 331 of file itkLightObject.cxx.

void itk::LightObject::Register ( ) const
virtualinherited

Increase the reference count (mark as used by another object).

Reimplemented in itk::ExceptionObject::ReferenceCountedExceptionData, and itk::Object.

Definition at line 160 of file itkLightObject.cxx.

virtual void otb::ParserImpl::SetExpr ( const std::string &  Expression)
inlinevirtual

Set the expression to be parsed

Definition at line 67 of file otbParser.cxx.

void itk::LightObject::SetReferenceCount ( int  ref)
virtualinherited

Sets the reference count on this object. This is a dangerous method, use it with care.

Sets the reference count (use with care)

Reimplemented in itk::Object.

Definition at line 244 of file itkLightObject.cxx.

void itk::LightObject::UnRegister ( ) const
virtualinherited

Decrease the reference count (release by another object).

Reimplemented in itk::ExceptionObject::ReferenceCountedExceptionData, and itk::Object.

Definition at line 192 of file itkLightObject.cxx.

Referenced by itk::LightObject::New().


Member Data Documentation

mu::Parser otb::ParserImpl::m_MuParser
private

Definition at line 197 of file otbParser.cxx.

InternalReferenceCountType itk::LightObject::m_ReferenceCount
mutableprotectedinherited

Number of uses of this object by other objects.

Definition at line 141 of file itkLightObject.h.

SimpleFastMutexLock itk::LightObject::m_ReferenceCountLock
mutableprotectedinherited

Mutex lock to protect modification to the reference count

Definition at line 144 of file itkLightObject.h.


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

Generated at Sun Feb 3 2013 03:51:40 for Orfeo Toolbox with doxygen 1.8.1.1