Kerbal Space Program  1.12.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Public Member Functions | Properties | List of all members
KSP.IO.PluginConfigNode Class Reference

A node containing configuration information More...

Public Member Functions

PluginConfigNode GetParent ()
 Gets the parent of this node. More...
 
GetValue< T > (string key)
 Get the value of a configuration key. More...
 
GetValue< T > (string key, T _default)
 Get the value of a configuration key. More...
 
 PluginConfigNode (PluginConfigNode parent)
 Specify the parent object when creating a node. More...
 
 PluginConfigNode ()
 Create a new node. More...
 
void SetValue (string key, object value)
 Set the value of a configuration key More...
 

Properties

Object this[string key] [get, set]
 Get or set the value of a configuration key More...
 

Detailed Description

A node containing configuration information

Constructor & Destructor Documentation

KSP.IO.PluginConfigNode.PluginConfigNode ( PluginConfigNode  parent)
inline

Specify the parent object when creating a node.

Parameters
parent
KSP.IO.PluginConfigNode.PluginConfigNode ( )
inline

Create a new node.

Member Function Documentation

PluginConfigNode KSP.IO.PluginConfigNode.GetParent ( )
inline

Gets the parent of this node.

Returns
PluginConfigNode or null if root node.
T KSP.IO.PluginConfigNode.GetValue< T > ( string  key)
inline

Get the value of a configuration key.

Template Parameters
TType you want returned
Parameters
keyThe configuration key which you want to fetch
Returns
Either null (or equivalent) for an inexistent key, or the value you wanted
T KSP.IO.PluginConfigNode.GetValue< T > ( string  key,
_default 
)
inline

Get the value of a configuration key.

Template Parameters
TType you want returned
Parameters
keyThe configuration key which you want to fetch
_defaultThe default value returned when the key cannot be found.
Returns
Either default for an inexistent key, or the value you wanted
void KSP.IO.PluginConfigNode.SetValue ( string  key,
object  value 
)
inline

Set the value of a configuration key

Parameters
keyThe name of the configuration key
valueThe value you wish to set it to

Property Documentation

Object KSP.IO.PluginConfigNode.this[string key]
getset

Get or set the value of a configuration key

Parameters
keyThe name of the configuration value
Returns
The value, or null.

The documentation for this class was generated from the following file: