Package oracle.rules.sdk2.extensions
Class OracleDuration
java.lang.Object
oracle.rules.rl.extensions.Duration
oracle.rules.sdk2.extensions.OracleDuration
-
Method Summary
Modifier and TypeMethodDescriptionstatic DurationCompute XML dayTimeDuration between 2 dates.static Durationbetween(XMLGregorianCalendar date1, oracle.jbo.domain.Timestamp date2) Compute XML dayTimeDuration between 2 dates.static DurationCompute XML dayTimeDuration between 2 dates.static Durationbetween(oracle.jbo.domain.Timestamp date1, XMLGregorianCalendar date2) Compute XML dayTimeDuration between 2 dates.static Durationbetween(oracle.jbo.domain.Timestamp date1, oracle.jbo.domain.Timestamp date2) Compute XML dayTimeDuration between 2 dates.static intCompares two dates and returns an int value of 0 if they are equal, less than 0 ifcal1represents a point in time beforets2, greater than 0 ifcal1represents a point in time afterts2.static intcompare(XMLGregorianCalendar cal1, oracle.jbo.domain.Timestamp ts2) Compares two dates and returns an int value of 0 if they are equal, less than 0 ifcal1represents a point in time beforets2, greater than 0 ifcal1represents a point in time afterts2.static intCompares two dates and returns an int value of 0 if they are equal, less than 0 ifts1represents a point in time beforecal2, greater than 0 ifts1represents a point in time aftercal2.static intcompare(oracle.jbo.domain.Timestamp ts1, XMLGregorianCalendar cal2) Compares two dates and returns an int value of 0 if they are equal, less than 0 ifts1represents a point in time beforecal2, greater than 0 ifts1represents a point in time aftercal2.static intcompare(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Compares two dates and returns an int value of 0 if they are equal, less than 0 ifts1represents a point in time beforets2, greater than 0 ifts1represents a point in time afterts2.static intdaysBetween(Calendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in days.static intdaysBetween(XMLGregorianCalendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in days.static intdaysBetween(oracle.jbo.domain.Timestamp ts1, Calendar cal2) Returns the difference between the two dates in days.static intdaysBetween(oracle.jbo.domain.Timestamp ts1, XMLGregorianCalendar cal2) Returns the difference between the two dates in days.static intdaysBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in days.static longhoursBetween(Calendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in hours.static longhoursBetween(XMLGregorianCalendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in hours.static longhoursBetween(oracle.jbo.domain.Timestamp ts1, Calendar cal2) Returns the difference between the two dates in hours.static longhoursBetween(oracle.jbo.domain.Timestamp ts1, XMLGregorianCalendar cal2) Returns the difference between the two dates in hours.static longhoursBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in hours.static longmillisecondsBetween(Calendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in milliseconds.static longmillisecondsBetween(XMLGregorianCalendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in milliseconds.static longmillisecondsBetween(oracle.jbo.domain.Timestamp ts1, Calendar cal2) Returns the difference between the two dates in milliseconds.static longmillisecondsBetween(oracle.jbo.domain.Timestamp ts1, XMLGregorianCalendar cal2) Returns the difference between the two dates in milliseconds.static longmillisecondsBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in milliseconds.static longminutesBetween(Calendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in minutes.static longminutesBetween(XMLGregorianCalendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in minutes.static longminutesBetween(oracle.jbo.domain.Timestamp ts1, Calendar cal2) Returns the difference between the two dates in minutes.static longminutesBetween(oracle.jbo.domain.Timestamp ts1, XMLGregorianCalendar cal2) Returns the difference between the two dates in minutes.static longminutesBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in minutes.static intmonthsBetween(Calendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in months.static intmonthsBetween(XMLGregorianCalendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in months.static intmonthsBetween(oracle.jbo.domain.Timestamp ts1, Calendar cal2) Returns the difference between the two dates in months.static intmonthsBetween(oracle.jbo.domain.Timestamp ts1, XMLGregorianCalendar cal2) Returns the difference between the two dates in months.static intmonthsBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in months.static longsecondsBetween(Calendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in seconds.static longsecondsBetween(XMLGregorianCalendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in seconds.static longsecondsBetween(oracle.jbo.domain.Timestamp ts1, Calendar cal2) Returns the difference between the two dates in seconds.static longsecondsBetween(oracle.jbo.domain.Timestamp ts1, XMLGregorianCalendar cal2) Returns the difference between the two dates in seconds.static longsecondsBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in seconds.static intweeksBetween(Calendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in weeks.static intweeksBetween(XMLGregorianCalendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in weeks.static intweeksBetween(oracle.jbo.domain.Timestamp ts1, Calendar cal2) Returns the difference between the two dates in weeks.static intweeksBetween(oracle.jbo.domain.Timestamp ts1, XMLGregorianCalendar cal2) Returns the difference between the two dates in weeks.static intweeksBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in weeks.static intyearsBetween(Calendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in years.static intyearsBetween(XMLGregorianCalendar cal1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in years.static intyearsBetween(oracle.jbo.domain.Timestamp ts1, Calendar cal2) Returns the difference between the two dates in years.static intyearsBetween(oracle.jbo.domain.Timestamp ts1, XMLGregorianCalendar cal2) Returns the difference between the two dates in years.static intyearsBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in years.Methods inherited from class oracle.rules.rl.extensions.Duration
between, between, between, between, compare, compare, compare, compare, compareDurations, daysBetween, daysBetween, daysBetween, daysBetween, divide, divide, fromString, getSeconds, hoursBetween, hoursBetween, hoursBetween, hoursBetween, isDayTimeDuration, isYearMonthDuration, millisecondsBetween, millisecondsBetween, millisecondsBetween, millisecondsBetween, minutesBetween, minutesBetween, minutesBetween, minutesBetween, monthsBetween, monthsBetween, monthsBetween, monthsBetween, multiply, multiply, ratio, secondsBetween, secondsBetween, secondsBetween, secondsBetween, weeksBetween, weeksBetween, weeksBetween, weeksBetween, yearsBetween, yearsBetween, yearsBetween, yearsBetween
-
Method Details
-
yearsBetween
public static int yearsBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in years. The difference may be negative if the first date is later than the second date. Any resulting fractional year is truncated.ts1andts2are converted to instances ofGregorianCalendarbefore the difference is calculated.- Parameters:
ts1- the starting Timestamp instancets2- the ending Timestamp instance- Returns:
- the number of years between the
ts1andts2. - Throws:
NullPointerException- if eitherts1orts2is null.
-
yearsBetween
Returns the difference between the two dates in years. The difference may be negative if the first date is later than the second date. Any resulting fractional year is truncated.ts1is converted to an instance ofGregorianCalendarbefore the difference is calculated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of years between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
yearsBetween
Returns the difference between the two dates in years. The difference may be negative if the first date is later than the second date. Any resulting fractional year is truncated.date2is converted to an instance ofGregorianCalendarbefore the difference is calculated.- Parameters:
cal1- the starting Calendar instancets2- the ending Timestamp instance- Returns:
- the number of years between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
yearsBetween
Returns the difference between the two dates in years. The difference may be negative if the first date is later than the second date. Any resulting fractional year is truncated.date1anddate2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending XMLGregorianCalendar instance- Returns:
- the number of years between the date1 and date2.
- Throws:
NullPointerException- if eitherts1orcal2is null.
-
yearsBetween
Returns the difference between the two dates in years. The difference may be negative if the first date is later than the second date. Any resulting fractional year is truncated.date1anddate2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
cal1- the starting XMLGregorianCalendar instancets2- the ending Timestamp instance- Returns:
- the number of years between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
monthsBetween
public static int monthsBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in months. The difference may be negative if the first date is later than the second date. Any resulting fractional month is truncated.- Parameters:
ts1- the starting Timestamp instancets2- the ending Timestamp instance- Returns:
- the number of months between the
ts1andts2. - Throws:
NullPointerException- if eitherts1orts2is null.
-
monthsBetween
Returns the difference between the two dates in months. The difference may be negative if the first date is later than the second date. Any resulting fractional month is truncated.- Parameters:
cal1- the starting Calendar instancets2- the ending Timestamp instance- Returns:
- the number of months between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
monthsBetween
Returns the difference between the two dates in months. The difference may be negative if the first date is later than the second date. Any resulting fractional month is truncated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of months between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
monthsBetween
Returns the difference between the two dates in months. The difference may be negative if the first date is later than the second date. Any resulting fractional month is truncated.- Parameters:
cal1- the starting XMLGregorianCalendar instancets2- the ending Timestamp instance- Returns:
- the number of months between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
monthsBetween
Returns the difference between the two dates in months. The difference may be negative if the first date is later than the second date. Any resulting fractional month is truncated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending XMLGregorianCalendar instance- Returns:
- the number of months between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
weeksBetween
public static int weeksBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in weeks. The difference may be negative if the first date is later than the second date. Any resulting fractional week is truncated.ts1andts2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
ts1- the starting Timestamp instancets2- the ending Timestamp instance- Returns:
- the number of weeks between the
ts1andts2. - Throws:
NullPointerException- if eitherts1orts2is null.
-
weeksBetween
Returns the difference between the two dates in weeks. The difference may be negative if the first date is later than the second date. Any resulting fractional week is truncated.ts1andcal2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of weeks between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
weeksBetween
Returns the difference between the two dates in weeks. The difference may be negative if the first date is later than the second date. Any resulting fractional week is truncated.cal1andts2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
cal1- the starting Calendar instancets2- the ending Timestamp instance- Returns:
- the number of weeks between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
weeksBetween
Returns the difference between the two dates in weeks. The difference may be negative if the first date is later than the second date. Any resulting fractional week is truncated.ts1andcal2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending XMLGregorianCalendar instance- Returns:
- the number of weeks between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
weeksBetween
Returns the difference between the two dates in weeks. The difference may be negative if the first date is later than the second date. Any resulting fractional week is truncated.cal1andts2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
cal1- the starting XMLGregorianCalendar instancets2- the ending Timestamp instance- Returns:
- the number of weeks between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
daysBetween
public static int daysBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in days. The difference may be negative if the first date is later than the second date. Any resulting fractional day is truncated.ts1andts2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
ts1- the starting Timestamp instancets2- the ending Timestamp instance- Returns:
- the number of weeks between the
ts1andts2. - Throws:
NullPointerException- if eitherts1orts2is null.
-
daysBetween
Returns the difference between the two dates in days. The difference may be negative if the first date is later than the second date. Any resulting fractional day is truncated.cal1andts2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
cal1- the starting Calendar instancets2- the ending Timestamp instance- Returns:
- the number of weeks between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
daysBetween
Returns the difference between the two dates in days. The difference may be negative if the first date is later than the second date. Any resulting fractional day is truncated.ts1andcal2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of weeks between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
daysBetween
Returns the difference between the two dates in days. The difference may be negative if the first date is later than the second date. Any resulting fractional day is truncated.cal1andts2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
cal1- the starting XMLGregorianCalendar instancets2- the ending Timestamp instance- Returns:
- the number of weeks between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
daysBetween
Returns the difference between the two dates in days. The difference may be negative if the first date is later than the second date. Any resulting fractional day is truncated.ts1andcal2are converted toGregorianCalendarbefore the difference is calculated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of weeks between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
hoursBetween
public static long hoursBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in hours. The difference may be negative if the first date is later than the second date. Any resulting fractional hour is truncated.- Parameters:
ts1- the starting Timestamp instancets2- the ending Timestamp instance- Returns:
- the number of hours between the
ts1andts2. - Throws:
NullPointerException- if eitherts1orts2is null.
-
hoursBetween
Returns the difference between the two dates in hours. The difference may be negative if the first date is later than the second date. Any resulting fractional hour is truncated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of hours between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
hoursBetween
Returns the difference between the two dates in hours. The difference may be negative if the first date is later than the second date. Any resulting fractional hour is truncated.- Parameters:
cal1- the starting Calendar instancets2- the ending Timestamp instance- Returns:
- the number of hours between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
hoursBetween
Returns the difference between the two dates in hours. The difference may be negative if the first date is later than the second date. Any resulting fractional hour is truncated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of hours between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
hoursBetween
Returns the difference between the two dates in hours. The difference may be negative if the first date is later than the second date. Any resulting fractional hour is truncated.- Parameters:
cal1- the starting XMLGregorianCalendar instancets2- the ending Timestamp instance- Returns:
- the number of hours between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
minutesBetween
public static long minutesBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in minutes. The difference may be negative if the first date is later than the second date. Any resulting fractional minute is truncated.- Parameters:
ts1- the starting Timestamp instancets2- the ending Timestamp instance- Returns:
- the number of minutes between the
ts1andts2. - Throws:
NullPointerException- if eitherts1orts2is null.
-
minutesBetween
Returns the difference between the two dates in minutes. The difference may be negative if the first date is later than the second date. Any resulting fractional minute is truncated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of minutes between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
minutesBetween
Returns the difference between the two dates in minutes. The difference may be negative if the first date is later than the second date. Any resulting fractional minute is truncated.- Parameters:
cal1- the starting Calendar instancets2- the ending Timestamp instance- Returns:
- the number of minutes between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
minutesBetween
Returns the difference between the two dates in minutes. The difference may be negative if the first date is later than the second date. Any resulting fractional minute is truncated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of minutes between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
minutesBetween
Returns the difference between the two dates in minutes. The difference may be negative if the first date is later than the second date. Any resulting fractional minute is truncated.- Parameters:
cal1- the starting XMLGregorianCalendar instancets2- the ending Timestamp instance- Returns:
- the number of minutes between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
secondsBetween
public static long secondsBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in seconds. The difference may be negative if the first date is later than the second date. Any resulting fractional second is truncated.- Parameters:
ts1- the starting Timestamp instancets2- the ending Timestamp instance- Returns:
- the number of seconds between the
ts1andts2. - Throws:
NullPointerException- if eitherts1orts2is null.
-
secondsBetween
Returns the difference between the two dates in seconds. The difference may be negative if the first date is later than the second date. Any resulting fractional second is truncated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of seconds between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
secondsBetween
Returns the difference between the two dates in seconds. The difference may be negative if the first date is later than the second date. Any resulting fractional second is truncated.- Parameters:
cal1- the starting Calendar instancets2- the ending Timestamp instance- Returns:
- the number of seconds between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
secondsBetween
Returns the difference between the two dates in seconds. The difference may be negative if the first date is later than the second date. Any resulting fractional second is truncated.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of seconds between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
secondsBetween
Returns the difference between the two dates in seconds. The difference may be negative if the first date is later than the second date. Any resulting fractional second is truncated.- Parameters:
cal1- the starting XMLGregorianCalendar instancets2- the ending Timestamp instance- Returns:
- the number of seconds between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
millisecondsBetween
public static long millisecondsBetween(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Returns the difference between the two dates in milliseconds. The difference may be negative if the first date is later than the second date.- Parameters:
ts1- the starting Timestamp instancets2- the ending Timestamp instance- Returns:
- the number of milliseconds between the
ts1andts2. - Throws:
NullPointerException- if eitherts1orts2is null.
-
millisecondsBetween
Returns the difference between the two dates in milliseconds. The difference may be negative if the first date is later than the second date.- Parameters:
cal1- the starting Calendar instancets2- the ending Timestamp instance- Returns:
- the number of milliseconds between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
millisecondsBetween
Returns the difference between the two dates in milliseconds. The difference may be negative if the first date is later than the second date.- Parameters:
ts1- the starting Timestamp instancecal2- the ending Calendar instance- Returns:
- the number of milliseconds between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
millisecondsBetween
Returns the difference between the two dates in milliseconds. The difference may be negative if the first date is later than the second date.- Parameters:
cal1- the starting XMLGregorianCalendar instancets2- the ending Timestamp instance- Returns:
- the number of milliseconds between the
cal1thets2. - Throws:
NullPointerException- if either cal1 orts2is null.
-
millisecondsBetween
Returns the difference between the two dates in milliseconds. The difference may be negative if the first date is later than the second date.- Parameters:
ts1- the starting Timestamp instancecal2- the ending XMLGregorianCalendar instance- Returns:
- the number of milliseconds between the
ts1andcal2. - Throws:
NullPointerException- if eitherts1orcal2is null.
-
compare
public static int compare(oracle.jbo.domain.Timestamp ts1, oracle.jbo.domain.Timestamp ts2) Compares two dates and returns an int value- of 0 if they are equal,
- less than 0 if
ts1represents a point in time beforets2, - greater than 0 if
ts1represents a point in time afterts2.
- Parameters:
ts1- the left-hand side Timestamp instancets2- the right-hand side Timestamp instance- Returns:
- the relative comparison result.
-
compare
Compares two dates and returns an int value- of 0 if they are equal,
- less than 0 if
ts1represents a point in time beforecal2, - greater than 0 if
ts1represents a point in time aftercal2.
- Parameters:
ts1- the left-hand side Timestamp instancecal2- the right-hand side Calendar instance- Returns:
- the relative comparison result.
-
compare
Compares two dates and returns an int value- of 0 if they are equal,
- less than 0 if
cal1represents a point in time beforets2, - greater than 0 if
cal1represents a point in time afterts2.
- Parameters:
cal1- the left-hand side Calendar instancets2- the right-hand side Timestamp instance- Returns:
- the relative comparison result.
-
compare
Compares two dates and returns an int value- of 0 if they are equal,
- less than 0 if
ts1represents a point in time beforecal2, - greater than 0 if
ts1represents a point in time aftercal2.
- Parameters:
ts1- the left-hand side Timestamp instancecal2- the right-hand side XMLGregorianCalendar instance- Returns:
- the relative comparison result.
-
compare
Compares two dates and returns an int value- of 0 if they are equal,
- less than 0 if
cal1represents a point in time beforets2, - greater than 0 if
cal1represents a point in time afterts2.
- Parameters:
cal1- the left-hand side XMLGregorianCalendar instancets2- the right-hand side Timestamp instance- Returns:
- the relative comparison result.
-
between
public static Duration between(oracle.jbo.domain.Timestamp date1, oracle.jbo.domain.Timestamp date2) Compute XML dayTimeDuration between 2 dates. Result will be negative if date1 > date2.- Parameters:
date1- first (earlier) datedate2- second (later) date- Returns:
- XML Duration
-
between
Compute XML dayTimeDuration between 2 dates. Result will be negative if date1 > date2.- Parameters:
date1- first (earlier) datedate2- second (later) date- Returns:
- XML Duration
-
between
Compute XML dayTimeDuration between 2 dates. Result will be negative if date1 > date2.- Parameters:
date1- first (earlier) datedate2- second (later) date- Returns:
- XML Duration
-
between
Compute XML dayTimeDuration between 2 dates. Result will be negative if date1 > date2.- Parameters:
date1- first (earlier) datedate2- second (later) date- Returns:
- XML Duration
-
between
Compute XML dayTimeDuration between 2 dates. Result will be negative if date1 > date2.- Parameters:
date1- first (earlier) datedate2- second (later) date- Returns:
- XML Duration
-