Klamp't
0.8.1
|
A class to simplify the loading of different controllers at run time. More...
#include <Controller.h>
Static Public Member Functions | |
static void | RegisterDefault (Robot &robot) |
static void | Register (RobotController *controller) |
static void | Register (const char *name, RobotController *controller) |
static shared_ptr< RobotController > | CreateByName (const char *name) |
static shared_ptr< RobotController > | CreateByName (const char *name, Robot &robot) |
static shared_ptr< RobotController > | Load (const char *fn, Robot &robot) |
static bool | Save (RobotController *controller, const char *fn) |
static shared_ptr< RobotController > | Load (TiXmlElement *in, Robot &robot) |
static bool | Save (RobotController *controller, TiXmlElement *out) |
Static Public Attributes | |
static std::map< std::string, shared_ptr< RobotController > > | controllers |
A class to simplify the loading of different controllers at run time.
First a list of controllers is provided to Register(), or RegisterDefault() can be called. Then CreateByName() is called to retreive the named controller.
Note that Register takes ownership of the pointers.