Go to the documentation of this file.
37 #include <boost/shared_ptr.hpp>
136 Config(
const QVariant& value);
189 void mapSetValue(
const QString& key,
const QVariant& value);
212 bool mapGetValue(
const QString& key, QVariant* value_out)
const;
222 bool mapGetInt(
const QString& key,
int* value_out)
const;
232 bool mapGetFloat(
const QString& key,
float* value_out)
const;
242 bool mapGetBool(
const QString& key,
bool* value_out)
const;
252 bool mapGetString(
const QString& key, QString* value_out)
const;
256 void setValue(
const QVariant& value);
317 QMap<QString, Config::NodePtr>::const_iterator
iterator_;
bool isValid() const
Returns true if the internal Node reference is valid, false if not. Same as (getType() !...
bool isValid()
Return true if the iterator currently points to a valid entry, false if not.
Config()
Default constructor. Creates an empty config object.
void start()
Resets the iterator to the start of the map.
int listLength() const
Returns the length of the List in this Node, or 0 if this Node does not have type List.
MapIterator()
Private constructor enforces that MapIterators are only made by their friend the Config class.
QString currentKey()
Return the name of the current map entry.
Type
Possible types a Config Node can have are Map, List, Value, and Empty. Invalid means the Config objec...
Config mapGetChild(const QString &key) const
If the referenced Node is a Map and it has a child with the given key, return a reference to the chil...
void makeValid()
If the node pointer is NULL, this sets it to a new empty node.
Config mapMakeChild(const QString &key)
Create a child node stored with the given key, and return the child.
bool mapGetValue(const QString &key, QVariant *value_out) const
Convenience function for looking up a named value.
Config listAppendNew()
Ensure the referenced Node is of type List, append a new Empty Node to the end of the list,...
bool mapGetBool(const QString &key, bool *value_out) const
Convenience function for looking up a named boolean.
void copy(const Config &source)
Make this a deep copy of source.
Type getType() const
Return the Type of the referenced Node, or Invalid if this Config does not refer to a Node at all.
Config listChildAt(int i) const
Return the i'th child in the list, if the referenced Node has type List. Returns an Invalid Config if...
QMap< QString, Config::NodePtr >::const_iterator iterator_
Config currentChild()
Return a Config reference to the current map entry.
void setType(Type new_type)
Set the type of this Config Node.
bool mapGetString(const QString &key, QString *value_out) const
Convenience function for looking up a named string.
boost::shared_ptr< Node > NodePtr
bool mapGetInt(const QString &key, int *value_out) const
Convenience function for looking up a named integer.
void mapRemoveChild(const QString &key)
Remove child node with given key from the Map.
Iterator class for looping over all entries in a Map type Config Node.
bool mapGetFloat(const QString &key, float *value_out) const
Convenience function for looking up a named float.
MapIterator mapIterator() const
Return a new iterator for looping over key/value pairs.
void advance()
Advance iterator to next entry.
void setValue(const QVariant &value)
Ensures this is a valid Config object, sets the type to Value then sets the value.
Configuration data storage class.
void mapSetValue(const QString &key, const QVariant &value)
Set a named child to the given value.
static Config invalidConfig()
QVariant getValue() const
If this config object is valid and is a Value type, this returns its value. Otherwise it returns an i...
rviz
Author(s): Dave Hershberger, David Gossow, Josh Faust, William Woodall
autogenerated on Fri Dec 13 2024 03:31:02