Module ical4j.core

Class DateRange

java.lang.Object
net.fortuna.ical4j.model.DateRange
All Implemented Interfaces:
Serializable

@Deprecated public class DateRange extends Object implements Serializable
Deprecated.
We can no longer use DateRange to compare dates reliably due to supporting incompatible temporal types. Use Interval instead.
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
    Deprecated.
    A flag indicating whether to include the end of the period in test functions.
    static final int
    Deprecated.
    A flag indicating whether to include the start of the period in test functions.
  • Constructor Summary

    Constructors
    Constructor
    Description
    DateRange(Date start, Date end)
    Deprecated.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    final boolean
    Deprecated.
    Decides whether these periods are serial without a gap.
    final boolean
    Deprecated.
    Decides whether this period starts after the given period ends.
    final boolean
    Deprecated.
    Decides whether this period is completed before the given period starts.
    final boolean
    Deprecated.
    Decides whether the given period is completely contained within this one.
    boolean
    Deprecated.
     
    Deprecated.
     
    Deprecated.
     
    int
    Deprecated.
     
    final boolean
    includes(Date date)
    Deprecated.
    Determines if the specified date occurs within this period (inclusive of period start and end).
    final boolean
    includes(Date date, int inclusiveMask)
    Deprecated.
    Decides whether a date falls within this period.
    final boolean
    Deprecated.
    Decides whether this period intersects with another one.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • INCLUSIVE_START

      public static final int INCLUSIVE_START
      Deprecated.
      A flag indicating whether to include the start of the period in test functions.
      See Also:
    • INCLUSIVE_END

      public static final int INCLUSIVE_END
      Deprecated.
      A flag indicating whether to include the end of the period in test functions.
      See Also:
  • Constructor Details

    • DateRange

      public DateRange(Date start, Date end)
      Deprecated.
      Parameters:
      start - the start of the range
      end - the end of the range
  • Method Details

    • getRangeStart

      public Date getRangeStart()
      Deprecated.
      Returns:
      the rangeStart
    • getRangeEnd

      public Date getRangeEnd()
      Deprecated.
      Returns:
      the rangeEnd
    • includes

      public final boolean includes(Date date)
      Deprecated.
      Determines if the specified date occurs within this period (inclusive of period start and end).
      Parameters:
      date - a date to test for inclusion
      Returns:
      true if the specified date occurs within the current period
    • includes

      public final boolean includes(Date date, int inclusiveMask)
      Deprecated.
      Decides whether a date falls within this period.
      Parameters:
      date - the date to be tested
      inclusiveMask - specifies whether period start and end are included in the calculation
      Returns:
      true if the date is in the period, false otherwise
    • before

      public final boolean before(DateRange range)
      Deprecated.
      Decides whether this period is completed before the given period starts.
      Parameters:
      range - a period that may or may not start after this period ends
      Returns:
      true if the specified period starts after this periods ends, otherwise false
    • after

      public final boolean after(DateRange range)
      Deprecated.
      Decides whether this period starts after the given period ends.
      Parameters:
      range - a period that may or may not end before this period starts
      Returns:
      true if the specified period end before this periods starts, otherwise false
    • intersects

      public final boolean intersects(DateRange range)
      Deprecated.
      Decides whether this period intersects with another one.
      Parameters:
      range - a possible intersecting period
      Returns:
      true if the specified period intersects this one, false otherwise.
    • adjacent

      public final boolean adjacent(DateRange range)
      Deprecated.
      Decides whether these periods are serial without a gap.
      Parameters:
      range - a period to test for adjacency
      Returns:
      true if one period immediately follows the other, false otherwise
    • contains

      public final boolean contains(DateRange range)
      Deprecated.
      Decides whether the given period is completely contained within this one.
      Parameters:
      range - the period that may be contained by this one
      Returns:
      true if this period covers all the dates of the specified period, otherwise false
    • equals

      public boolean equals(Object o)
      Deprecated.
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Deprecated.
      Overrides:
      hashCode in class Object