java.lang.Object
com.yuzhyn.azylee.core.datas.datetimes.DateTool

public class DateTool extends Object
  • 构造器详细资料

    • DateTool

      public DateTool()
  • 方法详细资料

    • parse

      public static Date parse(LocalDateTime dateTime)
    • parse

      public static Date parse(String s)
    • parse

      public static Date parse(String s, String format)
    • parse

      public static Date parse(String s, DateTimeFormatPattern pattern)
    • parse

      public static Date parse(int year, int month, int day)
    • parse

      public static Date parse(int year, int month, int day, int hour, int minute, int second)
    • addSecond

      public static Date addSecond(Date date, int second)
      时间增加 second 秒
      参数:
      date - 参数
      second - 参数
      返回:
      返回 返回
    • addSecond

      public static Date addSecond(Date date, long second)
      时间增加 second 秒(long类型)
      参数:
      date - 参数
      second - 参数
      返回:
      返回 返回
    • addMinute

      public static Date addMinute(Date date, int minute)
      时间增加 minute 分钟
      参数:
      date - 参数
      minute - 参数
      返回:
      返回 返回
    • addHour

      public static Date addHour(Date date, int hour)
      时间增加 hour 小时
      参数:
      date - 参数
      hour - 参数
      返回:
      返回 返回
    • addDay

      public static Date addDay(Date date, int day)
      时间增加 day 天
      参数:
      date - 参数
      day - 参数
      返回:
      返回 返回
    • addMonth

      public static Date addMonth(Date date, int month)
      时间增加 month 月
      参数:
      date - 参数
      month - 参数
      返回:
      返回 返回
    • addYear

      public static Date addYear(Date date, int year)
      时间增加 year 年
      参数:
      date - 参数
      year - 参数
      返回:
      返回 返回
    • main

      public static void main(String[] args)