org.apache.commons.net.ntp
public class TimeInfo extends Object
Version: $Revision: 165675 $ $Date: 2005-05-02 15:09:55 -0500 (Mon, 02 May 2005) $
Constructor Summary | |
---|---|
TimeInfo(NtpV3Packet message, long returnTime)
Create TimeInfo object with raw packet message and destination time received.
| |
TimeInfo(NtpV3Packet message, long returnTime, List comments)
Create TimeInfo object with raw packet message and destination time received.
| |
TimeInfo(NtpV3Packet msgPacket, long returnTime, boolean doComputeDetails)
Create TimeInfo object with raw packet message and destination time received.
| |
TimeInfo(NtpV3Packet message, long returnTime, List comments, boolean doComputeDetails)
Create TimeInfo object with raw packet message and destination time received.
|
Method Summary | |
---|---|
void | addComment(String comment)
Add comment (error/warning) to list of comments associated
with processing of NTP parameters. |
void | computeDetails()
Compute and validate details of the NTP message packet. |
List | getComments()
Return list of comments (if any) during processing of NTP packet.
|
Long | getDelay()
Get round-trip network delay. |
NtpV3Packet | getMessage()
Returns NTP message packet.
|
Long | getOffset()
Get clock offset needed to adjust local clock to match remote clock. |
long | getReturnTime()
Returns time at which time message packet was received by local machine.
|
Parameters: message NTP message packet returnTime destination receive time
Throws: IllegalArgumentException if message is null
Parameters: message NTP message packet returnTime destination receive time comments List of errors/warnings identified during processing
Throws: IllegalArgumentException if message is null
Parameters: msgPacket NTP message packet returnTime destination receive time doComputeDetails flag to pre-compute delay/offset values
Throws: IllegalArgumentException if message is null
Parameters: message NTP message packet returnTime destination receive time comments list of comments used to store errors/warnings with message doComputeDetails flag to pre-compute delay/offset values
Throws: IllegalArgumentException if message is null
Parameters: comment
Returns: List or null if not yet computed
Returns: Long or null if delay not available.
Returns: NTP message packet.
Returns: Long or null if offset not available.
Returns: packet return time.