org.gcube.portlets.user.speciesdiscovery.server.util
Class DateUtil
java.lang.Object
org.gcube.portlets.user.speciesdiscovery.server.util.DateUtil
public class DateUtil
- extends Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
logger
public static org.apache.log4j.Logger logger
DATE_TIME_FORMAT
public static final String DATE_TIME_FORMAT
- See Also:
- Constant Field Values
DATE_TIME_FORMAT_2
public static final String DATE_TIME_FORMAT_2
- See Also:
- Constant Field Values
DateUtil
public DateUtil()
toDate
public static Date toDate(Calendar calendar)
toDateFormatToString
public static String toDateFormatToString(Calendar calendar)
toDateFormat
public static Date toDateFormat(Calendar calendar)
getDateFormat
public static Date getDateFormat(Calendar calendar)
getDate
public static Date getDate(Calendar calendar)
stringToDateFormat
public static Date stringToDateFormat(String date)
dateToDateFormatString
public static String dateToDateFormatString(Date date)
millisecondsToDate
public static Date millisecondsToDate(long milliseconds)
getDifference
public static long getDifference(long date1,
long date2,
DateUtil.TIMETYPE timeType)
getDifference
public static String getDifference(long date1,
long date2)
- Parameters:
date1
- date2
-
- Returns:
- difference between two date in this format: N°day/days HH:mm:ss
Copyright © 2013. All Rights Reserved.