/** * Get the next node in the iteration. * * @return The next node handle in the iteration, or END. */ public int next() { if ((_nsPrefix == null) ||(_nsPrefix.length() == 0) ){ return (END); } int node = END; for (node = super.next(); node != END; node = super.next()) { if (_nsPrefix.compareTo(getLocalName(node))== 0) { return returnNode(node); } } return (END); } } // end of TypedNamespaceIterator
/** * Lookup a namespace URI from a prefix starting at node. This method * is used in the execution of xsl:element when the prefix is not known * at compile time. */ public String lookupNamespace(int node, String prefix) throws TransletException { int anode, nsnode; final AncestorIterator ancestors = new AncestorIterator(); if (isElement(node)) { ancestors.includeSelf(); } ancestors.setStartNode(node); while ((anode = ancestors.next()) != DTM.NULL) { final NamespaceIterator namespaces = new NamespaceIterator(); namespaces.setStartNode(anode); while ((nsnode = namespaces.next()) != DTM.NULL) { if (getLocalName(nsnode).equals(prefix)) { return getNodeValue(nsnode); } } } BasisLibrary.runTimeError(BasisLibrary.NAMESPACE_PREFIX_ERR, prefix); return null; }
/** * Get the next node in the iteration. * * @return The next node handle in the iteration, or END. */ public int next() { if ((_nsPrefix == null) ||(_nsPrefix.length() == 0) ){ return (END); } int node = END; for (node = super.next(); node != END; node = super.next()) { if (_nsPrefix.compareTo(getLocalName(node))== 0) { return returnNode(node); } } return (END); } } // end of TypedNamespaceIterator
/** * Lookup a namespace URI from a prefix starting at node. This method * is used in the execution of xsl:element when the prefix is not known * at compile time. */ public String lookupNamespace(int node, String prefix) throws TransletException { int anode, nsnode; final AncestorIterator ancestors = new AncestorIterator(); if (isElement(node)) { ancestors.includeSelf(); } ancestors.setStartNode(node); while ((anode = ancestors.next()) != DTM.NULL) { final NamespaceIterator namespaces = new NamespaceIterator(); namespaces.setStartNode(anode); while ((nsnode = namespaces.next()) != DTM.NULL) { if (getLocalName(nsnode).equals(prefix)) { return getNodeValue(nsnode); } } } BasisLibrary.runTimeError(BasisLibrary.NAMESPACE_PREFIX_ERR, prefix); return null; }
/** * Lookup a namespace URI from a prefix starting at node. This method * is used in the execution of xsl:element when the prefix is not known * at compile time. */ public String lookupNamespace(int node, String prefix) throws TransletException { int anode, nsnode; final AncestorIterator ancestors = new AncestorIterator(); if (isElement(node)) { ancestors.includeSelf(); } ancestors.setStartNode(node); while ((anode = ancestors.next()) != DTM.NULL) { final NamespaceIterator namespaces = new NamespaceIterator(); namespaces.setStartNode(anode); while ((nsnode = namespaces.next()) != DTM.NULL) { if (getLocalName(nsnode).equals(prefix)) { return getNodeValue(nsnode); } } } BasisLibrary.runTimeError(BasisLibrary.NAMESPACE_PREFIX_ERR, prefix); return null; }
/** * Lookup a namespace URI from a prefix starting at node. This method * is used in the execution of xsl:element when the prefix is not known * at compile time. */ public String lookupNamespace(int node, String prefix) throws TransletException { int anode, nsnode; final AncestorIterator ancestors = new AncestorIterator(); if (isElement(node)) { ancestors.includeSelf(); } ancestors.setStartNode(node); while ((anode = ancestors.next()) != DTM.NULL) { final NamespaceIterator namespaces = new NamespaceIterator(); namespaces.setStartNode(anode); while ((nsnode = namespaces.next()) != DTM.NULL) { if (getLocalName(nsnode).equals(prefix)) { return getNodeValue(nsnode); } } } BasisLibrary.runTimeError(BasisLibrary.NAMESPACE_PREFIX_ERR, prefix); return null; }
/** * Get the next node in the iteration. * * @return The next node handle in the iteration, or END. */ public int next() { if ((_nsPrefix == null) ||(_nsPrefix.length() == 0) ){ return (END); } int node = END; for (node = super.next(); node != END; node = super.next()) { if (_nsPrefix.compareTo(getLocalName(node))== 0) { return returnNode(node); } } return (END); } } // end of TypedNamespaceIterator
/** * Get the next node in the iteration. * * @return The next node handle in the iteration, or END. */ public int next() { if ((_nsPrefix == null) ||(_nsPrefix.length() == 0) ){ return (END); } int node = END; for (node = super.next(); node != END; node = super.next()) { if (_nsPrefix.compareTo(getLocalName(node))== 0) { return returnNode(node); } } return (END); } } // end of TypedNamespaceIterator