Thyra::ModelEvaluatorDelegatorBase< Scalar > Class Template Reference

This is a base class that delegetes almost all function to a wrapped model evaluator object. More...

#include <Thyra_ModelEvaluatorDelegatorBase.hpp>

Inheritance diagram for Thyra::ModelEvaluatorDelegatorBase< Scalar >:

[legend]
List of all members.

Constructors/initializers

 ModelEvaluatorDelegatorBase ()
 Constructs to uninitialized.
 ModelEvaluatorDelegatorBase (const RCP< ModelEvaluator< Scalar > > &model)
 Calls initialize().
 ModelEvaluatorDelegatorBase (const RCP< const ModelEvaluator< Scalar > > &model)
 Calls initialize().
void initialize (const RCP< ModelEvaluator< Scalar > > &model)
 Initialize given a non-const model evaluator.
void initialize (const RCP< const ModelEvaluator< Scalar > > &model)
 Initialize given a const model evaluator.
void uninitialize ()
 Uninitialize.

Virtual functions that can overriden

virtual bool isUnderlyingModelConst () const
 
virtual RCP< ModelEvaluator<
Scalar > > 
getNonconstUnderlyingModel ()
 
virtual RCP< const ModelEvaluator<
Scalar > > 
getUnderlyingModel () const
 

Public functions overridden from ModelEvaulator.

RCP< const VectorSpaceBase<
Scalar > > 
get_x_space () const
 
RCP< const VectorSpaceBase<
Scalar > > 
get_f_space () const
 
RCP< const VectorSpaceBase<
Scalar > > 
get_p_space (int l) const
 
RCP< const Teuchos::Array<
std::string > > 
get_p_names (int l) const
 
RCP< const VectorSpaceBase<
Scalar > > 
get_g_space (int j) const
 
ModelEvaluatorBase::InArgs<
Scalar > 
getNominalValues () const
 
ModelEvaluatorBase::InArgs<
Scalar > 
getLowerBounds () const
 
ModelEvaluatorBase::InArgs<
Scalar > 
getUpperBounds () const
 
RCP< LinearOpWithSolveBase<
Scalar > > 
create_W () const
 
RCP< LinearOpBase< Scalar > > create_W_op () const
 
ModelEvaluatorBase::InArgs<
Scalar > 
createInArgs () const
 
void reportFinalPoint (const ModelEvaluatorBase::InArgs< Scalar > &finalPoint, const bool wasSolved)
 

Producted utility functions to be called by subclasses

void setLocalVerbosityLevelValidatedParameter (ParameterList *paramList) const
 Set a valid parameter for reading the local verbosity level.
Teuchos::EVerbosityLevel readLocalVerbosityLevelValidatedParameter (ParameterList &paramList) const
 Read the local verbosity level parameter.

Detailed Description

template<class Scalar>
class Thyra::ModelEvaluatorDelegatorBase< Scalar >

This is a base class that delegetes almost all function to a wrapped model evaluator object.

This class makes it easy to write many different types of decorator subclasses by only requiring those subclasses to override just the behavior that they need to overide and leave the rest alone. Note that whenever the definition of ModelEvaluator changes, this class will have to be updated. However, the decorator subclasses that derive from this base class might be able to remain unchanged. Note that changes in only the ModelEvaluatorBase::InArgs and ModelEvaluatorBase::OutArgs classes should not require any changes here.

The only functions that a client must override in order to create a concrete subcalss is the evalModel() function. All other functions have implementations here that simply delegate to the model evaluator object returned from getUnderlyingModel(). However, most decorator classes will need to override at least one other function.

This class provides a default implemntation of the machinary to store and access the wrapped model evaluator object. A subclass can choose to ignore this and override the functions isUnderlyingModelConst(), getConstUnderlyingModel(), and getUnderlyingModel().

Definition at line 67 of file Thyra_ModelEvaluatorDelegatorBase.hpp.


Constructor & Destructor Documentation

template<class Scalar>
Thyra::ModelEvaluatorDelegatorBase< Scalar >::ModelEvaluatorDelegatorBase (  ) 

Constructs to uninitialized.

Definition at line 300 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
Thyra::ModelEvaluatorDelegatorBase< Scalar >::ModelEvaluatorDelegatorBase ( const RCP< ModelEvaluator< Scalar > > &  model  ) 

Calls initialize().

Definition at line 305 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
Thyra::ModelEvaluatorDelegatorBase< Scalar >::ModelEvaluatorDelegatorBase ( const RCP< const ModelEvaluator< Scalar > > &  model  ) 

Calls initialize().

Definition at line 314 of file Thyra_ModelEvaluatorDelegatorBase.hpp.


Member Function Documentation

template<class Scalar>
void Thyra::ModelEvaluatorDelegatorBase< Scalar >::initialize ( const RCP< ModelEvaluator< Scalar > > &  model  ) 

Initialize given a non-const model evaluator.

Reimplemented in Thyra::DefaultInverseModelEvaluator< Scalar >, and Thyra::DefaultLumpedParameterModelEvaluator< Scalar >.

Definition at line 323 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorDelegatorBase< Scalar >::initialize ( const RCP< const ModelEvaluator< Scalar > > &  model  ) 

Initialize given a const model evaluator.

Definition at line 332 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorDelegatorBase< Scalar >::uninitialize (  ) 

Uninitialize.

Definition at line 341 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
bool Thyra::ModelEvaluatorDelegatorBase< Scalar >::isUnderlyingModelConst (  )  const [virtual]

Definition at line 351 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
RCP< ModelEvaluator< Scalar > > Thyra::ModelEvaluatorDelegatorBase< Scalar >::getNonconstUnderlyingModel (  )  [virtual]

Definition at line 359 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
RCP< const ModelEvaluator< Scalar > > Thyra::ModelEvaluatorDelegatorBase< Scalar >::getUnderlyingModel (  )  const [virtual]

Definition at line 367 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
RCP< const VectorSpaceBase< Scalar > > Thyra::ModelEvaluatorDelegatorBase< Scalar >::get_x_space (  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Definition at line 378 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
RCP< const VectorSpaceBase< Scalar > > Thyra::ModelEvaluatorDelegatorBase< Scalar >::get_f_space (  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Definition at line 386 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
RCP< const VectorSpaceBase< Scalar > > Thyra::ModelEvaluatorDelegatorBase< Scalar >::get_p_space ( int  l  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Reimplemented in Thyra::DefaultInverseModelEvaluator< Scalar >, and Thyra::DefaultLumpedParameterModelEvaluator< Scalar >.

Definition at line 394 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
RCP< const Teuchos::Array< std::string > > Thyra::ModelEvaluatorDelegatorBase< Scalar >::get_p_names ( int  l  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Reimplemented in Thyra::DefaultLumpedParameterModelEvaluator< Scalar >.

Definition at line 402 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
RCP< const VectorSpaceBase< Scalar > > Thyra::ModelEvaluatorDelegatorBase< Scalar >::get_g_space ( int  j  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Reimplemented in Thyra::DefaultInverseModelEvaluator< Scalar >.

Definition at line 410 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
ModelEvaluatorBase::InArgs< Scalar > Thyra::ModelEvaluatorDelegatorBase< Scalar >::getNominalValues (  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Reimplemented in Thyra::DefaultLumpedParameterModelEvaluator< Scalar >, and Thyra::DefaultNominalBoundsOverrideModelEvaluator< Scalar >.

Definition at line 418 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
ModelEvaluatorBase::InArgs< Scalar > Thyra::ModelEvaluatorDelegatorBase< Scalar >::getLowerBounds (  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Reimplemented in Thyra::DefaultLumpedParameterModelEvaluator< Scalar >, and Thyra::DefaultNominalBoundsOverrideModelEvaluator< Scalar >.

Definition at line 426 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
ModelEvaluatorBase::InArgs< Scalar > Thyra::ModelEvaluatorDelegatorBase< Scalar >::getUpperBounds (  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Reimplemented in Thyra::DefaultLumpedParameterModelEvaluator< Scalar >, and Thyra::DefaultNominalBoundsOverrideModelEvaluator< Scalar >.

Definition at line 434 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
RCP< LinearOpWithSolveBase< Scalar > > Thyra::ModelEvaluatorDelegatorBase< Scalar >::create_W (  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Reimplemented in Thyra::DefaultModelEvaluatorWithSolveFactory< Scalar >.

Definition at line 442 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
RCP< LinearOpBase< Scalar > > Thyra::ModelEvaluatorDelegatorBase< Scalar >::create_W_op (  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Definition at line 450 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
ModelEvaluatorBase::InArgs< Scalar > Thyra::ModelEvaluatorDelegatorBase< Scalar >::createInArgs (  )  const [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Reimplemented in Thyra::DefaultInverseModelEvaluator< Scalar >.

Definition at line 458 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorDelegatorBase< Scalar >::reportFinalPoint ( const ModelEvaluatorBase::InArgs< Scalar > &  finalPoint,
const bool  wasSolved 
) [virtual]

Implements Thyra::ModelEvaluator< Scalar >.

Reimplemented in Thyra::DefaultFinalPointCaptureModelEvaluator< Scalar >, and Thyra::DefaultLumpedParameterModelEvaluator< Scalar >.

Definition at line 467 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorDelegatorBase< Scalar >::setLocalVerbosityLevelValidatedParameter ( ParameterList *  paramList  )  const [protected]

Set a valid parameter for reading the local verbosity level.

Definition at line 483 of file Thyra_ModelEvaluatorDelegatorBase.hpp.

template<class Scalar>
Teuchos::EVerbosityLevel Thyra::ModelEvaluatorDelegatorBase< Scalar >::readLocalVerbosityLevelValidatedParameter ( ParameterList &  paramList  )  const [protected]

Read the local verbosity level parameter.

Definition at line 506 of file Thyra_ModelEvaluatorDelegatorBase.hpp.


The documentation for this class was generated from the following file:
Generated on Tue Oct 20 12:47:14 2009 for Thyra Nonlinear Model Evaluator Support by doxygen 1.4.7