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

Method attValue

basex-core/src/main/java/org/basex/data/Data.java:376–383  ·  view source on GitHub ↗

Finds the specified attribute and returns its value. @param att the attribute ID of the attribute to be found @param pre PRE value @return attribute value or null

(final int att, final int pre)

Source from the content-addressed store, hash-verified

374 * @return attribute value or {@code null}
375 */
376 public final byte[] attValue(final int att, final int pre) {
377 final int a = pre + attSize(pre, kind(pre));
378 int p = pre;
379 while(++p != a) {
380 if(nameId(p) == att) return text(p, false);
381 }
382 return null;
383 }
384
385 /**
386 * Returns the ID of the name of an element, attribute or processing instruction.

Callers 3

paintComponentMethod · 0.95
labelMethod · 0.80
weightMethod · 0.80

Calls 4

attSizeMethod · 0.95
kindMethod · 0.95
nameIdMethod · 0.95
textMethod · 0.95

Tested by

no test coverage detected