GAMS
1.2.2
|
A factory class for creating Java Algorithms. More...
#include <JavaAlgorithm.h>
Public Member Functions | |
JavaAlgorithmFactory (jobject obj) | |
Constructor. More... | |
virtual | ~JavaAlgorithmFactory () |
Destructor. More... | |
virtual BaseAlgorithm * | create (const madara::knowledge::KnowledgeMap &args, madara::knowledge::KnowledgeBase *knowledge, platforms::BasePlatform *platform, variables::Sensors *sensors, variables::Self *self, variables::Agents *agents) |
Creates a Java Algorithm. More... | |
jobject | get_java_instance (void) |
Returns the Java instance that implements from AlgorithmFactory. More... | |
void | set_agents (variables::Agents *agents) |
Sets list of agents participating in swarm. More... | |
void | set_knowledge (madara::knowledge::KnowledgeBase *knowledge) |
Sets the knowledge base. More... | |
void | set_platform (platforms::BasePlatform *platform) |
Sets the map of platform names to platform information. More... | |
void | set_self (variables::Self *self) |
Sets self-referencing variables. More... | |
void | set_sensors (variables::Sensors *sensors) |
Sets the map of sensor names to sensor information. More... | |
Protected Attributes | |
variables::Agents * | agents_ |
list of agents participating in the swarm More... | |
madara::knowledge::KnowledgeBase * | knowledge_ |
knowledge base containing variables More... | |
jobject | obj_ |
the Java object with callable methods More... | |
platforms::BasePlatform * | platform_ |
platform variables More... | |
variables::Self * | self_ |
self-referencing variables More... | |
variables::Sensors * | sensors_ |
sensor variables More... | |
A factory class for creating Java Algorithms.
Definition at line 156 of file JavaAlgorithm.h.
gams::algorithms::JavaAlgorithmFactory::JavaAlgorithmFactory | ( | jobject | obj | ) |
Constructor.
obj | the Java object that implements AlgorithmFactory |
|
virtual |
Destructor.
|
virtual |
Creates a Java Algorithm.
args | first arg is where to store the executions tracker in the knowledge base. Default is ".executions" when no args are provided. |
knowledge | the knowledge base to use |
platform | the platform. This will be set by the controller in init_vars. |
sensors | the sensor info. This will be set by the controller in init_vars. |
self | self-referencing variables. This will be set by the controller in init_vars |
agents | the list of agents, which is dictated by init_vars when a number of processes is set. This will be set by the controller in init_vars |
Implements gams::algorithms::AlgorithmFactory.
jobject gams::algorithms::JavaAlgorithmFactory::get_java_instance | ( | void | ) |
Returns the Java instance that implements from AlgorithmFactory.
|
inherited |
Sets list of agents participating in swarm.
agents | agents in the swarm |
|
inherited |
Sets the knowledge base.
knowledge | the knowledge base to use |
|
inherited |
Sets the map of platform names to platform information.
platform | the platform to use |
|
inherited |
Sets self-referencing variables.
self | self-referencing variables |
|
inherited |
Sets the map of sensor names to sensor information.
sensors | map of sensor names to sensor information |
|
protectedinherited |
list of agents participating in the swarm
Definition at line 139 of file AlgorithmFactory.h.
|
protectedinherited |
knowledge base containing variables
Definition at line 136 of file AlgorithmFactory.h.
|
protected |
the Java object with callable methods
Definition at line 203 of file JavaAlgorithm.h.
|
protectedinherited |
platform variables
Definition at line 142 of file AlgorithmFactory.h.
|
protectedinherited |
self-referencing variables
Definition at line 145 of file AlgorithmFactory.h.
|
protectedinherited |
sensor variables
Definition at line 148 of file AlgorithmFactory.h.