public class NTPDate
extends java.util.Date
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
cvsRev |
static long |
offset
The offset.
|
Constructor and Description |
---|
NTPDate()
Creates a date with the current time, offset with the value from the NTP server.
|
Modifier and Type | Method and Description |
---|---|
static long |
currentTimeMillis()
Returns the current time in milliseconds.
|
long |
getOffset()
Returns the current offset.
|
java.lang.String |
toString()
Returns the Date as a formatted string.
|
static java.lang.String |
toString(java.util.Date d)
Returns the Date as a formatted string.
|
static java.lang.String |
toStringOrig(java.util.Date d)
Returns the Date as a formatted string.
|
after, before, clone, compareTo, equals, from, getDate, getDay, getHours, getMinutes, getMonth, getSeconds, getTime, getTimezoneOffset, getYear, hashCode, parse, setDate, setHours, setMinutes, setMonth, setSeconds, setTime, setYear, toGMTString, toInstant, toLocaleString, UTC
public static final java.lang.String cvsRev
public static long offset
public NTPDate()
public static long currentTimeMillis()
System.currentTimeMillis()+offset
public long getOffset()
public java.lang.String toString()
toString
in class java.util.Date
d
- the date to formatpublic static java.lang.String toString(java.util.Date d)
d
- the date to formatpublic static java.lang.String toStringOrig(java.util.Date d)
d
- the date to formatCopyright © 1999-2025 ErgoTech Systems, Inc. All Rights Reserved.