Package org.basex.query
Class QueryPlan
- java.lang.Object
-
- org.basex.query.QueryPlan
-
public final class QueryPlan extends Object
Query plan builder.- Author:
- BaseX Team 2005-22, BSD License, Christian Gruen
-
-
Constructor Summary
Constructors Constructor Description QueryPlan(boolean compiled, boolean updating, boolean full)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(FElem elem, Object... children)
Adds children to the specified element.void
add(FElem elem, ExprInfo... children)
Adds children to the specified element.void
addAttribute(FElem elem, Object name, Object value)
Adds an attribute to the specified element if the specified value is notnull
.void
addElement(FElem elem, FElem child)
Adds a child element to the specified element.FElem
attachVariable(FElem elem, Var var, boolean type)
Attaches variable information to the specified element.FElem
create(String name, Var var)
Creates a new element node to be added to the query plan.FElem
create(ExprInfo expr, Object... atts)
Creates a new element node to be added to the query plan.FElem
root()
Returns the root node.
-
-
-
Method Detail
-
root
public FElem root()
Returns the root node.- Returns:
- root node
-
add
public void add(FElem elem, Object... children)
Adds children to the specified element.- Parameters:
elem
- new elementchildren
- expressions to be added (null
references will be ignored)
-
add
public void add(FElem elem, ExprInfo... children)
Adds children to the specified element.- Parameters:
elem
- new elementchildren
- expressions (null
references will be ignored)
-
create
public FElem create(ExprInfo expr, Object... atts)
Creates a new element node to be added to the query plan.- Parameters:
expr
- calling expressionatts
- attribute names and values- Returns:
- element
-
create
public FElem create(String name, Var var)
Creates a new element node to be added to the query plan.- Parameters:
name
- name of elementvar
- variable to attach (can benull
)- Returns:
- element
-
addAttribute
public void addAttribute(FElem elem, Object name, Object value)
Adds an attribute to the specified element if the specified value is notnull
.- Parameters:
elem
- element to which the attribute will be addedname
- namevalue
- value ornull
-
addElement
public void addElement(FElem elem, FElem child)
Adds a child element to the specified element.- Parameters:
elem
- element to which the attribute will be addedchild
- child element
-
-