lux.xquery
Class ElementConstructor
java.lang.Object
lux.xpath.AbstractExpression
lux.xquery.ElementConstructor
- All Implemented Interfaces:
- Visitable
public class ElementConstructor
- extends AbstractExpression
| Methods inherited from class lux.xpath.AbstractExpression |
acceptSubs, appendSub, getBindingContext, getLastContextStep, getRoot, getSubs, getSuper, getTail, getType, isAbsolute, isDocumentOrdered, replaceRoot, setSubs, toString |
ElementConstructor
public ElementConstructor(QName qname,
Namespace[] namespaces,
AbstractExpression content,
AttributeConstructor... attributes)
- Make an element constructor - this models literal element constructors, not computed element
constructors.
- Parameters:
qname - the name of the elementnamespaces - this element's namespace declarationscontent - the content of the elementattributes - the element's literal attributes - these AttributeConstructors
may only have LiteralExpressions for their names and values
ElementConstructor
public ElementConstructor(QName qname,
AbstractExpression content,
AttributeConstructor... attributes)
ElementConstructor
public ElementConstructor(QName qname,
AttributeConstructor... attributes)
getName
public QName getName()
accept
public AbstractExpression accept(ExpressionVisitor visitor)
toString
public void toString(StringBuilder buf)
- Description copied from class:
AbstractExpression
- Each subclass must implement the toString(StringBuilder) method by
rendering itself as a syntatically valid XPath/XQuery expression in
the given buffer.
- Specified by:
toString in class AbstractExpression
getPrecedence
public int getPrecedence()
- Specified by:
getPrecedence in class AbstractExpression
- Returns:
- a number indicating the *outer* precedence of this expression.
Expressions with lower precedence numbers have lower
precedence, ie bind more loosely, than expressions with higher
precedence. Expressions with no sub-expressions are assigned a high
precedence. Complex expressions can be seen as having an inner and an outer
precedence; for example function call expressions behave as a comma with regard
to their sub-expressions, the arguments, and like parentheses to their enclosing expression.
Copyright © 2013. All Rights Reserved.