SeExpr
Public Member Functions | Static Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
SeContext Class Reference

#include <SeContext.h>

Public Member Functions

bool lookupParameter (const std::string &parameterName, std::string &value) const
 Lookup a SeContext parameter by name. More...
 
void setParameter (const std::string &parameterName, const std::string &value)
 Set a parameter. NOTE: this must be done when no threads are accessing lookupParameter for safety. More...
 
SeContextcreateChildContext () const
 Create a context that is a child of this context. More...
 
void setParent (const SeContext *context)
 
const SeContextgetParent () const
 
bool hasContext (const SeContext *context) const
 

Static Public Member Functions

static SeContextglobal ()
 The global default context of the seexpr. More...
 

Private Types

typedef std::map< std::string,
std::string > 
ParameterMap
 

Private Member Functions

 SeContext (const SeContext &)
 
SeContextoperator= (const SeContext &)
 
 SeContext (const SeContext *parent)
 

Private Attributes

const SeContext_parent
 The parent scope. More...
 
ParameterMap _parameters
 Attribute/value pairs. More...
 

Detailed Description

Definition at line 22 of file SeContext.h.

Member Typedef Documentation

typedef std::map<std::string,std::string> SeContext::ParameterMap
private

Definition at line 59 of file SeContext.h.

Constructor & Destructor Documentation

SeContext::SeContext ( const SeContext )
private

Private constructor and un-implemented default/copy/assignment (it is required that we derive from the global context via createChildContext)

Referenced by createChildContext().

SeContext::SeContext ( const SeContext parent)
private

Definition at line 19 of file SeContext.cpp.

Member Function Documentation

SeContext * SeContext::createChildContext ( ) const

Create a context that is a child of this context.

Definition at line 27 of file SeContext.cpp.

References SeContext().

const SeContext* SeContext::getParent ( ) const
inline

Definition at line 38 of file SeContext.h.

References _parent.

SeContext & SeContext::global ( )
static

The global default context of the seexpr.

Definition at line 31 of file SeContext.cpp.

References context.

bool SeContext::hasContext ( const SeContext context) const
inline

Definition at line 40 of file SeContext.h.

References _parent, and hasContext().

Referenced by hasContext().

bool SeContext::lookupParameter ( const std::string &  parameterName,
std::string &  value 
) const
inline

Lookup a SeContext parameter by name.

Definition at line 25 of file SeContext.h.

References _parameters, _parent, it, and lookupParameter().

Referenced by lookupParameter().

SeContext& SeContext::operator= ( const SeContext )
private
void SeContext::setParameter ( const std::string &  parameterName,
const std::string &  value 
)

Set a parameter. NOTE: this must be done when no threads are accessing lookupParameter for safety.

Definition at line 23 of file SeContext.cpp.

References _parameters, and value().

void SeContext::setParent ( const SeContext context)
inline

Definition at line 37 of file SeContext.h.

References _parent, and context.

Member Data Documentation

ParameterMap SeContext::_parameters
private

Attribute/value pairs.

Definition at line 61 of file SeContext.h.

Referenced by lookupParameter(), and setParameter().

const SeContext* SeContext::_parent
private

The parent scope.

Definition at line 56 of file SeContext.h.

Referenced by getParent(), hasContext(), lookupParameter(), and setParent().


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