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

Method value

basex-core/src/main/java/org/basex/query/var/StaticVar.java:76–95  ·  view source on GitHub ↗
(final QueryContext qc)

Source from the content-addressed store, hash-verified

74 }
75
76 @Override
77 public Value value(final QueryContext qc) throws QueryException {
78 if(dontEnter) throw CIRCVAR_X.get(info, name());
79 if(!lazy && expr == null) throw VAREMPTY_X.get(info, name());
80
81 if(value == null) {
82 dontEnter = true;
83 final QueryFocus focus = pushFocus(qc);
84 try {
85 super.value(qc);
86 } catch(final QueryException ex) {
87 if(lazy) ex.notCatchable();
88 throw ex;
89 } finally {
90 qc.focus = focus;
91 dontEnter = false;
92 }
93 }
94 return value;
95 }
96
97 /**
98 * Ensures that the variable expression is not updating.

Callers 1

compileMethod · 0.95

Calls 4

nameMethod · 0.95
pushFocusMethod · 0.95
notCatchableMethod · 0.80
getMethod · 0.65

Tested by

no test coverage detected