![]() |
Parasol Planning Library (PPL)
|
#include <TMPMethodSet.h>
Public Types | |
Local Types | |
typedef std::shared_ptr< TMPMethod > | TMPMethodPointer |
typedef std::map< std::string, TMPMethodPointer > | TMPMethodMap |
typedef std::function< TMPMethodPointer(XMLNode &)> | FactoryType |
typedef std::map< std::string, FactoryType > | FactoryMap |
typedef TMPMethodMap::iterator | iterator |
typedef TMPMethodMap::const_iterator | const_iterator |
Public Member Functions | |
Construction | |
template<typename TMPMethodTypeList > | |
TMPMethodSet (TMPLibrary *const _p, const TMPMethodTypeList &_mtl, const std::string &_name) | |
TMPMethod Accessors | |
void | ParseXML (XMLNode &_node) |
Add the appropriate TMPMethods from an XML node. More... | |
void | AddMethod (XMLNode &_node) |
void | AddMethod (TMPMethodPointer _e, const std::string &_label) |
TMPMethodPointer | GetMethod (const std::string &_label) |
iterator | FindMethod (std::string _label) |
void | Initialize () |
void | Print (std::ostream &_os) const |
Display the instantiated TMPMethods. More... | |
Iteration | |
Iterate over the instantiated TMPMethods. | |
iterator | begin () noexcept |
iterator | end () noexcept |
const_iterator | begin () const noexcept |
const_iterator | end () const noexcept |
Defines basic TMPMethod container class to hold TMPMethods (for classes like DistanceMetricTMPMethod, LocalPlannerTMPMethod, etc).
TMPMethodTypeList must be defined within templated class of MPTraits e.g., TMPMethod = NeighborhoodFinderTMPMethod TMPMethodTypeList = boost::mpl::list<BruteForceNF, BandsNF, ...> e.g., TMPMethod = LocalPlannerTMPMethod TMPMethodTypeList = boost::mpl::list<Straightline, RotateAtS, ...>
TMPMethodSet first parses the TMPMethodTypeList and adds all enumerated TMPMethods to its universe of TMPMethod types. Then, specific instantiations of those types can be added to its map of available TMPMethods by calling 'AddTMPMethod'.
typedef TMPMethodMap::const_iterator TMPMethodSet< TMPMethod >::const_iterator |
typedef std::map<std::string, FactoryType> TMPMethodSet< TMPMethod >::FactoryMap |
typedef std::function<TMPMethodPointer(XMLNode&)> TMPMethodSet< TMPMethod >::FactoryType |
typedef TMPMethodMap::iterator TMPMethodSet< TMPMethod >::iterator |
typedef std::map<std::string, TMPMethodPointer> TMPMethodSet< TMPMethod >::TMPMethodMap |
typedef std::shared_ptr<TMPMethod> TMPMethodSet< TMPMethod >::TMPMethodPointer |
TMPMethodSet< TMPMethod >::TMPMethodSet | ( | TMPLibrary *const | _p, |
const TMPMethodTypeList & | _mtl, | ||
const std::string & | _name | ||
) |
Construct a TMPMethodSet from a TMPMethodTypeList defined in the MPTraits class.
_mtl | An instance of the TMPMethod type list. |
_name | The name of this TMPMethod set. |
void TMPMethodSet< TMPMethod >::AddMethod | ( | TMPMethodPointer | _e, |
const std::string & | _label | ||
) |
void TMPMethodSet< TMPMethod >::AddMethod | ( | XMLNode & | _node | ) |
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
TMPMethodSet< TMPMethod >::iterator TMPMethodSet< TMPMethod >::FindMethod | ( | std::string | _label | ) |
Find a TMPMethod iterator.
_label | The TMPMethod label. |
TMPMethodSet< TMPMethod >::TMPMethodPointer TMPMethodSet< TMPMethod >::GetMethod | ( | const std::string & | _label | ) |
Get a TMPMethod by label.
_label | The TMPMethod label. |
void TMPMethodSet< TMPMethod >::Initialize |
void TMPMethodSet< TMPMethod >::ParseXML | ( | XMLNode & | _node | ) |
Add the appropriate TMPMethods from an XML node.
void TMPMethodSet< TMPMethod >::Print | ( | std::ostream & | _os | ) | const |
Display the instantiated TMPMethods.