common-util

local.tomas.expr
Class DateConstant

java.lang.Object
  extended by local.tomas.expr.DateConstant
All Implemented Interfaces:
Serializable, Constant, Expression

public class DateConstant
extends Object
implements Constant

A date constant.

Author:
Teubner
See Also:
Serialized Form

Constructor Summary
DateConstant()
          Default constructor.
DateConstant(Date value)
          Constructor using fields.
 
Method Summary
 boolean equals(Object obj)
          Compares this object against the specified object.
 Date getValue()
          Get date value
<E,F> E
greet(ExpressionWalker<E,F> visitor, F arg)
          Handle visit of ExpressionWalker.
 int hashCode()
           
 void setValue(Date value)
          Set date value.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DateConstant

public DateConstant()
Default constructor.


DateConstant

public DateConstant(Date value)
Constructor using fields.

Parameters:
value - date value
Method Detail

getValue

public Date getValue()
Get date value

Returns:
the value.

setValue

public void setValue(Date value)
Set date value.

Parameters:
value - value to set.

greet

public <E,F> E greet(ExpressionWalker<E,F> visitor,
                     F arg)
        throws ExpressionException
Description copied from interface: Expression
Handle visit of ExpressionWalker.

Specified by:
greet in interface Expression
Parameters:
visitor - the ExpressionWalker visiting this object
arg - implementation dependent argument
Returns:
implementation dependent result
Throws:
ExpressionException

equals

public boolean equals(Object obj)
Compares this object against the specified object. The result is true if and only if the argument is not null and is a DateConstant object with equal value as this object.

Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

common-util

Copyright © 2005-2007 Tomas Teubner. All Rights Reserved.