Factory singleton class that creates a HydrodynamicModel from sdf. More...
#include <HydrodynamicModel.hh>
Public Member Functions | |
HydrodynamicModel * | CreateHydrodynamicModel (sdf::ElementPtr _sdf, physics::LinkPtr _link) |
Create HydrodynamicModel object according to its sdf Description. More... | |
bool | RegisterCreator (const std::string &_identifier, HydrodynamicModelCreator _creator) |
Register a class with its creator. More... | |
Static Public Member Functions | |
static HydrodynamicModelFactory & | GetInstance () |
Returns the singleton instance of this factory. More... | |
Private Member Functions | |
HydrodynamicModelFactory () | |
Constructor is private since this is a singleton. More... | |
Private Attributes | |
std::map< std::string, HydrodynamicModelCreator > | creators_ |
Map of each registered identifier to its corresponding creator. More... | |
Factory singleton class that creates a HydrodynamicModel from sdf.
Definition at line 114 of file HydrodynamicModel.hh.
|
inlineprivate |
Constructor is private since this is a singleton.
Definition at line 128 of file HydrodynamicModel.hh.
HydrodynamicModel * gazebo::HydrodynamicModelFactory::CreateHydrodynamicModel | ( | sdf::ElementPtr | _sdf, |
physics::LinkPtr | _link | ||
) |
Create HydrodynamicModel object according to its sdf Description.
Definition at line 161 of file HydrodynamicModel.cc.
|
static |
Returns the singleton instance of this factory.
Definition at line 186 of file HydrodynamicModel.cc.
bool gazebo::HydrodynamicModelFactory::RegisterCreator | ( | const std::string & | _identifier, |
HydrodynamicModelCreator | _creator | ||
) |
Register a class with its creator.
Definition at line 193 of file HydrodynamicModel.cc.
|
private |
Map of each registered identifier to its corresponding creator.
Definition at line 131 of file HydrodynamicModel.hh.