Sacado
Development
|
Specialization of Sacado::ParameterLibraryBase for scalar parameters. More...
#include <Sacado_ScalarParameterLibrary.hpp>
Public Types | |
typedef ParameterLibraryBase < ScalarParameterFamily < EvalTypeTraits > , ScalarParameterEntry< _, EvalTypeTraits > > | BaseT |
Typename synonym of base class. | |
Public Types inherited from Sacado::ParameterLibraryBase< ScalarParameterFamily< EvalTypeTraits >, ScalarParameterEntry< _, EvalTypeTraits > > | |
typedef FamilyMap::iterator | iterator |
Iterator typename. | |
typedef FamilyMap::const_iterator | const_iterator |
Const iterator typename. | |
Public Member Functions | |
ScalarParameterLibrary () | |
Default constructor. | |
virtual | ~ScalarParameterLibrary () |
Destructor. | |
void | setRealValueForAllTypes (const std::string &name, double value) |
Set paramter value using a real number. | |
template<class EvalType > | |
void | setRealValue (const std::string &name, double value) |
Set real parameter to value value. | |
template<class EvalType > | |
void | setValue (const std::string &name, const typename EvalTypeTraits::template apply< EvalType >::type &value) |
Set parameter to value value. | |
template<class EvalType > | |
double | getRealValue (const std::string &name) const |
Get parameter value. | |
template<class EvalType > | |
const EvalTypeTraits::template apply< EvalType >::type & | getValue (const std::string &name) const |
Get parameter value. | |
template<class EvalType > | |
void | fillVector (const Teuchos::Array< std::string > &names, ScalarParameterVector< EvalTypeTraits > &pv) |
Fill a vector with the supplied parameter names. More... | |
Public Member Functions inherited from Sacado::ParameterLibraryBase< ScalarParameterFamily< EvalTypeTraits >, ScalarParameterEntry< _, EvalTypeTraits > > | |
ParameterLibraryBase () | |
Default constructor. | |
virtual | ~ParameterLibraryBase () |
Destructor. | |
bool | isParameter (const std::string &name) const |
Determine if parameter of name name is in the library. | |
bool | isParameterForType (const std::string &name) const |
Determine if parameter of name name has type type. | |
bool | addParameterFamily (const std::string &name, bool supports_ad, bool supports_analytic) |
Create a new parameter family. More... | |
bool | addEntry (const std::string &name, const Teuchos::RCP< typename Sacado::mpl::apply< ScalarParameterEntry< _, EvalTypeTraits >, EvalType >::type > &entry, const bool allow_overwrite=false) |
Add a new parameter using custom entry. More... | |
Teuchos::RCP< typename Sacado::mpl::apply < ScalarParameterEntry< _, EvalTypeTraits >, EvalType > ::type > | getEntry (const std::string &name) |
Return parameter entry. | |
Teuchos::RCP< const typename Sacado::mpl::apply < ScalarParameterEntry< _, EvalTypeTraits >, EvalType > ::type > | getEntry (const std::string &name) const |
Return parameter entry. | |
unsigned int | size () const |
Return number of parameters in library. | |
iterator | begin () |
Iterator pointing at beginning of library. | |
const_iterator | begin () const |
Iterator pointing at beginning of library. | |
iterator | end () |
Iterator pointing at end of library. | |
const_iterator | end () const |
Iterator pointing at end of library. | |
void | fillVector (const Teuchos::Array< std::string > &names, const Teuchos::Array< BaseValueType > &values, ParameterVectorBase< ScalarParameterFamily< EvalTypeTraits >, BaseValueType > &pv) |
Fill a vector with the supplied parameter names and values. | |
void | print (std::ostream &os, bool print_values=false) const |
Print parameter library. More... | |
void | clear () |
Clear the library. | |
Static Public Member Functions | |
static ScalarParameterLibrary & | getInstance () |
Returns a parameter library (singleton object). | |
Additional Inherited Members | |
Protected Types inherited from Sacado::ParameterLibraryBase< ScalarParameterFamily< EvalTypeTraits >, ScalarParameterEntry< _, EvalTypeTraits > > | |
typedef std::map< string, Teuchos::RCP < ScalarParameterFamily < EvalTypeTraits > > > | FamilyMap |
Map of all parameter families. | |
Protected Attributes inherited from Sacado::ParameterLibraryBase< ScalarParameterFamily< EvalTypeTraits >, ScalarParameterEntry< _, EvalTypeTraits > > | |
FamilyMap | library |
Scalar parameter library. | |
Specialization of Sacado::ParameterLibraryBase for scalar parameters.
void Sacado::ScalarParameterLibrary< EvalTypeTraits >::fillVector | ( | const Teuchos::Array< std::string > & | names, |
Sacado::ScalarParameterVector< EvalTypeTraits > & | pv | ||
) |
Fill a vector with the supplied parameter names.
baseValue will be computed from each individual parameter using the corresponding evaluation type EvalType
References Sacado::ParameterVectorBase< ScalarParameterFamily< EvalTypeTraits >, double >::addParam().