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

Method opt

basex-core/src/main/java/org/basex/query/func/map/MapKeys.java:20–27  ·  view source on GitHub ↗
(final CompileContext cc)

Source from the content-addressed store, hash-verified

18 }
19
20 @Override
21 protected Expr opt(final CompileContext cc) {
22 final Expr map = arg(0);
23 if(map.seqType().type instanceof final MapType mt) {
24 exprType.assign(mt.keyType().seqType(Occ.ZERO_OR_MORE), map.structSize());
25 }
26 return this;
27 }
28}

Callers

nothing calls this directly

Calls 6

seqTypeMethod · 0.95
structSizeMethod · 0.95
keyTypeMethod · 0.80
seqTypeMethod · 0.65
argMethod · 0.45
assignMethod · 0.45

Tested by

no test coverage detected