Package edu.cnu.mdi.format
Class DateString
java.lang.Object
edu.cnu.mdi.format.DateString
Thread-safe date and time formatting helpers.
-
Method Summary
Modifier and TypeMethodDescriptionstatic StringReturns the current time.static StringReturns the current time.static StringReturns the current time.static StringdateStringMM(long longtime) Returns the current time.static StringReturns the current time.static StringdateStringShort(long ltime) Returns the current time.static StringReturns the current time.static StringdateStringSS(long longtime) Returns the current time.
-
Method Details
-
dateString
Returns the current time.- Returns:
- a string representation of the current time, down to seconds.
-
dateStringMM
Returns the current time.- Returns:
- a string representation of the current time, down to minutes.
-
dateStringMM
Returns the current time.- Parameters:
longtime- the time in millis.- Returns:
- a string representation of the current time, down to minutes.
-
dateStringLong
Returns the current time.- Returns:
- a string representation of the current time, down to seconds.
-
dateStringSS
Returns the current time.- Parameters:
longtime- The time in millis.- Returns:
- a string representation of the current time, down to seconds.
-
dateStringSS
Returns the current time.- Returns:
- a string representation of the current time, down to seconds.
-
dateStringShort
Returns the current time.- Parameters:
ltime- a time in milliseconds.- Returns:
- a string representation of the current time, down to seconds but without day information.
-
dateStringShort
Returns the current time.- Returns:
- a string representation of the current time, down to seconds but without day information.
-