Package org.basex.core.cmd
Class Find
java.lang.Object
org.basex.core.jobs.Job
org.basex.core.Command
org.basex.core.cmd.AQuery
org.basex.core.cmd.Find
Evaluates the 'find' command and processes a simplified request as XQuery.
- Author:
- BaseX Team 2005-21, BSD License, Christian Gruen
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddLocks()Adds the strings (databases, special identifiers) for which locks need to be acquired.static StringCreates an XQuery representation for the specified query.static StringfindTable(StringList filter, TokenList cols, BoolList elem, byte[] name, boolean root) Creates an XQuery representation for the specified table query.protected booleanrun()Executes the command and serializes the result (internal call).booleanChecks if the command performs updates/write operations.Methods inherited from class org.basex.core.cmd.AQuery
build, parameters, result, stoppable, updatedMethods inherited from class org.basex.core.Command
addLocks, baseURI, baseURI, close, error, exception, execute, execute, getOption, getOption, info, info, init, maxResults, newData, run, run, setInput, setInput, supportsProg, toString, toString
-
Constructor Details
-
Find
Default constructor.- Parameters:
query- simplified query
-
Find
Default constructor.- Parameters:
query- simplified queryrt- start from root node
-
-
Method Details
-
run
protected boolean run()Description copied from class:CommandExecutes the command and serializes the result (internal call). -
updating
Description copied from class:CommandChecks if the command performs updates/write operations. -
addLocks
public void addLocks()Description copied from class:JobAdds the strings (databases, special identifiers) for which locks need to be acquired. -
find
Creates an XQuery representation for the specified query.- Parameters:
query- queryctx- database contextroot- start from root node- Returns:
- query
-
findTable
public static String findTable(StringList filter, TokenList cols, BoolList elem, byte[] name, boolean root) Creates an XQuery representation for the specified table query.- Parameters:
filter- filter termscols- filter columnselem- element flagname- name of root elementroot- root flag- Returns:
- query
-