NDEVR
API Documentation
NtpTimestamp

A 64-bit NTP timestamp with seconds and fractional parts since Jan 1, 1900. More...

Public Member Functions

 NtpTimestamp ()
 Default constructor.
 NtpTimestamp (const Time &dateTime)
Time toTime () const

Public Attributes

quint32 fraction
 Fractional time part, in 1/0xFFFFFFFFs of a second.
quint32 seconds
 Number of seconds passed since Jan 1 1900, in big-endian format.

Detailed Description

A 64-bit NTP timestamp with seconds and fractional parts since Jan 1, 1900.

Definition at line 13 of file NtpTimestamp.h.

Constructor & Destructor Documentation

◆ NtpTimestamp()

NtpTimestamp::NtpTimestamp ( const Time & dateTime)
inline
Parameters
dateTimeThe Time to convert to NTP structure.

Definition at line 27 of file NtpTimestamp.h.

References fraction, Time::getMilliseconds(), and seconds.

Member Function Documentation

◆ toTime()

Time NtpTimestamp::toTime ( ) const
inline
Returns
Time object for the given NTP timestamp.

Definition at line 44 of file NtpTimestamp.h.

References fraction, and seconds.


The documentation for this struct was generated from the following file: