Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

lemur::utility::ParamStack Class Reference

List of all members.

Public Member Functions

indri::api::Parameterstop ()
void push (indri::api::Parameters *p)
void pop ()
 pop the parameter stack, deleting the popped element.

void addKey (const lemur::utility::String &s)
void displayKeys ()
 ~ParamStack ()
 clean up.


Static Public Member Functions

void clear ()
 Clean up.

ParamStackinstance ()
 Obtain the singleton instance, instantiating if necessary.


Private Member Functions

 ParamStack ()
 private constructor to ensure singleton pattern.


Private Attributes

std::stack< indri::api::Parameters * > params
 the stack of Parameters.

std::set< std::string > keys
 maintain a list of used keys (for ParamDisplay).


Static Private Attributes

ParamStack_paramStackSingleton = 0
 the singleton instance.


Detailed Description

Container class for parameter stack. Maintains a singleton instance to push/pop Parameters * onto.


Constructor & Destructor Documentation

lemur::utility::ParamStack::~ParamStack  )  [inline]
 

clean up.

lemur::utility::ParamStack::ParamStack  )  [inline, private]
 

private constructor to ensure singleton pattern.


Member Function Documentation

void lemur::utility::ParamStack::addKey const lemur::utility::String s  )  [inline]
 

Add a parameter name to the list of known parameters.

Parameters:
s the name to add.
See also:
displayKeys

void lemur::utility::ParamStack::clear void   )  [inline, static]
 

Clean up.

void lemur::utility::ParamStack::displayKeys  )  [inline]
 

Write the list of known parameter names to cerr.

See also:
ParamDisplay

ParamStack& lemur::utility::ParamStack::instance  )  [inline, static]
 

Obtain the singleton instance, instantiating if necessary.

void lemur::utility::ParamStack::pop  )  [inline]
 

pop the parameter stack, deleting the popped element.

void lemur::utility::ParamStack::push indri::api::Parameters p  )  [inline]
 

Parameters:
p Parameters to push onto the stack.

indri::api::Parameters* lemur::utility::ParamStack::top  )  [inline]
 

Returns:
the top of the parameter stack or NULL if the stack is empty.


Member Data Documentation

ParamStack * lemur::utility::ParamStack::_paramStackSingleton = 0 [static, private]
 

the singleton instance.

std::set<std::string> lemur::utility::ParamStack::keys [private]
 

maintain a list of used keys (for ParamDisplay).

std::stack<indri::api::Parameters * > lemur::utility::ParamStack::params [private]
 

the stack of Parameters.


The documentation for this class was generated from the following file:
Generated on Tue Jun 15 11:03:07 2010 for Lemur by doxygen 1.3.4