/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date as * the specified SerialDate. */ public boolean isOnOrAfter(final SerialDate other) { return (this.serial >= other.toSerial()); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date * as the specified SerialDate. */ public boolean isAfter(final SerialDate other) { return (this.serial > other.toSerial()); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date * as the specified SerialDate. */ public boolean isAfter(final SerialDate other) { return (this.serial > other.toSerial()); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date as * the specified SerialDate. */ public boolean isOn(final SerialDate other) { return (this.serial == other.toSerial()); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date as * the specified SerialDate. */ public boolean isOn(final SerialDate other) { return (this.serial == other.toSerial()); }
/** * Returns true if this SerialDate represents an earlier date compared to * the specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents an earlier date * compared to the specified SerialDate. */ public boolean isBefore(final SerialDate other) { return (this.serial < other.toSerial()); }
/** * Returns true if this SerialDate represents an earlier date compared to * the specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents an earlier date * compared to the specified SerialDate. */ public boolean isBefore(final SerialDate other) { return (this.serial < other.toSerial()); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date as * the specified SerialDate. */ public boolean isOnOrAfter(final SerialDate other) { return (this.serial >= other.toSerial()); }
/** * Returns the difference (in days) between this date and the specified * 'other' date. * * @param other the date being compared to. * * @return The difference (in days) between this date and the specified * 'other' date. */ public int compare(final SerialDate other) { return this.serial - other.toSerial(); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date * as the specified SerialDate. */ public boolean isOnOrBefore(final SerialDate other) { return (this.serial <= other.toSerial()); }
/** * Returns true if this SerialDate represents an earlier date compared to * the specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents an earlier date * compared to the specified SerialDate. */ public boolean isBefore(final SerialDate other) { return (this.serial < other.toSerial()); }
/** * Returns a serial index number for the day. * * @return The serial index number. */ public long getSerialIndex() { return this.serialDate.toSerial(); }
/** * Returns the difference (in days) between this date and the specified * 'other' date. * * @param other the date being compared to. * * @return The difference (in days) between this date and the specified * 'other' date. */ public int compare(final SerialDate other) { return this.serial - other.toSerial(); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date * as the specified SerialDate. */ public boolean isOnOrBefore(final SerialDate other) { return (this.serial <= other.toSerial()); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date * as the specified SerialDate. */ public boolean isAfter(final SerialDate other) { return (this.serial > other.toSerial()); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date as * the specified SerialDate. */ public boolean isOnOrAfter(final SerialDate other) { return (this.serial >= other.toSerial()); }
/** * Returns the difference (in days) between this date and the specified * 'other' date. * * @param other the date being compared to. * * @return The difference (in days) between this date and the specified * 'other' date. */ public int compare(final SerialDate other) { return this.serial - other.toSerial(); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date as * the specified SerialDate. */ public boolean isOn(final SerialDate other) { return (this.serial == other.toSerial()); }
/** * Returns true if this SerialDate represents the same date as the * specified SerialDate. * * @param other the date being compared to. * * @return <code>true</code> if this SerialDate represents the same date * as the specified SerialDate. */ public boolean isOnOrBefore(final SerialDate other) { return (this.serial <= other.toSerial()); }
/** * Creates a new date by adding the specified number of days to the base * date. * * @param days the number of days to add (can be negative). * @param base the base date. * * @return a new date. */ public static SerialDate addDays(final int days, final SerialDate base) { final int serialDayNumber = base.toSerial() + days; return SerialDate.createInstance(serialDayNumber); }