Click or drag to resize

NtpTimeTag Class

Represents a standard Network Time Protocol (NTP) timetag.
Inheritance Hierarchy
SystemObject
  GSFTimeTagBase
    GSFNtpTimeTag

Namespace: GSF
Assembly: GSF.Core (in GSF.Core.dll) Version: 2.4.181-beta
Syntax
[SerializableAttribute]
public class NtpTimeTag : TimeTagBase
View Source

The NtpTimeTag type exposes the following members.

Constructors
 NameDescription
Public methodNtpTimeTag(Decimal) Creates a new NtpTimeTag, given number of seconds since 1/1/1900.
Public methodNtpTimeTag(Ticks) Creates a new NtpTimeTag, given specified Ticks.
Public methodNtpTimeTag(UInt64) Creates a new NtpTimeTag, given 64-bit NTP timestamp.
Protected methodNtpTimeTag(SerializationInfo, StreamingContext) Creates a new NtpTimeTag from serialization parameters.
Public methodNtpTimeTag(UInt32, UInt32) Creates a new NtpTimeTag, given number of seconds and fractional seconds since 1/1/1900.
Top
Properties
 NameDescription
Public propertyBaseDateOffsetTicks Gets ticks representing the absolute minimum time of this timetag implementation.
(Inherited from TimeTagBase)
Public propertyTimestamp Gets 64-bit NTP timestamp.
Public propertyValue Gets or sets number of seconds (including any fractional seconds) since base time.
(Inherited from TimeTagBase)
Top
Methods
 NameDescription
Public methodCompareTo(DateTime) Compares the TimeTagBase with a DateTime.
(Inherited from TimeTagBase)
Public methodCompareTo(Object) Compares the TimeTagBase with the specified Object.
(Inherited from TimeTagBase)
Public methodCompareTo(TimeTagBase) Compares the TimeTagBase with another TimeTagBase.
(Inherited from TimeTagBase)
Public methodEquals(DateTime) Determines whether the specified DateTime is equal to the current TimeTagBase.
(Inherited from TimeTagBase)
Public methodEquals(Object) Determines whether the specified Object is equal to the current TimeTagBase.
(Inherited from TimeTagBase)
Public methodEquals(TimeTagBase) Determines whether the specified TimeTagBase is equal to the current TimeTagBase.
(Inherited from TimeTagBase)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodStatic memberFromTicks Gets 64-bit NTP timestamp given timestamp in Ticks.
Public methodStatic memberGetBaseDateOffsetTicks(Decimal) Gets proper NTP offset based on seconds value, see RFC-2030.
Public methodStatic memberGetBaseDateOffsetTicks(Ticks) Gets proper NTP offset based on timestamp value, see RFC-2030.
Public methodStatic memberGetBaseDateOffsetTicks(UInt32) Gets proper NTP offset based on most significant byte on seconds value, see RFC-2030.
Public methodGetHashCode Serves as a hash function for the current TimeTagBase.
(Inherited from TimeTagBase)
Public methodGetObjectData Populates a SerializationInfo with the data needed to serialize the target object.
(Inherited from TimeTagBase)
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Public methodToDateTime Returns standard .NET DateTime representation for timetag.
(Inherited from TimeTagBase)
Public methodToString Returns basic textual representation for timetag.
(Inherited from TimeTagBase)
Public methodToString(IFormatProvider) Returns textual representation for timetag using the specified provider.
(Inherited from TimeTagBase)
Public methodToString(String) Returns textual representation for timetag in the specified format.
(Inherited from TimeTagBase)
Public methodToString(String, IFormatProvider) Returns textual representation for timetag in the specified format using the specified provider.
(Inherited from TimeTagBase)
Top
Fields
 NameDescription
Public fieldStatic memberAlternateBaseTicks Number of ticks since since 2/7/2036 at 6h 28m 16s UTC when MSB is set.
Public fieldStatic memberBaseTicks Number of ticks since 1/1/1900.
Top
Extension Methods
 NameDescription
Public Extension MethodGetEnumValueOrDefault Gets the enumeration constant for value, if defined in the enumeration, or a default value.
(Defined by EnumExtensions)
Public Extension MethodGetEnumValueOrDefaultT Gets the enumeration constant for this value, if defined in the enumeration, or a default value.
(Defined by EnumExtensions)
Top
Remarks
As recommended by RFC-2030, all NTP timestamps earlier than 3h 14m 08s UTC on 20 January 1968 are reckoned from 6h 28m 16s UTC on 7 February 2036. This gives the NtpTimeTag class a functioning range of 1968-01-20 03:14:08 to 2104-02-26 09:42:23.
See Also

Reference

GSF Namespace