10#ifndef TEUCHOS_STANDARDFUNCTIONOBJECTXMLCONVERTERS_HPP
11#define TEUCHOS_STANDARDFUNCTIONOBJECTXMLCONVERTERS_HPP
19#include "Teuchos_StandardFunctionObjects.hpp"
26template<
class OperandType>
73 static std::string getOperandAttributeName(){
74 static const std::string operandAttributeName =
"operand";
75 return operandAttributeName;
82template<
class OperandType>
88 xmlObj.
getRequired<OperandType>(getOperandAttributeName());
92template<
class OperandType>
99 functionObject,
true);
100 OperandType operand = castedFunction->getModifiyingOperand();
113template<
class OperandType>
129template<
class OperandType>
132 OperandType operand)
const
145template<
class OperandType>
161template<
class OperandType>
164 OperandType operand)
const
177template<
class OperandType>
193template<
class OperandType>
196 OperandType operand)
const
209template<
class OperandType>
225template<
class OperandType>
228 OperandType operand)
const
Converts back and forth between XML and FunctionObjects.
A simple function object that adds a specififed value from the given arguement in the runFunction fun...
Class for converting AdditionFunction objects to and from XML.
RCP< SimpleFunctionObject< OperandType > > getSpecificSimpleFunction(OperandType operand) const
A simple function object that divides a specififed value from the given arguement in the runFunction ...
Class for converting DivisionFunction objects to and from XML.
RCP< SimpleFunctionObject< OperandType > > getSpecificSimpleFunction(OperandType operand) const
An abstract base class for converting FunctionObjects to and from XML.
A simple function object that multiplys a specififed value from the given arguement in the runFunctio...
Class for converting MultiplicationFunction objects to and from XML.
RCP< SimpleFunctionObject< OperandType > > getSpecificSimpleFunction(OperandType operand) const
Smart reference counting pointer class for automatic garbage collection.
RCP< T2 > rcp_dynamic_cast(const RCP< T1 > &p1, bool throw_on_fail=false)
Dynamic cast of underlying RCP type from T1* to T2*.
A simple function object that applies a given operand to a spcified arguement using a specific operat...
An xml converter for SimpleFunctionObjects.
virtual void getSpecialSimpleFunctionXMLTraits(const RCP< const SimpleFunctionObject< OperandType > >, XMLObject &) const
Add and extra XML traits that are specific to a certain FuncitonOjbect when converting that function ...
RCP< FunctionObject > convertXML(const XMLObject &xmlObj) const
virtual RCP< SimpleFunctionObject< OperandType > > getSpecificSimpleFunction(OperandType operand) const =0
Gets the specific SimpleFunction to be returned by this converter when converting from XML.
void convertFunctionObject(const RCP< const FunctionObject > functionObject, XMLObject &xmlObj) const
A simple function object that subtracts a specififed value from the given arguement in the runFunctio...
Class for converting SubtractionFunction objects to and from XML.
RCP< SimpleFunctionObject< OperandType > > getSpecificSimpleFunction(OperandType operand) const
Representation of an XML data tree. XMLObject is a ref-counted handle to a XMLObjectImplem object,...
const std::string & getRequired(const std::string &name) const
Get an attribute, throwing an std::exception if it is not found.
void addAttribute(const std::string &name, T value)
Lookup whether or not Doubles are allowed.
The Teuchos namespace contains all of the classes, structs and enums used by Teuchos,...
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
Deprecated.