|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.objectweb.medor.filter.lib.BasicBinaryOperator | +--org.objectweb.medor.filter.lib.NavigatorOperator
A NavigatorOperator typically represents a path expression.
Such an expression starts from a FieldOperand for which the origin field is a JormField of a PName type (ref).
Field Summary | |
protected boolean |
isPName
|
Fields inherited from class org.objectweb.medor.filter.lib.BasicBinaryOperator |
left, leftResult, result, right, rightResult, type, verified |
Fields inherited from interface org.objectweb.medor.filter.api.Operator |
ABS, AND, AVG, BITWIZE, CONCAT, CONDAND, CONDOR, COUNT, DIV, EQUAL, FIRSTLOCATE, GREATER, GREATEREQUAL, IN, INDEXEDLOCATE, LENGTH, LOWER, LOWEREQUAL, MAX, MEMBEROF, MIN, MINUS, MOD, MULT, NAV, NOT, NOTEQUAL, NOTMEMBEROF, OR, PLUS, SQRT, SUBSTRING, SUM, UMINUS |
Constructor Summary | |
NavigatorOperator(FieldOperand fop,
java.lang.String att)
Creates a NavigatorOperator from a FieldOperand and an attribute name. |
|
NavigatorOperator(NavigatorOperator nop,
java.lang.String att)
Creates a NavigatorOperator from a previously existing NavigatorOperator and an attribute name. |
Method Summary | |
void |
compileExpression()
Checks the semantic integrity of an expression. |
void |
evaluate(ParameterOperand[] pos,
Tuple t)
This operator is not evaluable, and must be transformed into JoinProject instances during the optimization step. |
MetaObject |
getMetaObject()
Returns the Jorm Meta object which describes the field that is reached by this navigator. |
java.lang.String |
getOperatorString()
Returns the String representing the operator in Java |
boolean |
isPName()
Returns 'true' if the current path designes a field which is a reference. |
Methods inherited from class org.objectweb.medor.filter.lib.BasicBinaryOperator |
clone, getExpression, getLeftExpression, getOperandNumber, getResult, getRightExpression, getType, isCompiled, setExpression, setLeftExpression, setRightExpression |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected boolean isPName
Constructor Detail |
public NavigatorOperator(FieldOperand fop, java.lang.String att) throws MedorException
fop
- is the FieldOperand corresponding to the left operand.att
- is the name of the attribute to which the operator nagivates.
MedorException
- when fop does not reference a PNameField
or when no field att is reachable by the PNameField.public NavigatorOperator(NavigatorOperator nop, java.lang.String att) throws MedorException
nop
- is the NavigatorOperator corresponding to the left operand.att
- is the name of the attribute to which the operator nagivates.
MedorException
- when nop does not match to a PName
or when no field att is reachable by the PName.Method Detail |
public boolean isPName()
public MetaObject getMetaObject()
public java.lang.String getOperatorString()
public void evaluate(ParameterOperand[] pos, Tuple t) throws MedorException
evaluate
in interface Expression
evaluate
in class BasicBinaryOperator
pos
- a list of ParameterOperandt
- Tuple
MedorException
- if evaluation errorpublic void compileExpression() throws MalformedExpressionException
It checks that all types are compatible and prepare the expression to be evaluable.It also creates buffers where stores the result. Notes that when evaluating there is no creation of new objects. This method change the state of this expression object, it will be evaluable and not modifiable.
MalformedExpressionException
- if syntax error
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |