10#include "Teuchos_StringToIntMap.hpp" 
   14StringToIntMap::StringToIntMap(
 
   18  typedef map_t::value_type 
val_t;
 
   19  for( 
int i = 0; 
i < n; ++
i ) {
 
   23      ,
"Teuchos::StringToIntMap::StringToIntMap(...): " 
   24      << 
"Error, the std::string \"" << 
strings[
i] << 
"\" is a duplicate for " 
   25      << defaultGroupName_ );
 
 
   31  map_t::const_iterator 
itr = map_.find( 
option );
 
   34    ,
"Teuchos::StringToIntMap:::get(\""<<
option<<
"\",...): " 
   35    << 
"Error, the std::string \"" << 
option << 
"\" is not recongnised for " 
   36    << ( groupName.length() ? groupName : defaultGroupName_ )
 
   37    << 
"; valid selections include " << this->validSelections() << 
"." 
 
   44std::string StringToIntMap::validSelections()
 const 
   46  std::ostringstream 
oss;
 
   48  map_t::const_iterator 
itr = map_.begin();
 
   49  for( 
int i = 0; 
itr != map_.end(); ++
itr, ++
i ) {
 
   52    oss << 
"\""<<
itr->first<<
"\":"<<
itr->second;
 
Smart reference counting pointer class for automatic garbage collection.
 
int get(const std::string &option, const std::string &groupName="") const
 
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
Macro for throwing an exception with breakpointing to ease debugging.
 
The Teuchos namespace contains all of the classes, structs and enums used by Teuchos,...