Bottle 2D - Lua API 1.0.0
All you need to create games using bottle2D.
|
A config node represent a node in the configuration file (like an XML node). More...
#include <header.hpp>
Public Member Functions | |
string | GetString (string key) |
Get the string corresponding to key in this node. | |
number | GetNumber (string key) |
Get the number corresponding to key in this node. | |
bool | ChildExists (string key) |
Retrun true if the child key exists (it can be string / number / child node) | |
nil | SetValue (string key, string value) |
Set / create a string with key. | |
nil | SetValue (string key, number value) |
Set / create a number with key. | |
ConfigNode | AccessNode (string key) |
Get the ConfigNode corresponding to key, if it exists, otherwise, create a child ConfigNode named "key" in this ConfigNode and return it. | |
nil | Remove (string key) |
Remove the child named key. | |
nil | Clear () |
Clear the ConfigNode (delete all childs) |
A config node represent a node in the configuration file (like an XML node).
You can add data to the node with a key and add child node.
ConfigNode ConfigNode::AccessNode | ( | string | key | ) |
Get the ConfigNode corresponding to key, if it exists, otherwise, create a child ConfigNode named "key" in this ConfigNode and return it.
bool ConfigNode::ChildExists | ( | string | key | ) |
Retrun true if the child key exists (it can be string / number / child node)
nil ConfigNode::Clear | ( | ) |
Clear the ConfigNode (delete all childs)
number ConfigNode::GetNumber | ( | string | key | ) |
Get the number corresponding to key in this node.
string ConfigNode::GetString | ( | string | key | ) |
Get the string corresponding to key in this node.
nil ConfigNode::Remove | ( | string | key | ) |
Remove the child named key.
nil ConfigNode::SetValue | ( | string | key, |
string | value | ||
) |
Set / create a string with key.
nil ConfigNode::SetValue | ( | string | key, |
number | value | ||
) |
Set / create a number with key.