|
Classdesc 3.44
|
REST processor registry. More...
#include <RESTProcess_base.h>


Public Member Functions | |
| template<class T> | |
| RESTProcess_t (T &obj) | |
| RESTProcess_t (const RPPtr &p) | |
| Construct from an object that RPPPtr wraps. | |
| void | add (string d, RESTProcessBase *rp) |
| ownership of rp is passed | |
| void | add (string d, RESTProcessFunctionBase *rp) |
| ownership of rp is passed | |
| RPPtr | process (const std::string &query, const REST_PROCESS_BUFFER &jin) |
| template<class F> | |
| void | defineFunctionArgTypes () |
| define all arguments of F | |
| template<class T, class... Args> | |
| void | addFactory (const std::string &typeName, const std::function< void(const std::string &objName)> &callback=nullptr) |
REST processor registry.
| RESTProcess_t | ( | T & | obj | ) |
populate this map with the members of obj. T must be a classdescified type, otherwise this is equivalent to a default contructor
| void addFactory | ( | const std::string & | typeName, |
| const std::function< void(const std::string &objName)> & | callback = nullptr ) |
adds a factory function for creating objects of type T.
| T | type of objects this factory will create |
| Args | are the types of arguments to be passed to T's constructor |
| typeName | alias for the factory - usually the unqualified type name |
| callback | an optional callback that is run whenever a new object is created The factory gets called with a string argument giving the new objects name in the registry, followed by the arguments for T's constructor, if any |
References add().