Class DoubleConverter
This utility class is designed to make System.Double related conversions easier to work with.
Inheritance
System.Object
DoubleConverter
Namespace: Cuemon
Assembly: Cuemon.Core.dll
Syntax
public static class DoubleConverter
Methods
| Improve this DocFromEpochTime(DateTime)
Converts the specified value
to an equivalent Epoc time representation.
Declaration
public static double FromEpochTime(DateTime value)
Parameters
Type | Name | Description |
---|---|---|
System.DateTime | value | The System.DateTime value to be converted. |
Returns
Type | Description |
---|---|
System.Double | A System.Double value that is equivalent to |
Remarks
This implementation converts the value
to an UTC representation ONLY if the System.DateTime.Kind equals System.DateTimeKind.Local.
FromEpochTime(DateTime, Func<DateTime, DateTime>)
Converts the specified value
to an equivalent Epoc time representation.
Declaration
public static double FromEpochTime(DateTime value, Func<DateTime, DateTime> utcConverter)
Parameters
Type | Name | Description |
---|---|---|
System.DateTime | value | The System.DateTime value to be converted. |
System.Func<System.DateTime, System.DateTime> | utcConverter | The function delegate that will convert the given |
Returns
Type | Description |
---|---|
System.Double | A System.Double value that is equivalent to |