SG++-Doxygen-Documentation
sgpp::combigrid::GeneralFunction< Out, In > Class Template Reference

Wrapper for std::function<Out(In)>. More...

#include <GeneralFunction.hpp>

Public Types

typedef std::function< Out(In)> function_type
 
typedef Out output_type
 

Public Member Functions

Out call (In in) const
 Evaluates the function (for python use etc., does the same as operator()). More...
 
 GeneralFunction (Out(*ptr)(In))
 for function pointers More...
 
template<typename T >
 GeneralFunction (T const &f)
 for lambdas or function objects More...
 
 GeneralFunction ()
 Default constructor, creating a constant zero function. More...
 
function_type getStdFunction () const
 
Out operator() (In in) const
 Evaluates the function. More...
 

Detailed Description

template<typename Out, typename In>
class sgpp::combigrid::GeneralFunction< Out, In >

Wrapper for std::function<Out(In)>.

This is necessary because SWIG can't handle std::function objects properly.

Member Typedef Documentation

template<typename Out, typename In>
typedef std::function<Out(In)> sgpp::combigrid::GeneralFunction< Out, In >::function_type
template<typename Out, typename In>
typedef Out sgpp::combigrid::GeneralFunction< Out, In >::output_type

Constructor & Destructor Documentation

template<typename Out, typename In>
sgpp::combigrid::GeneralFunction< Out, In >::GeneralFunction ( Out(*)(In)  ptr)
inlineexplicit

for function pointers

template<typename Out, typename In>
template<typename T >
sgpp::combigrid::GeneralFunction< Out, In >::GeneralFunction ( T const &  f)
inlineexplicit

for lambdas or function objects

template<typename Out, typename In>
sgpp::combigrid::GeneralFunction< Out, In >::GeneralFunction ( )
inline

Default constructor, creating a constant zero function.

Member Function Documentation

template<typename Out, typename In>
Out sgpp::combigrid::GeneralFunction< Out, In >::call ( In  in) const
inline

Evaluates the function (for python use etc., does the same as operator()).

template<typename Out, typename In>
function_type sgpp::combigrid::GeneralFunction< Out, In >::getStdFunction ( ) const
inline
template<typename Out, typename In>
Out sgpp::combigrid::GeneralFunction< Out, In >::operator() ( In  in) const
inline

Evaluates the function.


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