Table of Contents

Class JsonDateTimeNanoConverter

Namespace
Ecng.Serialization
Assembly
Ecng.Serialization.dll

Provides a JSON converter for converting DateTime values from Unix timestamps in nanoseconds.

public class JsonDateTimeNanoConverter : JsonDateTimeConverter
Inheritance
JsonDateTimeNanoConverter
Inherited Members
Extension Methods

Constructors

JsonDateTimeNanoConverter()

Initializes a new instance of the JsonDateTimeNanoConverter class using nanoseconds.

public JsonDateTimeNanoConverter()

Methods

Convert(double)

Converts the specified double value to a DateTime using nanosecond precision.

protected override DateTime Convert(double value)

Parameters

value double

The double value representing the Unix timestamp in nanoseconds.

Returns

DateTime

A DateTime corresponding to the Unix timestamp.