com.wewebu.expression.language
Class OwExprDateValue

java.lang.Object
  extended by com.wewebu.expression.language.OwExprValue
      extended by com.wewebu.expression.language.OwExprDateValue
All Implemented Interfaces:
OwExprScope, Comparable

public class OwExprDateValue
extends OwExprValue
implements Comparable

A date value built around the Calendar Java implementation.

Alfresco Workdesk
Copyright (c) Alfresco Software, Inc.
All rights reserved.

For licensing information read the license.txt file or
go to: http://wiki.alfresco.com


Constructor Summary
OwExprDateValue(Calendar calendar_p)
          Constructor
OwExprDateValue(Calendar calendar_p, Class<?> javaType_p)
          Constructor
 
Method Summary
 OwExprValue accept(OwExprBinaryOperator binaryOperator_p, OwExprDateValue v1_p)
          Stage 2 binary operator visitor acceptance method
 OwExprValue accept(OwExprBinaryOperator binaryOperator_p, OwExprStringValue v1_p)
          Stage 2 binary operator visitor acceptance method
 OwExprValue accept(OwExprBinaryOperator binaryOperator_p, OwExprTimeValue v1_p)
          Stage 2 binary operator visitor acceptance method
 OwExprValue accept(OwExprBinaryOperator binaryOperator_p, OwExprValue v2_p)
          Stage 1 binary operator visitor acceptance method
 int compareTo(Object o_p)
           
 boolean equals(Object obj_p)
           
 Calendar getCalendar()
           
protected  Map getValuePropeties()
          Overridable default value properties factory method
 int hashCode()
           
 Object toJavaObject(Class javaSuperType_p)
          Java class conversion method.
 String toString()
           
 
Methods inherited from class com.wewebu.expression.language.OwExprValue
accept, accept, accept, accept, at, fromJavaValue, fromJavaValue, function, getJavaType, hasProperty, length, property
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OwExprDateValue

public OwExprDateValue(Calendar calendar_p)
Constructor

Parameters:
calendar_p - inner calendar value

OwExprDateValue

public OwExprDateValue(Calendar calendar_p,
                       Class<?> javaType_p)
Constructor

Parameters:
calendar_p - inner calendar value
javaType_p - original java type
Since:
1.3.0 and AWD 3.1.0
Method Detail

toJavaObject

public Object toJavaObject(Class javaSuperType_p)
                    throws OwExprEvaluationException
Description copied from class: OwExprValue
Java class conversion method.

Specified by:
toJavaObject in class OwExprValue
Parameters:
javaSuperType_p -
Returns:
always the inner calendar data - m_calendar
Throws:
OwExprEvaluationException

getValuePropeties

protected final Map getValuePropeties()
Description copied from class: OwExprValue
Overridable default value properties factory method

Overrides:
getValuePropeties in class OwExprValue
Returns:
a Map of OwExprProperty for this value

accept

public final OwExprValue accept(OwExprBinaryOperator binaryOperator_p,
                                OwExprValue v2_p)
                         throws OwExprEvaluationException
Description copied from class: OwExprValue
Stage 1 binary operator visitor acceptance method

Overrides:
accept in class OwExprValue
Parameters:
binaryOperator_p - binary operator visitor
v2_p - right side operator value
Returns:
the operator visit processed OwExprValue
Throws:
OwExprEvaluationException - if the operation fails for any reason (unsupported operand types , incompatible operands, unimplemented operation or operation failure at evaluation time)

accept

public final OwExprValue accept(OwExprBinaryOperator binaryOperator_p,
                                OwExprDateValue v1_p)
                         throws OwExprEvaluationException
Description copied from class: OwExprValue
Stage 2 binary operator visitor acceptance method

Overrides:
accept in class OwExprValue
Parameters:
binaryOperator_p - binary operator visitor
v1_p - lef side operator value
Returns:
the operator visit processed OwExprValue
Throws:
OwExprEvaluationException - if the operation fails for any reason (unsupported operand types , incompatible operands, unimplemented operation or operation failure at evaluation time)

accept

public OwExprValue accept(OwExprBinaryOperator binaryOperator_p,
                          OwExprStringValue v1_p)
                   throws OwExprEvaluationException
Description copied from class: OwExprValue
Stage 2 binary operator visitor acceptance method

Overrides:
accept in class OwExprValue
Parameters:
binaryOperator_p - binary operator visitor
v1_p - lef side operator value
Returns:
the operator visit processed OwExprValue
Throws:
OwExprEvaluationException - if the operation fails for any reason (unsupported operand types , incompatible operands, unimplemented operation or operation failure at evaluation time)

accept

public OwExprValue accept(OwExprBinaryOperator binaryOperator_p,
                          OwExprTimeValue v1_p)
                   throws OwExprEvaluationException
Description copied from class: OwExprValue
Stage 2 binary operator visitor acceptance method

Overrides:
accept in class OwExprValue
Parameters:
binaryOperator_p - binary operator visitor
v1_p - lef side operator value
Returns:
the operator visit processed OwExprValue
Throws:
OwExprEvaluationException - if the operation fails for any reason (unsupported operand types , incompatible operands, unimplemented operation or operation failure at evaluation time)

getCalendar

public final Calendar getCalendar()
Returns:
the inner calendar data

compareTo

public int compareTo(Object o_p)
Specified by:
compareTo in interface Comparable

equals

public boolean equals(Object obj_p)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2013 Alfresco Business Solutions. All Rights Reserved.