org.gcube.data.trees.constraints
Class BeforeDate

java.lang.Object
  extended by org.gcube.data.trees.constraints.BaseConstraint<Date>
      extended by org.gcube.data.trees.constraints.BeforeDate
All Implemented Interfaces:
Serializable, Constraint<Date>

public class BeforeDate
extends BaseConstraint<Date>

Accepts Date values that precede a given one.

Author:
Fabio Simeoni
See Also:
Serialized Form

Constructor Summary
BeforeDate()
           
BeforeDate(Date d)
          Creates an instance from a given date.
 
Method Summary
 boolean accepts(Date d)
          Returns true if a value satisfies the constraint.
 boolean equals(Object obj)
          
 int hashCode()
          
 String toString()
          
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BeforeDate

public BeforeDate()

BeforeDate

public BeforeDate(Date d)
Creates an instance from a given date.

Parameters:
d - the date
Method Detail

accepts

public boolean accepts(Date d)
Returns true if a value satisfies the constraint.

Parameters:
d - the value.
Returns:
true if the value satisfies the constraint, false if it does not.

toString

public String toString()

Overrides:
toString in class BaseConstraint<Date>

equals

public boolean equals(Object obj)

Overrides:
equals in class Object

hashCode

public int hashCode()

Overrides:
hashCode in class Object


Copyright © 2013. All Rights Reserved.