Class TimeSpanConverter
Yaml converter for TimeSpan type.
Namespace: NFive.SDK.Plugins.Configuration
Assembly: NFive.SDK.Plugins.dll
Syntax
public class TimeSpanConverter : IYamlTypeConverter
Methods
| Improve this Doc View SourceAccepts(Type)
Gets a value indicating whether the current converter supports converting the specified type.
Declaration
public bool Accepts(Type type)
Parameters
Type | Name | Description |
---|---|---|
Type | type | The type to check. |
Returns
Type | Description |
---|---|
Boolean |
|
ReadYaml(IParser, Type)
Reads an object's state from a Yaml parser.
Declaration
public object ReadYaml(IParser parser, Type type)
Parameters
Type | Name | Description |
---|---|---|
IParser | parser | |
Type | type |
Returns
Type | Description |
---|---|
Object | Deserialized TimeSpan object. |
WriteYaml(IEmitter, Object, Type)
Writes the specified object's state to a Yaml emitter.
Declaration
public void WriteYaml(IEmitter emitter, object value, Type type)
Parameters
Type | Name | Description |
---|---|---|
IEmitter | emitter | |
Object | value | |
Type | type |