Class DateTerm

All Implemented Interfaces:
Serializable
Direct Known Subclasses:
ReceivedDateTerm, SentDateTerm

public abstract class DateTerm extends ComparisonTerm
This class implements comparisons for Dates
Author:
Bill Shannon, John Mani
See Also:
  • Field Details

    • date

      protected Date date
      The date.
  • Constructor Details

    • DateTerm

      protected DateTerm(int comparison, Date date)
      Constructor.
      Parameters:
      comparison - the comparison type
      date - The Date to be compared against
  • Method Details

    • getDate

      public Date getDate()
      Return the Date to compare with.
      Returns:
      the date
    • getComparison

      public int getComparison()
      Return the type of comparison.
      Returns:
      the comparison type
    • match

      protected boolean match(Date d)
      The date comparison method.
      Parameters:
      d - the date in the constructor is compared with this date
      Returns:
      true if the dates match, otherwise false
    • equals

      public boolean equals(Object obj)
      Equality comparison.
      Overrides:
      equals in class ComparisonTerm
    • hashCode

      public int hashCode()
      Compute a hashCode for this object.
      Overrides:
      hashCode in class ComparisonTerm