Commit a46f8502 authored by Bryan Berthou's avatar Bryan Berthou
Browse files

refs#16

In NumA++ (trunk) :
- Create FunctorUtils class : add missing method to create FunctorMD.
parent a58ef37b
......@@ -4,7 +4,7 @@
/**
* @file Integrator1D.h
* @author Bryan BERTHOU (SPhN / CEA Saclay)
* @date 15 February 2016
* @date February 15, 2016
* @version 1.0
*/
......@@ -44,6 +44,7 @@ public:
virtual void configure(const ElemUtils::Parameters &parameters);
//TODO moved to FunctorUtils ; remove this definition
template<typename PointerToObj, typename PointerToMemFn>
static Functor1D<PointerToObj, PointerToMemFn>* newIntegrationFunctor(
PointerToObj* object, PointerToMemFn function) {
......
#ifndef FUNCTOR_UTILS_H
#define FUNCTOR_UTILS_H
/**
* @file FunctorUtils.h
* @author Bryan BERTHOU (SPhN / CEA Saclay)
* @date October 07, 2016
* @version 1.0
*/
#include "../integration/many_dimension/FunctorMD.h"
#include "../integration/one_dimension/Functor1D.h"
namespace NumA {
/**
* @class FunctorUtils
*
* @brief
*/
class FunctorUtils {
public:
template<typename PointerToObj, typename PointerToMemFn>
static Functor1D<PointerToObj, PointerToMemFn>* newIntegrationFunctor(
PointerToObj* object, PointerToMemFn function) {
return new Functor1D<PointerToObj, PointerToMemFn>(object, function);
}
template<typename PointerToObj, typename PointerToMemFn>
static FunctorMD<PointerToObj, PointerToMemFn>* newFunctorMD(
PointerToObj* object, PointerToMemFn function) {
return new FunctorMD<PointerToObj, PointerToMemFn>(object, function);
}
};
} /* namespace NumA */
#endif /* FUNCTOR_UTILS_H */
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment