Thyra::ModelEvaluatorBase::OutArgs< Scalar > Class Template Reference

Concrete aggregate class for all output arguments computable by a ModelEvaluator subclass object. More...

#include <Thyra_ModelEvaluatorBase_decl.hpp>

Inheritance diagram for Thyra::ModelEvaluatorBase::OutArgs< Scalar >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 OutArgs ()
 
int Np () const
 Return the number of parameter subvectors p(l) supported (Np >= 0).
int Ng () const
 Return the number of axillary response functions g(j)(...) supported (Ng >= 0).
bool supports (EOutArgsMembers arg) const
 Determine if an input argument is supported or not.
const DerivativeSupportsupports (EOutArgsDfDp arg, int l) const
 Determine if DfDp(l) is supported or not, where 0 <= l && l < Np().
const DerivativeSupportsupports (EOutArgsDgDx_dot arg, int j) const
 Determine if DgDx_dot(j) is supported or not, 0 <= j && j < Ng().
const DerivativeSupportsupports (EOutArgsDgDx arg, int j) const
 Determine if DgDx(j) is supported or not, 0 <= j && j < Ng().
const DerivativeSupportsupports (EOutArgsDgDp arg, int j, int l) const
 Determine if DgDp(j,l) is supported or not, 0 <= j && j < Ng() and 0 <= l && l < Np().
void set_f (const RCP< VectorBase< Scalar > > &f)
 Precondition: supports(OUT_ARG_f)==true.
RCP< VectorBase< Scalar > > get_f () const
 Precondition: supports(OUT_ARG_f)==true.
void set_g (int j, const RCP< VectorBase< Scalar > > &g_j)
 Precondition: supports(OUT_ARG_g)==true.
RCP< VectorBase< Scalar > > get_g (int j) const
 Precondition: supports(OUT_ARG_g)==true..
void set_W (const RCP< LinearOpWithSolveBase< Scalar > > &W)
 Precondition: supports(OUT_ARG_W)==true.
RCP< LinearOpWithSolveBase
< Scalar > > 
get_W () const
 Precondition: supports(OUT_ARG_W)==true.
void set_W_op (const RCP< LinearOpBase< Scalar > > &W_op)
 Precondition: supports(OUT_ARG_W_op)==true.
RCP< LinearOpBase< Scalar > > get_W_op () const
 Precondition: supports(OUT_ARG_W_op)==true.
DerivativeProperties get_W_properties () const
 Return the known properties of W (precondition: supports(OUT_ARG_f)==true).
void set_DfDp (int l, const Derivative< Scalar > &DfDp_l)
 Precondition: supports(OUT_ARG_DfDp,l)==true.
Derivative< Scalar > get_DfDp (int l) const
 Precondition: supports(OUT_ARG_DfDp,l)==true.
DerivativeProperties get_DfDp_properties (int l) const
 Return the know properties of DfDp(l) (precondition: supports(OUT_ARG_DfDp,l)==true).
void set_DgDx_dot (int j, const Derivative< Scalar > &DgDx_dot_j)
 Precondition: supports(OUT_ARG_DgDx_dot,j)==true.
Derivative< Scalar > get_DgDx_dot (int j) const
 Precondition: supports(OUT_ARG_DgDx_dot,j)==true.
DerivativeProperties get_DgDx_dot_properties (int j) const
 Return the know properties of DgDx_dot(j) (precondition: supports(OUT_ARG_DgDx_dot,j)==true).
void set_DgDx (int j, const Derivative< Scalar > &DgDx_j)
 Precondition: supports(OUT_ARG_DgDx,j)==true.
Derivative< Scalar > get_DgDx (int j) const
 Precondition: supports(OUT_ARG_DgDx,j)==true.
DerivativeProperties get_DgDx_properties (int j) const
 Return the know properties of DgDx(j) (precondition: supports(OUT_ARG_DgDx,j)==true).
void set_DgDp (int j, int l, const Derivative< Scalar > &DgDp_j_l)
 Precondition: supports(OUT_ARG_DgDp,j,l)==true.
Derivative< Scalar > get_DgDp (int j, int l) const
 Precondition: supports(OUT_ARG_DgDp,j,l)==true.
DerivativeProperties get_DgDp_properties (int j, int l) const
 Return the know properties of DgDp(j,l) (precondition: supports(OUT_ARG_DgDp,j,l)==true).
void setArgs (const OutArgs< Scalar > &outArgs, bool ignoreUnsupported=false)
 Set all arguments fron outArgs into *this.
void setFailed () const
 Set that the evaluation as a whole failed.
bool isFailed () const
 Return if the evaluation failed or not.
bool isEmpty () const
 
void assertSameSupport (const OutArgs< Scalar > &outArgs) const
 Assert that two OutArgs objects have the same support.
std::string modelEvalDescription () const
 
std::string description () const
 
void describe (Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel) const
 Create a more detailed description along about this object and the ModelEvaluator that created it.

Protected Member Functions

void _setModelEvalDescription (const std::string &modelEvalDescription)
 
void _set_Np_Ng (int Np, int Ng)
 
void _setSupports (EOutArgsMembers arg, bool supports)
 
void _setSupports (EOutArgsDfDp arg, int l, const DerivativeSupport &)
 
void _setSupports (EOutArgsDgDx_dot arg, int j, const DerivativeSupport &)
 
void _setSupports (EOutArgsDgDx arg, int j, const DerivativeSupport &)
 
void _setSupports (EOutArgsDgDp arg, int j, int l, const DerivativeSupport &)
 
void _set_W_properties (const DerivativeProperties &properties)
 
void _set_DfDp_properties (int l, const DerivativeProperties &properties)
 
void _set_DgDx_dot_properties (int j, const DerivativeProperties &properties)
 
void _set_DgDx_properties (int j, const DerivativeProperties &properties)
 
void _set_DgDp_properties (int j, int l, const DerivativeProperties &properties)
 
void _setSupports (const OutArgs< Scalar > &inputOutArgs)
 
void _setUnsupportsAndRelated (EInArgsMembers arg)
 
void _setUnsupportsAndRelated (EOutArgsMembers arg)
 

Detailed Description

template<class Scalar>
class Thyra::ModelEvaluatorBase::OutArgs< Scalar >

Concrete aggregate class for all output arguments computable by a ModelEvaluator subclass object.

Note that const OutArgs object means that a client can not change what output objects are being pointed to but they can still change the states of the contained objects. This is slight variation on the concept of logical const-ness in C++ but it is totally consistent with the vary nature of this class.

In addition to storing the output objects themselves, this class also allows the storage if the properties of some of the objects as well. Therefore, objects of this type are used to communicate a lot of different information about the output functions and derivatives supported by a model. It tells clients what functions and derivatives are supported and what the know properties are.

A client can not directly set what input arguments are supported or not supported. Only a subclass of ModelEvaluator can do that (through the OutArgsSetup subclass).

Definition at line 462 of file Thyra_ModelEvaluatorBase_decl.hpp.


Constructor & Destructor Documentation

template<class Scalar >
Thyra::ModelEvaluatorBase::OutArgs< Scalar >::OutArgs (  )  [inline]

Definition at line 565 of file Thyra_ModelEvaluatorBase_def.hpp.


Member Function Documentation

template<class Scalar >
int Thyra::ModelEvaluatorBase::OutArgs< Scalar >::Np (  )  const [inline]

Return the number of parameter subvectors p(l) supported (Np >= 0).

Definition at line 572 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
int Thyra::ModelEvaluatorBase::OutArgs< Scalar >::Ng (  )  const [inline]

Return the number of axillary response functions g(j)(...) supported (Ng >= 0).

Definition at line 577 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
bool Thyra::ModelEvaluatorBase::OutArgs< Scalar >::supports ( EOutArgsMembers  arg  )  const [inline]

Determine if an input argument is supported or not.

Definition at line 582 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
const ModelEvaluatorBase::DerivativeSupport & Thyra::ModelEvaluatorBase::OutArgs< Scalar >::supports ( EOutArgsDfDp  arg,
int  l 
) const [inline]

Determine if DfDp(l) is supported or not, where 0 <= l && l < Np().

Definition at line 597 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
const ModelEvaluatorBase::DerivativeSupport & Thyra::ModelEvaluatorBase::OutArgs< Scalar >::supports ( EOutArgsDgDx_dot  arg,
int  j 
) const [inline]

Determine if DgDx_dot(j) is supported or not, 0 <= j && j < Ng().

Definition at line 608 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
const ModelEvaluatorBase::DerivativeSupport & Thyra::ModelEvaluatorBase::OutArgs< Scalar >::supports ( EOutArgsDgDx  arg,
int  j 
) const [inline]

Determine if DgDx(j) is supported or not, 0 <= j && j < Ng().

Definition at line 619 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
const ModelEvaluatorBase::DerivativeSupport & Thyra::ModelEvaluatorBase::OutArgs< Scalar >::supports ( EOutArgsDgDp  arg,
int  j,
int  l 
) const [inline]

Determine if DgDp(j,l) is supported or not, 0 <= j && j < Ng() and 0 <= l && l < Np().

Definition at line 630 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::set_f ( const RCP< VectorBase< Scalar > > &  f  )  [inline]

Precondition: supports(OUT_ARG_f)==true.

Definition at line 641 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
RCP< VectorBase< Scalar > > Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_f (  )  const [inline]

Precondition: supports(OUT_ARG_f)==true.

Definition at line 652 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::set_g ( int  j,
const RCP< VectorBase< Scalar > > &  g_j 
) [inline]

Precondition: supports(OUT_ARG_g)==true.

Definition at line 660 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
RCP< VectorBase< Scalar > > Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_g ( int  j  )  const [inline]

Precondition: supports(OUT_ARG_g)==true..

Definition at line 671 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::set_W ( const RCP< LinearOpWithSolveBase< Scalar > > &  W  )  [inline]

Precondition: supports(OUT_ARG_W)==true.

Definition at line 679 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
RCP< LinearOpWithSolveBase< Scalar > > Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_W (  )  const [inline]

Precondition: supports(OUT_ARG_W)==true.

Definition at line 690 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::set_W_op ( const RCP< LinearOpBase< Scalar > > &  W_op  )  [inline]

Precondition: supports(OUT_ARG_W_op)==true.

Definition at line 698 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
RCP< LinearOpBase< Scalar > > Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_W_op (  )  const [inline]

Precondition: supports(OUT_ARG_W_op)==true.

Definition at line 709 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
ModelEvaluatorBase::DerivativeProperties Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_W_properties (  )  const [inline]

Return the known properties of W (precondition: supports(OUT_ARG_f)==true).

Definition at line 718 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::set_DfDp ( int  l,
const Derivative< Scalar > &  DfDp_l 
) [inline]

Precondition: supports(OUT_ARG_DfDp,l)==true.

Definition at line 726 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
ModelEvaluatorBase::Derivative< Scalar > Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_DfDp ( int  l  )  const [inline]

Precondition: supports(OUT_ARG_DfDp,l)==true.

Definition at line 737 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
ModelEvaluatorBase::DerivativeProperties Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_DfDp_properties ( int  l  )  const [inline]

Return the know properties of DfDp(l) (precondition: supports(OUT_ARG_DfDp,l)==true).

Definition at line 746 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::set_DgDx_dot ( int  j,
const Derivative< Scalar > &  DgDx_dot_j 
) [inline]

Precondition: supports(OUT_ARG_DgDx_dot,j)==true.

Definition at line 754 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
ModelEvaluatorBase::Derivative< Scalar > Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_DgDx_dot ( int  j  )  const [inline]

Precondition: supports(OUT_ARG_DgDx_dot,j)==true.

Definition at line 765 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
ModelEvaluatorBase::DerivativeProperties Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_DgDx_dot_properties ( int  j  )  const [inline]

Return the know properties of DgDx_dot(j) (precondition: supports(OUT_ARG_DgDx_dot,j)==true).

Definition at line 774 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::set_DgDx ( int  j,
const Derivative< Scalar > &  DgDx_j 
) [inline]

Precondition: supports(OUT_ARG_DgDx,j)==true.

Definition at line 782 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
ModelEvaluatorBase::Derivative< Scalar > Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_DgDx ( int  j  )  const [inline]

Precondition: supports(OUT_ARG_DgDx,j)==true.

Definition at line 793 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
ModelEvaluatorBase::DerivativeProperties Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_DgDx_properties ( int  j  )  const [inline]

Return the know properties of DgDx(j) (precondition: supports(OUT_ARG_DgDx,j)==true).

Definition at line 802 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::set_DgDp ( int  j,
int  l,
const Derivative< Scalar > &  DgDp_j_l 
) [inline]

Precondition: supports(OUT_ARG_DgDp,j,l)==true.

Definition at line 810 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
ModelEvaluatorBase::Derivative< Scalar > Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_DgDp ( int  j,
int  l 
) const [inline]

Precondition: supports(OUT_ARG_DgDp,j,l)==true.

Definition at line 821 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
ModelEvaluatorBase::DerivativeProperties Thyra::ModelEvaluatorBase::OutArgs< Scalar >::get_DgDp_properties ( int  j,
int  l 
) const [inline]

Return the know properties of DgDp(j,l) (precondition: supports(OUT_ARG_DgDp,j,l)==true).

Definition at line 830 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::setArgs ( const OutArgs< Scalar > &  outArgs,
bool  ignoreUnsupported = false 
) [inline]

Set all arguments fron outArgs into *this.

If ignoreUnsupported==true, then arguments in outArgs that are not supported in *this will be ignored. Othereise, if an unsupported argument is set, then an exception will be thrown.

Definition at line 861 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::setFailed (  )  const [inline]

Set that the evaluation as a whole failed.

Note that this function is declared as const even through it technically changes the state of *this object. This was done so that this property could be set by a ModelEvaluator subclass in evalModel() which takes a const OutArgs object. This is consistent with the behavior of the rest of a const OutArgs object in that a client is allowed to change the state of objects through a const OutArgs object, they just can't change what objects are pointed to.

Definition at line 940 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
bool Thyra::ModelEvaluatorBase::OutArgs< Scalar >::isFailed (  )  const [inline]

Return if the evaluation failed or not.

If the evaluation failed, no assumptions should be made at all about the state of the output objects.

Definition at line 956 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
bool Thyra::ModelEvaluatorBase::OutArgs< Scalar >::isEmpty (  )  const [inline]

Definition at line 963 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::assertSameSupport ( const OutArgs< Scalar > &  outArgs  )  const [inline]

Assert that two OutArgs objects have the same support.

Definition at line 996 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
std::string Thyra::ModelEvaluatorBase::OutArgs< Scalar >::modelEvalDescription (  )  const [inline]

Definition at line 1070 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
std::string Thyra::ModelEvaluatorBase::OutArgs< Scalar >::description (  )  const [inline, virtual]

Reimplemented from Teuchos::Describable.

Definition at line 1077 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::describe ( Teuchos::FancyOStream out,
const Teuchos::EVerbosityLevel  verbLevel 
) const [inline, virtual]

Create a more detailed description along about this object and the ModelEvaluator that created it.

Reimplemented from Teuchos::Describable.

Definition at line 1093 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_setModelEvalDescription ( const std::string &  modelEvalDescription  )  [inline, protected]

Definition at line 1200 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_set_Np_Ng ( int  Np,
int  Ng 
) [inline, protected]

Definition at line 1208 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_setSupports ( EOutArgsMembers  arg,
bool  supports 
) [inline, protected]

Definition at line 1234 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_setSupports ( EOutArgsDfDp  arg,
int  l,
const DerivativeSupport supports_in 
) [inline, protected]

Definition at line 1247 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_setSupports ( EOutArgsDgDx_dot  arg,
int  j,
const DerivativeSupport supports_in 
) [inline, protected]

Definition at line 1258 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_setSupports ( EOutArgsDgDx  arg,
int  j,
const DerivativeSupport supports_in 
) [inline, protected]

Definition at line 1268 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_setSupports ( EOutArgsDgDp  arg,
int  j,
int  l,
const DerivativeSupport supports_in 
) [inline, protected]

Definition at line 1278 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_set_W_properties ( const DerivativeProperties properties  )  [inline, protected]

Definition at line 1289 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_set_DfDp_properties ( int  l,
const DerivativeProperties properties 
) [inline, protected]

Definition at line 1298 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_set_DgDx_dot_properties ( int  j,
const DerivativeProperties properties 
) [inline, protected]

Definition at line 1308 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_set_DgDx_properties ( int  j,
const DerivativeProperties properties 
) [inline, protected]

Definition at line 1318 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_set_DgDp_properties ( int  j,
int  l,
const DerivativeProperties properties 
) [inline, protected]

Definition at line 1328 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar>
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_setSupports ( const OutArgs< Scalar > &  inputOutArgs  )  [inline, protected]

Definition at line 1338 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_setUnsupportsAndRelated ( EInArgsMembers  arg  )  [inline, protected]

Definition at line 1376 of file Thyra_ModelEvaluatorBase_def.hpp.

template<class Scalar >
void Thyra::ModelEvaluatorBase::OutArgs< Scalar >::_setUnsupportsAndRelated ( EOutArgsMembers  arg  )  [inline, protected]

Definition at line 1400 of file Thyra_ModelEvaluatorBase_def.hpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Generated on Wed Apr 13 10:00:45 2011 for Thyra by  doxygen 1.6.3