/** * Get the local part of the QName * * @return the local part of the QName */ public String getLocalPart() { return pool.getLocalName(fingerprint); }
/** * Get the local part of the QName * * @return the local part of the QName */ public String getLocalPart() { return pool.getLocalName(fingerprint); }
/** * Test whether this node test is satisfied by a given node * @param nodeType The type of node to be matched * @param fingerprint identifies the expanded name of the node to be matched */ public boolean matches(int nodeType, int fingerprint, int annotation) { if (fingerprint == -1) return false; if (nodeType != nodeKind) return false; return localName.equals(namePool.getLocalName(fingerprint)); }
/** * Get the local name of this node. * @return The local name of this node. * For a node with no name, return an empty string. */ public String getLocalPart() { return tree.getNamePool().getLocalName(tree.attCode[nodeNr]); }
/** * Get the local name of an attribute (by position). * * @param index The position of the attribute in the list. * @return The local name of the attribute as a string, or null if there * is no attribute at that position. */ public String getLocalName(int index) { return tree.getNamePool().getLocalName(tree.attCode[firstAttribute + index]); }
public String getPITarget() { if (currentStaxEvent != XMLStreamConstants.PROCESSING_INSTRUCTION) { throw new IllegalStateException("Not positioned at a processing instruction"); } return namePool.getLocalName(((NodeInfo)currentItem).getNameCode()); }
public String getPITarget() { if (currentStaxEvent != XMLStreamConstants.PROCESSING_INSTRUCTION) { throw new IllegalStateException("Not positioned at a processing instruction"); } return namePool.getLocalName(provider.getNameCode()); }
/** * Get the local name of this node. * * @return The local name of this node. * For a node with no name, return an empty string. */ public String getLocalPart() { return tree.getNamePool().getLocalName(tree.attCode[nodeNr]); }
public String getLocalName() { if (currentStaxEvent != START_ELEMENT && currentStaxEvent != END_ELEMENT) { throw new IllegalStateException(""+currentStaxEvent); } return namePool.getLocalName(startElementEvent.getNameCode()); }
public IntPredicate getMatcher(final NodeVectorTree tree) { final byte[] nodeKindArray = tree.getNodeKindArray(); final int[] nameCodeArray = tree.getNameCodeArray(); return nodeNr -> (nodeKindArray[nodeNr] & 0x0f) == nodeKind && localName.equals(namePool.getLocalName(nameCodeArray[nodeNr] & 0xfffff)); }
public IntPredicate getMatcher(final NodeVectorTree tree) { final byte[] nodeKindArray = tree.getNodeKindArray(); final int[] nameCodeArray = tree.getNameCodeArray(); return nodeNr -> (nodeKindArray[nodeNr] & 0x0f) == nodeKind && localName.equals(namePool.getLocalName(nameCodeArray[nodeNr] & 0xfffff)); }
public QName getName() { if (currentStaxEvent != START_ELEMENT && currentStaxEvent != END_ELEMENT) { throw new IllegalStateException(""+currentStaxEvent); } int nc = startElementEvent.getNameCode(); return new QName(namePool.getURI(nc), namePool.getLocalName(nc), namePool.getPrefix(nc)); }
/** * Get the local name of an attribute (by position). * * @param index The position of the attribute in the list. * @return The local name of the attribute as a string, or null if there * is no attribute at that position. */ public String getLocalName(int index) { return tree.getNamePool().getLocalName(getNameCode(index)); }
public QName getName() { int nc = provider.getNameCode(); return new QName(namePool.getURI(nc), namePool.getLocalName(nc), namePool.getPrefix(nc)); }
public String toShortString() { switch (nodeKind) { case Type.ELEMENT: return getNamespaceURI().isEmpty() ? namePool.getLocalName(getFingerprint()) : toString(); case Type.ATTRIBUTE: return "@" + (getNamespaceURI().isEmpty() ? namePool.getLocalName(getFingerprint()) : toString()); default: return toString(); } }
/** * Constructor starting from a NamePool namecode * @param namePool The name pool containing the specified name code * @param nameCode The name code identifying this name in the name pool */ public QNameValue(NamePool namePool, int nameCode) { String prefix = namePool.getPrefix(nameCode); String uri = namePool.getURI(nameCode); String localPart = namePool.getLocalName(nameCode); qName = new StructuredQName(prefix, uri, localPart); typeLabel = BuiltInAtomicType.QNAME; }
/** * Constructor starting from a NamePool namecode * @param namePool The name pool containing the specified name code * @param nameCode The name code identifying this name in the name pool */ public QNameValue(NamePool namePool, int nameCode) { String prefix = namePool.getPrefix(nameCode); String uri = namePool.getURI(nameCode); String localPart = namePool.getLocalName(nameCode); qName = new StructuredQName(prefix, uri, localPart); typeLabel = BuiltInAtomicType.QNAME; }
/** * Get the index, given the fingerprint */ public int getIndexByFingerprint(int fingerprint) { return getIndex(getNamePool().getURI(fingerprint), getNamePool().getLocalName(fingerprint)); }
/** * Get the index, given the fingerprint */ public int getIndexByFingerprint(int fingerprint) { return getIndex(getNamePool().getURI(fingerprint), getNamePool().getLocalName(fingerprint)); }
private void checkNotTemporaryOutputState(XPathContext context) throws XPathException { if (context.getTemporaryOutputState() != 0) { XPathException err = new XPathException("Cannot execute xsl:result-document while evaluating xsl:" + context.getNamePool().getLocalName(context.getTemporaryOutputState())); err.setErrorCode("XTDE1480"); err.setLocation(getLocation()); throw err; } }