Class Value
A base value type for config data abstract representations, to be serialized with an
IConfigProvider. If a Value is null, then
that represents just that: a null
in whatever serialization is being used.
Also contains factory functions for all derived types.
Inherited Members
Namespace: IPA.Config.Data
Assembly: IPA.Loader.dll
Syntax
public abstract class Value
Methods
| Improve this Doc View SourceBool(Boolean)
Declaration
public static Boolean Bool(bool val)
Parameters
Type | Name | Description |
---|---|---|
Boolean | val | the value to wrap |
Returns
Type | Description |
---|---|
Boolean | a Boolean wrapping |
See Also
| Improve this Doc View SourceFloat(Decimal)
Creates a new FloatingPoint wrapping a Decimal.
Declaration
public static FloatingPoint Float(decimal val)
Parameters
Type | Name | Description |
---|---|---|
Decimal | val | the value to wrap |
Returns
Type | Description |
---|---|
FloatingPoint | a FloatingPoint wrapping |
See Also
| Improve this Doc View SourceFrom(Boolean)
Declaration
public static Boolean From(bool val)
Parameters
Type | Name | Description |
---|---|---|
Boolean | val | the value to wrap |
Returns
Type | Description |
---|---|
Boolean | a Boolean wrapping |
See Also
| Improve this Doc View SourceFrom(IDictionary<String, Value>)
Creates a new Map holding the content of an IDictionary<TKey,TValue> of String to Value.
Declaration
public static Map From(IDictionary<string, Value> vals)
Parameters
Type | Name | Description |
---|---|---|
IDictionary<String, Value> | vals |
Returns
Type | Description |
---|---|
Map | a Map containing the content of |
See Also
| Improve this Doc View SourceFrom(IEnumerable<Value>)
Creates a new List holding the content of an IEnumerable<T> of Value.
Declaration
public static List From(IEnumerable<Value> vals)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable<Value> | vals |
Returns
Type | Description |
---|---|
List | a List containing the content of |
See Also
| Improve this Doc View SourceFrom(IEnumerable<KeyValuePair<String, Value>>)
Creates a new Map holding the content of an IEnumerable<T> of KeyValuePair<TKey,TValue> of String to Value.
Declaration
public static Map From(IEnumerable<KeyValuePair<string, Value>> vals)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable<KeyValuePair<String, Value>> | vals | the enumerable of KeyValuePair<TKey,TValue> of name to Value |
Returns
Type | Description |
---|---|
Map | a Map containing the content of |
See Also
| Improve this Doc View SourceFrom(Decimal)
Declaration
public static FloatingPoint From(decimal val)
Parameters
Type | Name | Description |
---|---|---|
Decimal | val | the value to wrap |
Returns
Type | Description |
---|---|
FloatingPoint | a FloatingPoint wrapping |
See Also
| Improve this Doc View SourceFrom(Int64)
Declaration
public static Integer From(long val)
Parameters
Type | Name | Description |
---|---|---|
Int64 | val | the value to wrap |
Returns
Type | Description |
---|---|
Integer | a Integer wrapping |
See Also
| Improve this Doc View SourceFrom(String)
Declaration
public static Text From(string val)
Parameters
Type | Name | Description |
---|---|---|
String | val | the value to wrap |
Returns
Type | Description |
---|---|
Text | a Text wrapping |
See Also
| Improve this Doc View SourceInteger(Int64)
Declaration
public static Integer Integer(long val)
Parameters
Type | Name | Description |
---|---|---|
Int64 | val | the value to wrap |
Returns
Type | Description |
---|---|
Integer | a Integer wrapping |
See Also
| Improve this Doc View SourceList()
Creates an empty List().
Declaration
public static List List()
Returns
Type | Description |
---|---|
List | an empty List() |
See Also
| Improve this Doc View SourceMap()
Creates an empty Map().
Declaration
public static Map Map()
Returns
Type | Description |
---|---|
Map | an empty Map() |
See Also
| Improve this Doc View SourceNull()
Creates a Null Value.
Declaration
public static Value Null()
Returns
Type | Description |
---|---|
Value | null |
Text(String)
Declaration
public static Text Text(string val)
Parameters
Type | Name | Description |
---|---|---|
String | val | the value to wrap |
Returns
Type | Description |
---|---|
Text | a Text wrapping |
See Also
| Improve this Doc View SourceToString()
Converts this Value into a human-readable format.
Declaration
public abstract override string ToString()
Returns
Type | Description |
---|---|
String | a human-readable string containing the value provided |