Class DateUtilities
java.lang.Object
com.inductiveautomation.ignition.common.script.builtin.DateUtilities
Date and time functions for use in scripting, to make dealing with java.util.Date objects less painful
from python.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Datestatic Datestatic Datestatic DateaddMinutes(Date d, int value) static Datestatic DateaddSeconds(Date d, int value) static Datestatic Datestatic intdaysBetween(Date a, Date b) static Stringstatic Stringstatic DatefromMillis(long millis) static intstatic DategetDate(int year, int month, int day) static intstatic intgetDayOfWeek(Date d) static intgetDayOfYear(Date d) static intstatic intstatic intstatic intstatic intstatic intgetQuarter(Date d) static intstatic Stringstatic doublestatic doublegetTimezoneOffset(Date date) static doublestatic intstatic inthoursBetween(Date a, Date b) static booleanstatic booleanstatic booleanstatic booleanstatic booleanisDaylightTime(Date date) static Datestatic longmillisBetween(Date a, Date b) static intminutesBetween(Date a, Date b) static intmonthsBetween(Date a, Date b) static Datenow()static Datestatic intsecondsBetween(Date a, Date b) static Datestatic longstatic intweeksBetween(Date a, Date b) static intyearsBetween(Date a, Date b)
-
Constructor Details
-
DateUtilities
public DateUtilities()
-
-
Method Details
-
now
-
fromMillis
-
toMillis
-
getTimezoneOffset
public static double getTimezoneOffset() -
getTimezoneOffset
-
getTimezoneRawOffset
public static double getTimezoneRawOffset() -
getTimezone
-
isDaylightTime
public static boolean isDaylightTime() -
isDaylightTime
-
midnight
-
setTime
-
getDate
-
addMillis
-
addSeconds
-
addMinutes
-
addHours
-
addDays
-
addWeeks
-
addMonths
-
addYears
-
millisBetween
-
secondsBetween
-
minutesBetween
-
hoursBetween
-
daysBetween
-
weeksBetween
-
monthsBetween
-
yearsBetween
-
format
-
format
-
isBefore
-
isAfter
-
isBetween
-
getQuarter
-
getYear
-
getMonth
-
getDayOfMonth
-
getDayOfYear
-
getDayOfWeek
-
getHour12
-
getAMorPM
-
getHour24
-
getMinute
-
getSecond
-
getMillis
-
parse
@Nullable public static Date parse(org.python.core.PyObject[] pyArgs, String[] keywords) throws ParseException - Throws:
ParseException
-