22 #include <boost/shared_ptr.hpp>
23 #include <boost/enable_shared_from_this.hpp>
27 #define SDF_VERSION "1.4"
35 typedef boost::shared_ptr<SDF>
SDFPtr;
41 void addURIPath(
const std::string &_uri,
const std::string &_path);
45 void setFindCallback(boost::function<std::string (
const std::string &)> _cb);
51 class Element :
public boost::enable_shared_from_this<Element>
94 private:
void ToString(
const std::string &_prefix,
96 public: std::string ToString(
100 const std::string &_type,
101 const std::string &_defaultvalue,
103 const std::string &_description=
"")
106 public:
void AddValue(
const std::string &_type,
107 const std::string &_defaultValue,
bool _required,
108 const std::string &_description=
"")
150 public:
int GetValueInt(
const std::string &_key =
"")
156 public:
unsigned int GetValueUInt(
const std::string &_key =
"")
175 public:
template<
typename T>
176 T
Get(
const std::string &_key =
"")
180 if (_key.empty() && this->value)
181 this->value->Get<T>(result);
182 else if (!_key.empty())
192 gzerr <<
"Unable to find value for key[" << _key <<
"]\n";
228 const std::
string &_name = "") const GAZEBO_DEPRECATED(1.6);
231 const std::
string &_name) GAZEBO_DEPRECATED(1.6);
233 const std::
string &_name) GAZEBO_DEPRECATED(1.6);
246 public:
void Update() GAZEBO_DEPRECATED(1.6);
247 public:
void Reset() GAZEBO_DEPRECATED(1.6);
250 const std::
string &_filename) GAZEBO_DEPRECATED(1.6);
251 public: std::
string GetInclude() const GAZEBO_DEPRECATED(1.6);
254 public: std::
string GetDescription() const GAZEBO_DEPRECATED(1.6);
258 const std::
string &_desc) GAZEBO_DEPRECATED(1.6);
263 private: boost::shared_ptr<
Param> CreateParam(const std::
string &_key,
264 const std::
string &_type, const std::
string &_defaultValue,
266 const std::
string &_description="") GAZEBO_DEPRECATED(1.6);
269 const std::
string &_name) const GAZEBO_DEPRECATED(1.6);
271 private: std::
string name;
272 private: std::
string required;
273 private: std::
string description;
274 private:
bool copyChildren;
291 private: std::
string includeFilename;
307 public:
void SetFromString(