public class XpathConstraint extends MutableTypeConstraint
| Modifier and Type | Class and Description |
|---|---|
static class |
XpathConstraint.XpathChunk |
static class |
XpathConstraint.XpathDataProvider |
Constraint.ConstraintType| Constructor and Description |
|---|
XpathConstraint() |
| Modifier and Type | Method and Description |
|---|---|
XpathConstraint.XpathChunk |
addChunck(Class<?> clazz,
String field,
int index,
boolean iterate,
boolean lazy) |
XpathConstraint |
clone()
Clones the constraint
|
ContextEntry |
createContextEntry() |
LinkedList<XpathConstraint.XpathChunk> |
getChunks() |
Declaration |
getDeclaration() |
InternalReadAccessor |
getReadAccessor() |
Declaration[] |
getRequiredDeclarations()
Returns all the declarations required by the given
constraint implementation.
|
Class<?> |
getResultClass() |
Constraint.ConstraintType |
getType()
Returns the type of the constraint, either ALPHA, BETA or UNKNOWN
|
Declaration |
getXpathStartDeclaration() |
boolean |
isAllowed(InternalFactHandle handle,
InternalWorkingMemory workingMemory) |
boolean |
isAllowedCachedLeft(ContextEntry context,
InternalFactHandle handle) |
boolean |
isAllowedCachedRight(Tuple tuple,
ContextEntry context) |
boolean |
isTemporal()
Returns true in case this constraint is a temporal constraint
|
void |
readExternal(ObjectInput in) |
void |
replaceDeclaration(Declaration oldDecl,
Declaration newDecl)
When a rule contains multiple logical branches, i.e., makes
use of 'OR' CE, it is required to clone patterns and declarations
for each logical branch.
|
void |
setDeclaration(Declaration declaration) |
void |
setXpathStartDeclaration(Declaration xpathStartDeclaration) |
String |
toString() |
void |
writeExternal(ObjectOutput out) |
cloneIfInUse, setInUse, setTypeequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetListenedPropertyMaskpublic XpathConstraint.XpathChunk addChunck(Class<?> clazz, String field, int index, boolean iterate, boolean lazy)
public Constraint.ConstraintType getType()
ConstraintgetType in interface ConstraintgetType in class MutableTypeConstraintpublic Declaration[] getRequiredDeclarations()
Constraintpublic void replaceDeclaration(Declaration oldDecl, Declaration newDecl)
Constraintpublic XpathConstraint clone()
Constraintclone in interface Constraintclone in class MutableTypeConstraintpublic boolean isTemporal()
Constraintpublic boolean isAllowedCachedLeft(ContextEntry context, InternalFactHandle handle)
public boolean isAllowedCachedRight(Tuple tuple, ContextEntry context)
public ContextEntry createContextEntry()
public boolean isAllowed(InternalFactHandle handle, InternalWorkingMemory workingMemory)
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal in interface ExternalizablereadExternal in class MutableTypeConstraintIOExceptionClassNotFoundExceptionpublic void writeExternal(ObjectOutput out) throws IOException
writeExternal in interface ExternalizablewriteExternal in class MutableTypeConstraintIOExceptionpublic LinkedList<XpathConstraint.XpathChunk> getChunks()
public Class<?> getResultClass()
public Declaration getDeclaration()
public void setDeclaration(Declaration declaration)
public InternalReadAccessor getReadAccessor()
public Declaration getXpathStartDeclaration()
public void setXpathStartDeclaration(Declaration xpathStartDeclaration)
Copyright © 2001–2019 JBoss by Red Hat. All rights reserved.