MXQuery 0.6.0 API Documentation - Copyright 2006-2009 ETH Zurich

ch.ethz.mxquery.iterators.update
Class TransformIterator

java.lang.Object
  extended by ch.ethz.mxquery.model.Iterator
      extended by ch.ethz.mxquery.model.CurrentBasedIterator
          extended by ch.ethz.mxquery.iterators.update.TransformIterator
All Implemented Interfaces:
XDMIterator, Traversable

public class TransformIterator
extends CurrentBasedIterator

Represents the expression TRANSFORM.


Field Summary
 
Fields inherited from interface ch.ethz.mxquery.model.XDMIterator
EXPR_CATEGORY_SEQUENTIAL, EXPR_CATEGORY_SIMPLE, EXPR_CATEGORY_UPDATING, EXPR_CATEGORY_VACUOUS, EXPR_PARAM_CHEAPEVAL, EXPR_PARAM_VARIABLE, EXPR_PARAM_WINDOW, EXPR_PARAM_XDMGEN
 
Constructor Summary
TransformIterator(Context ctx, XDMIterator[] copyExprs, QName[] copyVars, XDMIterator modifyExpr, XDMIterator returnExpr, QueryLocation location)
          Constructor
 
Method Summary
 XDMIterator copy(Context parentIterContext, XQStaticContext prevParentIterContext, boolean copyContext, java.util.Vector nestedPredCtxStack)
          Copies the Iterator.
 XDMIterator[] getAllSubIters()
           
 Token next()
          Produces the next XDM token This method typically implements the base functionality of an Iterator and computes the value of the next token.
 void setResettable(boolean r)
          Checks if the return expression is correct.
 KXmlSerializer traverseIteratorTree(KXmlSerializer serializer)
           
 
Methods inherited from class ch.ethz.mxquery.model.Iterator
addPredicates, close, copyInts, copyIterators, copyQNames, copyStrings, copyTypeInfos, getAllSubItersRecursive, getContext, getExpressionCategoryType, getLoc, getPendingUpdateList, getPredicates, getStaticType, getSubIters, hasPredicates, isConstModePreserve, isExprParameter, isOpen, isResettable, removePredicates, reset, setConstModePreserve, setContext, setLoc, setOrderByExpr, setParam, setReturnExpr, setSubIters, setSubIters, setSubIters, setWhereExpr, traverse
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TransformIterator

public TransformIterator(Context ctx,
                         XDMIterator[] copyExprs,
                         QName[] copyVars,
                         XDMIterator modifyExpr,
                         XDMIterator returnExpr,
                         QueryLocation location)
Constructor

Parameters:
copyExprs - copy expression
copyVars - variables in which the copy expression are safed.
modifyExpr - modifying expression
returnExpr - return expression
Method Detail

setResettable

public void setResettable(boolean r)
                   throws MXQueryException
Checks if the return expression is correct.

Specified by:
setResettable in interface XDMIterator
Overrides:
setResettable in class Iterator
Parameters:
r - true make this iterator resetable, false make it not resetable
Throws:
MXQueryException

next

public Token next()
           throws MXQueryException
Description copied from interface: XDMIterator
Produces the next XDM token This method typically implements the base functionality of an Iterator and computes the value of the next token.

Returns:
The XDM token representing the next fragment of the XDM instance
Throws:
MXQueryException

getAllSubIters

public XDMIterator[] getAllSubIters()
Specified by:
getAllSubIters in interface XDMIterator
Overrides:
getAllSubIters in class Iterator

traverseIteratorTree

public KXmlSerializer traverseIteratorTree(KXmlSerializer serializer)
                                    throws java.lang.Exception
Specified by:
traverseIteratorTree in interface XDMIterator
Overrides:
traverseIteratorTree in class Iterator
Throws:
java.lang.Exception

copy

public XDMIterator copy(Context parentIterContext,
                        XQStaticContext prevParentIterContext,
                        boolean copyContext,
                        java.util.Vector nestedPredCtxStack)
                 throws MXQueryException
Description copied from interface: XDMIterator
Copies the Iterator. The context is copied (if necessary) here. The subIterators are copied (if existing) here.

Specified by:
copy in interface XDMIterator
Overrides:
copy in class Iterator
Parameters:
parentIterContext - The new parent context
prevParentIterContext - The previous context of the parent iterator
copyContext - Copy the context or use the parent context
nestedPredCtxStack - The Stack of nested predicate context, needed for nested rewritten predicates
Returns:
A copy of this Iterator
Throws:
MXQueryException

MXQuery 0.6.0 API Documentation - Copyright 2006-2009 ETH Zurich

MXQuery 0.6.0 API Documentation - Copyright 2006-2009 ETH Zurich