casacore
Loading...
Searching...
No Matches
casacore::WrapperBase< T > Class Template Referenceabstract

More...

#include <WrapperBase.h>

Public Member Functions

 WrapperBase ()
 Default constructor: zero dimension.
 WrapperBase (const uInt dim)
 Standard constructor.
virtual ~WrapperBase ()
 Destructor.
virtual T eval (typename Function< T >::FunctionArg x, const Vector< T > &par) const =0
 Evaluate the function at x.
virtual uInt ndim () const
 Get the dimensionality.

Protected Attributes

uInt ndim_p
 Dimensionality.
Vector< T > arg_p
 Vector argument interface.

Private Member Functions

 WrapperBase (const WrapperBase< T > &other)
 Copy constructor and assignment (not implemented).
WrapperBase< T > & operator= (const WrapperBase< T > &other)

Detailed Description

template<class T>
class casacore::WrapperBase< T >

Aid in constructing function objects from C++ functions

Intended use:

Internal

Review Status

Reviewed By:
UNKNOWN
Date Reviewed:
before2004/08/25

Prerequisite

Synopsis

This base class is provided to enable compile time selection of the appropriate function call through WrapperData.

Example

Float func(const Vector<Float>& x) { return x(0)*x(1); } // x*y
// Convert C++ functions to Functionals
FunctionWrapper<Float> Func(func, 2);
float Float
Definition aipstype.h:52

Definition at line 64 of file WrapperBase.h.

Constructor & Destructor Documentation

◆ WrapperBase() [1/3]

template<class T>
casacore::WrapperBase< T >::WrapperBase ( )
inline

◆ WrapperBase() [2/3]

template<class T>
casacore::WrapperBase< T >::WrapperBase ( const uInt dim)
inlineexplicit

Standard constructor.

Definition at line 70 of file WrapperBase.h.

References arg_p, and ndim_p.

◆ ~WrapperBase()

template<class T>
virtual casacore::WrapperBase< T >::~WrapperBase ( )
inlinevirtual

Destructor.

Definition at line 73 of file WrapperBase.h.

◆ WrapperBase() [3/3]

template<class T>
casacore::WrapperBase< T >::WrapperBase ( const WrapperBase< T > & other)
private

Copy constructor and assignment (not implemented).

References WrapperBase().

Member Function Documentation

◆ eval()

◆ ndim()

template<class T>
virtual uInt casacore::WrapperBase< T >::ndim ( ) const
inlinevirtual

Get the dimensionality.

Definition at line 84 of file WrapperBase.h.

References ndim_p.

◆ operator=()

template<class T>
WrapperBase< T > & casacore::WrapperBase< T >::operator= ( const WrapperBase< T > & other)
private

References WrapperBase().

Member Data Documentation

◆ arg_p

◆ ndim_p


The documentation for this class was generated from the following files: