Teuchos Package Browser (Single Doxygen Collection) Version of the Day
Teuchos::StringValidator Class Reference

A simple validator that only allows certain string values to be choosen or simply enforces that a particular parameter have a std::string for a value. More...

#include <Teuchos_StandardParameterEntryValidators.hpp>

Inheritance diagram for Teuchos::StringValidator:
Inheritance graph
[legend]

List of all members.

Constructors/Destructor

 StringValidator ()
 Constructs a StringValidator.
 StringValidator (const Teuchos::Array< std::string > &validStrings)
 Constructs a StringValidator.

Setter Functions

ValidStringsList setValidStrings (const Teuchos::Array< std::string > &validStrings)
 Sets the Array of valid strings and returns what the current array of valid string now is.

Overridden from ParameterEntryValidator

ValidStringsList validStringValues () const
 
void validate (ParameterEntry const &entry, std::string const &paramName, std::string const &sublistName) const
 
const std::string getXMLTypeName () const
 
void printDoc (std::string const &docString, std::ostream &out) const
 

Private Members

ValidStringsList validStrings_
 An array containing a list of all the valid string values.

Detailed Description

A simple validator that only allows certain string values to be choosen or simply enforces that a particular parameter have a std::string for a value.

Please see StringValidatorXMLConverter for documenation regarding the XML representation of this validator.

Definition at line 1470 of file Teuchos_StandardParameterEntryValidators.hpp.


Constructor & Destructor Documentation

Teuchos::StringValidator::StringValidator ( )

Constructs a StringValidator.

Definition at line 457 of file Teuchos_StandardParameterEntryValidators.cpp.

Teuchos::StringValidator::StringValidator ( const Teuchos::Array< std::string > &  validStrings)

Constructs a StringValidator.

Parameters:
validStringsA list of valid string values for this validator.

Definition at line 462 of file Teuchos_StandardParameterEntryValidators.cpp.


Member Function Documentation

ParameterEntryValidator::ValidStringsList Teuchos::StringValidator::setValidStrings ( const Teuchos::Array< std::string > &  validStrings)

Sets the Array of valid strings and returns what the current array of valid string now is.

Parameters:
validStringsWhat the array for the valid strings should contain.
Returns:
What the arry for the valid strings now conatians.

Definition at line 469 of file Teuchos_StandardParameterEntryValidators.cpp.

ParameterEntryValidator::ValidStringsList Teuchos::StringValidator::validStringValues ( ) const [virtual]
void Teuchos::StringValidator::validate ( ParameterEntry const &  entry,
std::string const &  paramName,
std::string const &  sublistName 
) const [virtual]
const std::string Teuchos::StringValidator::getXMLTypeName ( ) const [virtual]
void Teuchos::StringValidator::printDoc ( std::string const &  docString,
std::ostream &  out 
) const [virtual]

Member Data Documentation

An array containing a list of all the valid string values.

Definition at line 1529 of file Teuchos_StandardParameterEntryValidators.hpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines