map id to parameters More...
#include <parameter_container.h>
Public Types | |
typedef std::map< int, Parameter * > | BaseClass |
Public Member Functions | |
bool | addParameter (Parameter *p) |
add parameter to the container More... | |
void | clear () |
Parameter * | detachParameter (int id) |
remove a parameter from the container, i.e., the user now owns the pointer More... | |
Parameter * | getParameter (int id) |
return a parameter based on its ID More... | |
bool | isMainStorage () const |
ParameterContainer (bool isMainStorage_=true) | |
virtual bool | read (std::istream &is, const std::map< std::string, std::string > *renamedMap=0) |
read parameters from a stream More... | |
virtual bool | write (std::ostream &os) const |
write the data to a stream More... | |
virtual | ~ParameterContainer () |
Protected Attributes | |
bool | _isMainStorage |
map id to parameters
Definition at line 41 of file parameter_container.h.
typedef std::map<int, Parameter*> g2o::ParameterContainer::BaseClass |
Definition at line 44 of file parameter_container.h.
g2o::ParameterContainer::ParameterContainer | ( | bool | isMainStorage_ = true | ) |
create a container for the parameters.
isMainStorage_ | pointers to the parameters are owned by this container, i.e., freed in its constructor |
Definition at line 42 of file parameter_container.cpp.
|
virtual |
Definition at line 56 of file parameter_container.cpp.
bool g2o::ParameterContainer::addParameter | ( | Parameter * | p | ) |
add parameter to the container
Definition at line 60 of file parameter_container.cpp.
void g2o::ParameterContainer::clear | ( | ) |
Definition at line 47 of file parameter_container.cpp.
Parameter * g2o::ParameterContainer::detachParameter | ( | int | id | ) |
remove a parameter from the container, i.e., the user now owns the pointer
Definition at line 77 of file parameter_container.cpp.
Parameter * g2o::ParameterContainer::getParameter | ( | int | id | ) |
return a parameter based on its ID
Definition at line 70 of file parameter_container.cpp.
|
inline |
Definition at line 62 of file parameter_container.h.
|
virtual |
read parameters from a stream
Definition at line 97 of file parameter_container.cpp.
|
virtual |
write the data to a stream
Definition at line 86 of file parameter_container.cpp.
|
protected |
Definition at line 69 of file parameter_container.h.