类 DateUtil
java.lang.Object
org.tio.utils.hutool.DateUtil
- 作者:
- tanyaowu
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static intdaysBetween(Date date1, Date date2) 两个日期相隔的天数static StringformatDateTime(Date date) 格式化日期时间
格式 yyyy-MM-dd HH:mm:ssstatic StringguessPattern(String dateStr) static StringhttpDate()当前时间生成符合http响应头中的Date格式的字符串static StringhttpDate(long millis) static String把date生成符合http响应头中的Date格式的字符串static DateparseToDate(String dateStr) static DateparseToSqlDate(String dateStr) static TimeparseToTime(String dateStr) static TimestampparseToTimestamp(String dateStr)
-
构造器详细资料
-
DateUtil
public DateUtil()
-
-
方法详细资料
-
guessPattern
-
parseToDate
-
parseToSqlDate
-
parseToTimestamp
-
parseToTime
-
httpDate
当前时间生成符合http响应头中的Date格式的字符串- 返回:
-
httpDate
把date生成符合http响应头中的Date格式的字符串- 参数:
date-- 返回:
-
httpDate
-
formatDateTime
格式化日期时间
格式 yyyy-MM-dd HH:mm:ss- 参数:
date- 被格式化的日期- 返回:
- 格式化后的日期
-
daysBetween
两个日期相隔的天数- 参数:
date1-date2-- 返回:
-