|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.openbandy.util.TimestampUtil
public class TimestampUtil
This class provides static helper methods to be used with timestamps and
dates respectively and methods for the conversion of such.
(c) Copyright P. Bolliger 2007, ALL RIGHTS RESERVED.
Constructor Summary | |
---|---|
TimestampUtil()
|
Method Summary | |
---|---|
static boolean |
areEqualToTheSecond(long t1,
long t2)
Compare two timestamps (given in milliseconds) to the accuracy of one second. |
static java.lang.String |
getActualFormatedDate()
Returns a string representing the actual date and time according to the format 'yyyyMMdd HH:mm:ss' |
static java.lang.String |
getFormatedDate(long timeMillis)
Returns a string representing the actual date and time according to the format 'yyyyMMdd HH:mm:ss' |
static long |
getTimestampFromNMEAFormatedString(java.lang.String nmea)
Returns a timestamp in milliseconds since midnight, January 1, 1970 UTC corresponding to the string parameter which is formated according to NMEA-0183. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TimestampUtil()
Method Detail |
---|
public static boolean areEqualToTheSecond(long t1, long t2)
t1
- The Time in milliseconds since midnight, January 1, 1970 UTCt2
- The Time to compare with
public static java.lang.String getActualFormatedDate()
public static java.lang.String getFormatedDate(long timeMillis)
timeMillis
- The time in milliseconds since midnight, January 1, 1970 UTC
public static long getTimestampFromNMEAFormatedString(java.lang.String nmea)
nmea
- Date formated according to NMEA-0183 (e.g.
'10:22:33/22.11.06')
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |