org.springmodules.validation.util.condition.date
Class IsAfterDateCondition
java.lang.Object
org.springmodules.validation.util.condition.AbstractCondition
org.springmodules.validation.util.condition.TypeSpecificCondition
org.springmodules.validation.util.condition.NonNullAcceptingTypeSpecificCondition
org.springmodules.validation.util.condition.date.AbstractDateCondition
org.springmodules.validation.util.condition.date.IsAfterDateCondition
- All Implemented Interfaces:
- Condition
public class IsAfterDateCondition
- extends AbstractDateCondition
An AbstractDateCondition
implementation that checks whether the checked calendar is chronologically after
a specific calendar.
- Author:
- Uri Boness
Constructor Summary |
IsAfterDateCondition(Calendar earlier)
Constructs a new IsAfterDateCondition with a given calendar to be compared with the checked calendar. |
IsAfterDateCondition(Date earlier)
Constructs a new IsAfterDateCondition with a given date to be compared with the checked calendar. |
Method Summary |
protected boolean |
checkCalendar(Calendar calendar)
Checks whether the given calendar is chornologically after the calendar associated with this condition. |
Calendar |
getEarlier()
Returns the calendar associated with this condition. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
IsAfterDateCondition
public IsAfterDateCondition(Date earlier)
- Constructs a new IsAfterDateCondition with a given date to be compared with the checked calendar.
- Parameters:
earlier
- The date to be compared with the checked calendar.
IsAfterDateCondition
public IsAfterDateCondition(Calendar earlier)
- Constructs a new IsAfterDateCondition with a given calendar to be compared with the checked calendar.
- Parameters:
earlier
- The calendar to be compared with the checked calendar.
checkCalendar
protected boolean checkCalendar(Calendar calendar)
- Checks whether the given calendar is chornologically after the calendar associated with this condition.
- Specified by:
checkCalendar
in class AbstractDateCondition
- Parameters:
calendar
- The calendar to be checked.
- Returns:
true
if the given calender comes after the calendar associated with this condition,
false
otherwise.
getEarlier
public Calendar getEarlier()
- Returns the calendar associated with this condition.
- Returns:
- The calendar associated with this condition.
Copyright © 2009. All Rights Reserved.