Orfeo ToolBox  4.2
Orfeo ToolBox is not a black box
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
otb::Parser Class Reference

Definition of the standard floating point parser. Standard implementation of the mathematical expressions parser. More...

#include <otbParser.h>

+ Inheritance diagram for otb::Parser:
+ Collaboration diagram for otb::Parser:

Public Types

typedef itk::SmartPointer
< const Self
ConstPointer
 
typedef std::map< std::string,
int > 
FunctionMapType
 
typedef Parser ParserType
 
typedef itk::SmartPointer< SelfPointer
 
typedef Parser 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)
 
ValueType Eval ()
 
const std::string & GetExpr () const
 
FunctionMapType GetFunList () const
 
virtual const char * GetNameOfClass () const
 
const std::map< std::string,
Parser::ValueType * > & 
GetVar () const
 
virtual void SetExpr (const std::string &Expression)
 

Static Public Member Functions

static Pointer New ()
 

Protected Member Functions

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

Private Types

typedef itk::SmartPointer
< ParserImpl
ParserImplPtr
 

Private Member Functions

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

Private Attributes

ParserImplPtr m_InternalParser
 

Detailed Description

Definition of the standard floating point parser. Standard implementation of the mathematical expressions parser.

See Also
BandMathImageFilter

Definition at line 37 of file otbParser.h.

Member Typedef Documentation

Definition at line 44 of file otbParser.h.

typedef std::map<std::string, int> otb::Parser::FunctionMapType

Type for function/number of arguments map

Definition at line 57 of file otbParser.h.

Definition at line 93 of file otbParser.h.

Convenient type definitions

Definition at line 50 of file otbParser.h.

Definition at line 43 of file otbParser.h.

Standard class typedefs.

Definition at line 41 of file otbParser.h.

Definition at line 42 of file otbParser.h.

typedef double otb::Parser::ValueType

Definition at line 54 of file otbParser.h.

Constructor & Destructor Documentation

otb::Parser::Parser ( )
protected

Definition at line 231 of file otbParser.cxx.

otb::Parser::~Parser ( )
protectedvirtual

Definition at line 236 of file otbParser.cxx.

otb::Parser::Parser ( const Self )
private

Member Function Documentation

bool otb::Parser::CheckExpr ( )

Check Expression

Definition at line 260 of file otbParser.cxx.

References m_InternalParser.

void otb::Parser::ClearVar ( )

Clear all the defined variables

Definition at line 255 of file otbParser.cxx.

References m_InternalParser.

virtual::itk::LightObject::Pointer otb::Parser::CreateAnother ( void  ) const
void otb::Parser::DefineVar ( const std::string &  sName,
Parser::ValueType fVar 
)

Define a variable

Definition at line 250 of file otbParser.cxx.

References m_InternalParser.

Parser::ValueType otb::Parser::Eval ( )

Trigger the parsing

Definition at line 245 of file otbParser.cxx.

References m_InternalParser.

const std::string & otb::Parser::GetExpr ( ) const

Return the expression to be parsed

Definition at line 266 of file otbParser.cxx.

References m_InternalParser.

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

Return a map of function names and associated number of arguments

Definition at line 278 of file otbParser.cxx.

References m_InternalParser.

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

Run-time type information (and related methods)

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

Return the list of variables

Definition at line 272 of file otbParser.cxx.

References m_InternalParser.

static Pointer otb::Parser::New ( )
static

New macro for creation of through a Smart Pointer

void otb::Parser::operator= ( const Self )
private
void otb::Parser::PrintSelf ( std::ostream &  os,
itk::Indent  indent 
) const
protectedvirtual

Definition at line 225 of file otbParser.cxx.

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

Set the expression to be parsed

Definition at line 240 of file otbParser.cxx.

References m_InternalParser.

Member Data Documentation

ParserImplPtr otb::Parser::m_InternalParser
private

Definition at line 94 of file otbParser.h.

Referenced by CheckExpr(), ClearVar(), DefineVar(), Eval(), GetExpr(), GetFunList(), GetVar(), and SetExpr().


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