TriUtils  Development
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | List of all members
Trilinos_Util_Map Class Reference

#include <Trilinos_Util_CommandLineParser.h>

Inheritance diagram for Trilinos_Util_Map:
Inheritance graph
[legend]

Public Member Functions

 Trilinos_Util_Map ()
 
virtual ~Trilinos_Util_Map ()
 
virtual int Get (const std::string input, const int def_value)
 Gets the value of the specified option as an integer. If not found, returns the specified default value. More...
 
virtual double Get (const std::string input, const double def_value)
 Gets the value of the specified option as a double. If not found, returns the specified default value. More...
 
virtual std::string Get (const std::string input, const std::string def_value)
 Gets the value of the specified option as a std::string. If not found, returns the specified default value. More...
 
virtual bool Set (const std::string input, const char *value)
 Modify the value of a database entry. More...
 
virtual bool Set (const std::string input, const std::string value)
 
virtual bool Set (const std::string input, const int value)
 
virtual bool Set (const std::string input, const double value)
 
virtual bool Add (const std::string input, const std::string value)
 Add an entry to the databse. More...
 
bool SetLabel (std::string Label)
 
std::string GetLabel (std::string)
 
virtual bool Has (const std::string input)
 Check wheter an option is in the database or not. More...
 
virtual void ShowAll () const
 Show all the databse entries. More...
 
virtual void ShowReallyAll () const
 Show all the databse entries, including entries beginning with "_". More...
 
virtual void Reset (void)
 

Friends

std::ostream & operator<< (std::ostream &os, const Trilinos_Util_Map &S)
 

Constructor & Destructor Documentation

Trilinos_Util_Map::Trilinos_Util_Map ( void  )
virtual Trilinos_Util_Map::~Trilinos_Util_Map ( )
inlinevirtual

Member Function Documentation

bool Trilinos_Util_Map::Add ( const std::string  input,
const std::string  value 
)
virtual

Add an entry to the databse.

This method add an entry to the databse. First, it checks that this entry does not exist. If it exists, the method returns false. Otherwise, it adds the entry and returns true.

virtual int Trilinos_Util_Map::Get ( const std::string  input,
const int  def_value 
)
virtual

Gets the value of the specified option as an integer. If not found, returns the specified default value.

Referenced by Trilinos_Util::CrsMatrixGallery::Set().

virtual double Trilinos_Util_Map::Get ( const std::string  input,
const double  def_value 
)
virtual

Gets the value of the specified option as a double. If not found, returns the specified default value.

virtual std::string Trilinos_Util_Map::Get ( const std::string  input,
const std::string  def_value 
)
virtual

Gets the value of the specified option as a std::string. If not found, returns the specified default value.

std::string Trilinos_Util_Map::GetLabel ( std::string  )
inline
bool Trilinos_Util_Map::Has ( const std::string  input)
virtual

Check wheter an option is in the database or not.

This method checks whether option input is in the databse or not. It returns true if it is, false otherwise.

Referenced by Trilinos_Util::CrsMatrixGallery::Set().

void Trilinos_Util_Map::Reset ( void  )
virtual
virtual bool Trilinos_Util_Map::Set ( const std::string  input,
const char *  value 
)
virtual

Modify the value of a database entry.

This method modifies the value of a database entry. If the entry does not exist in the database, return false. Otherwise, returns true.

virtual bool Trilinos_Util_Map::Set ( const std::string  input,
const std::string  value 
)
virtual
virtual bool Trilinos_Util_Map::Set ( const std::string  input,
const int  value 
)
virtual
virtual bool Trilinos_Util_Map::Set ( const std::string  input,
const double  value 
)
virtual
bool Trilinos_Util_Map::SetLabel ( std::string  Label)
inline
void Trilinos_Util_Map::ShowAll ( ) const
virtual

Show all the databse entries.

Referenced by operator<<().

void Trilinos_Util_Map::ShowReallyAll ( ) const
virtual

Show all the databse entries, including entries beginning with "_".

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const Trilinos_Util_Map S 
)
friend

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