WrapperParam.h
Classes
- WrapperParam -- Parameter handling for wrapped function objects (full description)
Interface
- Public Members
- WrapperParam()
- explicit WrapperParam(const T &par)
- explicit WrapperParam(const Vector<T> &par)
- WrapperParam(const WrapperParam<T> &other)
- WrapperParam<T> &operator=(const WrapperParam<T> &other)
- virtual ~WrapperParam()
- virtual const String &name() const
Review Status
- Reviewed By:
- UNKNOWN
- Date Reviewed:
- before2004/08/25
Prerequisite
Synopsis
This class is provided to enable easy specialization for the actual
FunctionWrapper class.
Example
Float func(const Vector<Float>& x) {return x(0)*x(1);} // x*y
// Convert C++ functions to Function
FunctionWrapper<Float> Func(func, 2);
Template Type Argument Requirements (T)
- T should have standard numerical operators and exp() function. Current
implementation only tested for real types (and their AutoDiffs).
Thrown Exceptions
- Assertion in debug mode if attempt is made to set a negative width
- AipsError if incorrect parameter number specified.
To Do
Member Description
Construct with the given parameters
WrapperParam(const WrapperParam<T> &other)
Copy constructor (deep copy)
WrapperParam<T> &operator=(const WrapperParam<T> &other)
Copy assignment (deep copy)
Destructor
virtual const String &name() const
Give name of function