The controller's algorithm factory.
More...
#include <AlgorithmFactoryRepository.h>
The controller's algorithm factory.
Definition at line 79 of file AlgorithmFactoryRepository.h.
◆ AlgorithmFactoryRepository()
Constructor.
- Parameters
-
knowledge | the knowledge base |
sensors | variables for all sensors |
platform | the current platform |
self | self-referencing variables |
agents | agents of the swarm |
◆ ~AlgorithmFactoryRepository()
gams::algorithms::AlgorithmFactoryRepository::~AlgorithmFactoryRepository |
( |
| ) |
|
◆ add()
void gams::algorithms::AlgorithmFactoryRepository::add |
( |
const std::vector< std::string > & |
aliases, |
|
|
AlgorithmFactory * |
factory |
|
) |
| |
Adds an algorithm factory.
- Parameters
-
aliases | the named aliases for the factory. All aliases will be converted to lower case |
factory | the factory for creating an algorithm |
- Returns
- the new algorithm
◆ create()
BaseAlgorithm* gams::algorithms::AlgorithmFactoryRepository::create |
( |
const std::string & |
type, |
|
|
const madara::knowledge::KnowledgeMap & |
args = madara::knowledge::KnowledgeMap() |
|
) |
| |
Creates an algorithm.
- Parameters
-
type | type of algorithm to create |
args | a vector of Knowledge Record arguments |
- Returns
- the new algorithm
◆ initialize_default_mappings()
void gams::algorithms::AlgorithmFactoryRepository::initialize_default_mappings |
( |
void |
| ) |
|
Initializes factories for all supported GAMS algorithms.
◆ set_agents()
void gams::algorithms::AlgorithmFactoryRepository::set_agents |
( |
variables::Agents * |
agents | ) |
|
Sets list of agents participating in swarm.
- Parameters
-
agents | agents in the swarm |
◆ set_knowledge()
void gams::algorithms::AlgorithmFactoryRepository::set_knowledge |
( |
madara::knowledge::KnowledgeBase * |
knowledge | ) |
|
Sets the knowledge base.
- Parameters
-
knowledge | the knowledge base to use |
◆ set_platform()
Sets the map of platform names to platform information.
- Parameters
-
platform | the platform to use |
◆ set_self()
void gams::algorithms::AlgorithmFactoryRepository::set_self |
( |
variables::Self * |
self | ) |
|
Sets self-referencing variables.
- Parameters
-
self | self-referencing variables |
◆ set_sensors()
void gams::algorithms::AlgorithmFactoryRepository::set_sensors |
( |
variables::Sensors * |
sensors | ) |
|
Sets the map of sensor names to sensor information.
- Parameters
-
sensors | map of sensor names to sensor information |
◆ agents_
◆ factory_map_
◆ init_finished_
bool gams::algorithms::AlgorithmFactoryRepository::init_finished_ |
|
protected |
◆ init_started_
bool gams::algorithms::AlgorithmFactoryRepository::init_started_ |
|
protected |
◆ knowledge_
madara::knowledge::KnowledgeBase* gams::algorithms::AlgorithmFactoryRepository::knowledge_ |
|
protected |
◆ platform_
◆ self_
◆ sensors_
The documentation for this class was generated from the following file: