Difference between revisions of "API:PluginConfigNode"
From Kerbal Space Program Wiki
m (N3X15 moved page PluginConfigNode to API:PluginConfigNode) |
|||
(One intermediate revision by the same user not shown) | |||
Line 4: | Line 4: | ||
A node full of configuration values. | A node full of configuration values. | ||
− | |||
{{PropertiesStart}} | {{PropertiesStart}} | ||
− | {{ | + | {{Property |
− | |type= | + | |type=Object |
− | | | + | |name=this[{{arg|string|key}}] |
− | | | + | |desc=Get or set the value of a configuration key |
− | |desc=Get or set a | + | |hasget=1 |
+ | |hasset=1 | ||
}} | }} | ||
{{PropertiesEnd}} | {{PropertiesEnd}} | ||
Line 18: | Line 18: | ||
|returndesc= | |returndesc= | ||
|name=SetValue | |name=SetValue | ||
− | |args=string key, object value | + | |args={{arg|string|key}}, {{arg|object|value}} |
|desc=Set the value of a configuration key | |desc=Set the value of a configuration key | ||
}} | }} | ||
Line 32: | Line 32: | ||
|returndesc= | |returndesc= | ||
|name=GetValue<T> | |name=GetValue<T> | ||
− | |args=string key | + | |args={{arg|string|key}} |
|desc=Get the value of a configuration key. | |desc=Get the value of a configuration key. | ||
}} | }} | ||
Line 39: | Line 39: | ||
|returndesc= | |returndesc= | ||
|name=GetValue<T> | |name=GetValue<T> | ||
− | |args=string key, T _default | + | |args={{arg|string|key}}, {{arg|T|_default}} |
|desc=Get the value of a configuration key. | |desc=Get the value of a configuration key. | ||
}} | }} | ||
{{MethodsEnd}} | {{MethodsEnd}} |
Latest revision as of 22:39, 12 October 2012
KSP.IO Namespace
BinaryReader ·
BinaryWriter ·
File ·
FileInfo ·
FileStream ·
IOException ·
IOTools ·
IOUtils ·
MemoryStream ·
PluginConfigNode ·
PluginConfiguration ·
TextReader ·
TextWriter
PluginConfigNode
- See PluginConfiguration for a full description.
A node full of configuration values.
Properties
The following are public properties available in PluginConfigNode.
Signature | Description |
---|---|
Object this[string key] { get; set; } | Get or set the value of a configuration key |
Methods
The following are methods included in PluginConfigNode.
Signature | Description |
---|---|
void SetValue(string key, object value) | Set the value of a configuration key |
PluginConfigNode GetParent() | Gets the parent of this node. |
T GetValue<T>(string key) | Get the value of a configuration key. |
T GetValue<T>(string key, T _default) | Get the value of a configuration key. |