Class DateHelper

java.lang.Object
com.pensio.api.DateHelper

public class DateHelper extends Object
  • Constructor Details

    • DateHelper

      public DateHelper()
  • Method Details

    • currentTime

      public Date currentTime()
    • currentUTC

      public Date currentUTC()
    • isToday

      public boolean isToday(Date date)
    • thisYear

      public boolean thisYear(Date date)
    • getYear

      public int getYear()
    • getYear

      public int getYear(Date date)
    • getMonth

      public int getMonth(Date date)
      Parameters:
      date -
      Returns:
      actual month, you know the first is 1
    • getHours

      public int getHours(Date date)
    • getMinutes

      public int getMinutes(Date date)
    • getSeconds

      public int getSeconds(Date date)
    • getSecondsSinceMidnight

      public int getSecondsSinceMidnight(Date date)
    • newDate

      public static Date newDate(int year, int month, int day, int hourOfDay, int minute, int second)
    • sameDay

      public boolean sameDay(Date date1, Date date2)
    • formatDate

      public static String formatDate(String format, Date date)
    • parseDate

      public static Date parseDate(String format, String date) throws ParseException
      Throws:
      ParseException
    • add

      public Date add(Date date, DateHelper.DateValue dateValue)