MCPcopy Create free account
hub / github.com/BaseXdb/basex / query

Method query

basex-core/src/main/java/org/basex/core/Sandbox.java:91–101  ·  view source on GitHub ↗

Runs a query and returns exceptions into assertion errors. @param query query to be evaluated @return string result

(final String query)

Source from the content-addressed store, hash-verified

89 * @return string result
90 */
91 protected static String query(final String query) {
92 try {
93 return eval(query);
94 } catch(final JobException ex) {
95 Util.debug(ex);
96 return "";
97 } catch(final QueryException | IOException ex) {
98 Util.stack(ex);
99 return fail("Query failed:\n" + query, ex);
100 }
101 }
102
103 /**
104 * Checks if a query yields the specified string.

Callers 2

containsMethod · 0.95
checkTypeMethod · 0.95

Calls 4

evalMethod · 0.95
debugMethod · 0.95
stackMethod · 0.95
compareMethod · 0.95

Tested by

no test coverage detected