Returns the name of an element, attribute or processing instruction. @param pre PRE value @param kind node kind @return name
(final int pre, final int kind)
| 398 | * @return name |
| 399 | */ |
| 400 | public final byte[] name(final int pre, final int kind) { |
| 401 | if(kind == PI) { |
| 402 | final byte[] name = text(pre, true); |
| 403 | final int i = indexOf(name, ' '); |
| 404 | return i == -1 ? name : substring(name, 0, i); |
| 405 | } |
| 406 | return (kind == ELEM ? elemNames : attrNames).key(nameId(pre)); |
| 407 | } |
| 408 | |
| 409 | /** |
| 410 | * Returns the ID of the namespace URI of the addressed element or attribute. |