|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.exist.xquery.AbstractExpression
org.exist.xquery.update.Modification
public abstract class Modification
| Field Summary | |
|---|---|
protected DocumentSet |
lockedDocuments
|
protected static org.apache.log4j.Logger |
LOG
|
protected MutableDocumentSet |
modifiedDocuments
|
protected Expression |
select
|
protected Int2ObjectHashMap<DocumentTrigger> |
triggers
|
protected Expression |
value
|
| Fields inherited from class org.exist.xquery.AbstractExpression |
|---|
column, context, contextDocSet, contextId, line, unordered |
| Fields inherited from interface org.exist.xquery.Expression |
|---|
DOT_TEST, EXPRESSION_ID_INVALID, IGNORE_CONTEXT, IN_NODE_CONSTRUCTOR, IN_PREDICATE, IN_UPDATE, IN_WHERE_CLAUSE, NEED_INDEX_INFO, NO_CONTEXT_ID, NON_STREAMABLE, POSITIONAL_PREDICATE, SINGLE_STEP_EXECUTION, UNORDERED, USE_TREE_TRAVERSAL |
| Constructor Summary | |
|---|---|
Modification(XQueryContext context,
Expression select,
Expression value)
|
|
| Method Summary | |
|---|---|
void |
analyze(AnalyzeContextInfo contextInfo)
Statically analyze the expression and its subexpressions. |
static void |
checkFragmentation(XQueryContext context,
DocumentSet docs)
|
static void |
checkFragmentation(XQueryContext context,
DocumentSet docs,
int splitCount)
Check if any of the modified documents needs defragmentation. |
void |
commitTransaction(Txn transaction)
Commit's the transaction for the update unless it is a batch update and then the commit is defered |
protected Sequence |
deepCopy(Sequence inSeq)
|
protected void |
finishTriggers(Txn transaction)
|
int |
getCardinality()
The default cardinality is Cardinality.EXACTLY_ONE. |
Txn |
getTransaction()
Gets the Transaction to use for the update (can be batch or individual) |
void |
resetState(boolean postOptimization)
Called to inform an expression that it should reset to its initial state. |
int |
returnsType()
The static return type of the expression. |
protected StoredNode[] |
selectAndLock(Txn transaction,
Sequence nodes)
Acquire a lock on all documents processed by this modification. |
protected void |
unlockDocuments()
Release all acquired document locks. |
| Methods inherited from class org.exist.xquery.AbstractExpression |
|---|
accept, allowMixNodesInReturn, eval, eval, getColumn, getContext, getContextDocSet, getContextId, getDependencies, getExpressionId, getLine, getParent, getPrimaryAxis, getSource, getSubExpression, getSubExpressionCount, match, needsReset, setASTNode, setContextDocSet, setContextId, setLocation, setPrimaryAxis, simplify |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.exist.xquery.Expression |
|---|
dump |
| Field Detail |
|---|
protected static final org.apache.log4j.Logger LOG
protected final Expression select
protected final Expression value
protected DocumentSet lockedDocuments
protected MutableDocumentSet modifiedDocuments
protected Int2ObjectHashMap<DocumentTrigger> triggers
| Constructor Detail |
|---|
public Modification(XQueryContext context,
Expression select,
Expression value)
context - | Method Detail |
|---|
public int getCardinality()
AbstractExpressionCardinality.EXACTLY_ONE.
getCardinality in interface ExpressiongetCardinality in class AbstractExpressionpublic int returnsType()
ExpressionType. If the return type cannot be determined
statically, return Type.ITEM.
returnsType in interface ExpressionreturnsType in class AbstractExpressionpublic void resetState(boolean postOptimization)
Expression
resetState in interface ExpressionresetState in class AbstractExpression
public void analyze(AnalyzeContextInfo contextInfo)
throws XPathException
Expression
XPathException
protected StoredNode[] selectAndLock(Txn transaction,
Sequence nodes)
throws LockException,
PermissionDeniedException,
XPathException,
TriggerException
nodes -
LockException
TriggerException
PermissionDeniedException
XPathException
protected Sequence deepCopy(Sequence inSeq)
throws XPathException
XPathException
protected void finishTriggers(Txn transaction)
throws TriggerException
TriggerExceptionprotected void unlockDocuments()
public static void checkFragmentation(XQueryContext context,
DocumentSet docs)
throws EXistException
EXistException
public static void checkFragmentation(XQueryContext context,
DocumentSet docs,
int splitCount)
throws EXistException
docs -
EXistExceptionpublic Txn getTransaction()
public void commitTransaction(Txn transaction)
throws TransactionException
transaction - The Transaction to commit
TransactionException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||