org.objectweb.medor.query.lib
Class BasicCalculatedField

java.lang.Object
  |
  +--org.objectweb.medor.query.lib.BasicCalculatedField
All Implemented Interfaces:
CalculatedField, Cloneable, java.lang.Cloneable, Field, QueryTreeField

public class BasicCalculatedField
extends java.lang.Object
implements CalculatedField

Author:
Sebastien Chassande-Barrioz

Field Summary
protected  Expression e
           
protected  java.lang.String name
           
protected  PType type
           
 
Fields inherited from interface org.objectweb.medor.api.Field
NONULLS, NULLABLE, NULLABLEUNKNOWN, PNAMENAME
 
Constructor Summary
BasicCalculatedField(Expression e)
           
BasicCalculatedField(java.lang.String name, PType type, QueryTree qt, Expression e)
           
 
Method Summary
 java.lang.Object clone()
           
 Expression getExpression()
           
 java.lang.String getName()
          Returns the Field name
 short getNullStatus()
          What is the status of the Field regarding null values (NullStatus).
 Field[] getOriginUsedFields()
           
protected  java.util.ArrayList getOriginUsedFields(java.util.ArrayList src, java.util.ArrayList dst)
           
 QueryTree getQueryTree()
           
 PType getType()
          Returns the field type, as a PType
 java.util.ArrayList getUsed()
           
 Field[] getUsedFields()
           
 void setExpression(Expression e)
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

name

protected java.lang.String name

type

protected PType type

e

protected Expression e
Constructor Detail

BasicCalculatedField

public BasicCalculatedField(java.lang.String name,
                            PType type,
                            QueryTree qt,
                            Expression e)

BasicCalculatedField

public BasicCalculatedField(Expression e)
Method Detail

getQueryTree

public QueryTree getQueryTree()
Specified by:
getQueryTree in interface QueryTreeField

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Specified by:
clone in interface Cloneable
Overrides:
clone in class java.lang.Object
java.lang.CloneNotSupportedException

getName

public java.lang.String getName()
Description copied from interface: Field
Returns the Field name

Specified by:
getName in interface Field
Returns:
the Field name

getType

public PType getType()
Description copied from interface: Field
Returns the field type, as a PType

Specified by:
getType in interface Field
Returns:
the Field type

getExpression

public Expression getExpression()
Specified by:
getExpression in interface CalculatedField

setExpression

public void setExpression(Expression e)
Specified by:
setExpression in interface CalculatedField

getUsedFields

public Field[] getUsedFields()
Specified by:
getUsedFields in interface CalculatedField

getOriginUsedFields

public Field[] getOriginUsedFields()
Specified by:
getOriginUsedFields in interface CalculatedField

getOriginUsedFields

protected java.util.ArrayList getOriginUsedFields(java.util.ArrayList src,
                                                  java.util.ArrayList dst)

getUsed

public java.util.ArrayList getUsed()

getNullStatus

public short getNullStatus()
Description copied from interface: Field
What is the status of the Field regarding null values (NullStatus).

Specified by:
getNullStatus in interface Field
Returns:
the Null status of the Field
See Also:
NullStatus