|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.interactive_instruments.ShapeChange.TargetHelper.XpathConstraintNode
de.interactive_instruments.ShapeChange.TargetHelper.XpathConstraintNode.Logic
public static class XpathConstraintNode.Logic
This class stands for logical operations AND, OR, XOR and EQV. Which of these is is coded in the state member logic.
Nested Class Summary | |
---|---|
protected static class |
XpathConstraintNode.Logic.LogicType
|
Field Summary | |
---|---|
protected XpathConstraintNode.Logic.LogicType |
logic
|
Fields inherited from class de.interactive_instruments.ShapeChange.TargetHelper.XpathConstraintNode |
---|
children, negated, parent, xpathHelper |
Constructor Summary | |
---|---|
XpathConstraintNode.Logic(XpathHelper xpathHelper,
XpathConstraintNode.Logic.LogicType logic)
Ctor |
Method Summary | |
---|---|
boolean |
isAndOrLogic(boolean isAnd)
Method to inquire whether the node inquired is a Logic node and this logic node has the same isAnd polarity as specified in the parameter. |
XpathConstraintNode.XpathFragment |
translate(XpathConstraintNode.BindingContext ctx)
This compiles the node and its children to an Xpath predicate, which can be inserted into a <rule>. |
Methods inherited from class de.interactive_instruments.ShapeChange.TargetHelper.XpathConstraintNode |
---|
addChild, bindsVariable, containsError, generatingAttribute, hasIdentity, hasSimpleType, isDependentOn, isMultiple, isVarOrAttribBased |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected XpathConstraintNode.Logic.LogicType logic
Constructor Detail |
---|
public XpathConstraintNode.Logic(XpathHelper xpathHelper, XpathConstraintNode.Logic.LogicType logic)
xpathHelper
- The schema objectisAnd
- Flag to make this an AND (true) or an OR (false)Method Detail |
---|
public boolean isAndOrLogic(boolean isAnd)
Method to inquire whether the node inquired is a Logic node and this logic node has the same isAnd polarity as specified in the parameter. XORs and EQVs are ignored and yield false.
isAndOrLogic
in class XpathConstraintNode
isAnd
- Flag: Are we an AND? (not an OR)?
public XpathConstraintNode.XpathFragment translate(XpathConstraintNode.BindingContext ctx)
This compiles the node and its children to an Xpath predicate, which can be inserted into a <rule>.
AND and OR are translated into their Xpath counterparts and and or. XOR will be realized as a != operator, EQV by an = operator.
translate
in class XpathConstraintNode
ctx
- BindingContext this node shall be compiled in
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |