/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode the node relative to which the XPath * statement will be executed. * xPath the XPath statement * namespaceResolver used to resolve namespace prefixes * to the corresponding namespace URI * @return the XPath result * @throws XMLPlatformException */ public NodeList selectNodesAdvanced(Node contextNode, String xPathString, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XPath xPath = getXPathFactory().newXPath(); if(null != xmlNamespaceResolver) { JAXPNamespaceContext namespaceContext = new JAXPNamespaceContext(xmlNamespaceResolver); xPath.setNamespaceContext(namespaceContext); } XPathExpression xPathExpression = xPath.compile(xPathString); return (NodeList) xPathExpression.evaluate(contextNode, XPathConstants.NODESET); } catch(XPathException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }
/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode the node relative to which the XPath * statement will be executed. * xPath the XPath statement * namespaceResolver used to resolve namespace prefixes * to the corresponding namespace URI * @return the XPath result * @throws XMLPlatformException */ @Override public NodeList selectNodesAdvanced(Node contextNode, String xPathString, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XPath xPath = getXPathFactory().newXPath(); if(null != xmlNamespaceResolver) { JAXPNamespaceContext namespaceContext = new JAXPNamespaceContext(xmlNamespaceResolver); xPath.setNamespaceContext(namespaceContext); } XPathExpression xPathExpression = xPath.compile(xPathString); return (NodeList) xPathExpression.evaluate(contextNode, XPathConstants.NODESET); } catch(XPathException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }
/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode the node relative to which the XPath * statement will be executed. * xPath the XPath statement * namespaceResolver used to resolve namespace prefixes * to the corresponding namespace URI * @return the XPath result * @throws XMLPlatformException */ public NodeList selectNodesAdvanced(Node contextNode, String xPathString, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XPath xPath = getXPathFactory().newXPath(); if(null != xmlNamespaceResolver) { JAXPNamespaceContext namespaceContext = new JAXPNamespaceContext(xmlNamespaceResolver); xPath.setNamespaceContext(namespaceContext); } XPathExpression xPathExpression = xPath.compile(xPathString); return (NodeList) xPathExpression.evaluate(contextNode, XPathConstants.NODESET); } catch(XPathException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }
/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode * @param xPathString * @param xmlNamespaceResolver * @return * @throws XMLPlatformException */ public Node selectSingleNodeAdvanced(Node contextNode, String xPathString, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XPath xPath = getXPathFactory().newXPath(); if(null != xmlNamespaceResolver) { JAXPNamespaceContext namespaceContext = new JAXPNamespaceContext(xmlNamespaceResolver); xPath.setNamespaceContext(namespaceContext); } XPathExpression xPathExpression = xPath.compile(xPathString); return (Node) xPathExpression.evaluate(contextNode, XPathConstants.NODE); } catch(XPathException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }
/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode * @param xPath * @param xmlNamespaceResolver * @return * @throws XMLPlatformException */ public Node selectSingleNodeAdvanced(Node contextNode, String xPathString, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XPath xPath = getXPathFactory().newXPath(); if(null != xmlNamespaceResolver) { JAXPNamespaceContext namespaceContext = new JAXPNamespaceContext(xmlNamespaceResolver); xPath.setNamespaceContext(namespaceContext); } XPathExpression xPathExpression = xPath.compile(xPathString); return (Node) xPathExpression.evaluate(contextNode, XPathConstants.NODE); } catch(XPathException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }
/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode * @param xPathString * @param xmlNamespaceResolver * @return * @throws XMLPlatformException */ @Override public Node selectSingleNodeAdvanced(Node contextNode, String xPathString, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XPath xPath = getXPathFactory().newXPath(); if(null != xmlNamespaceResolver) { JAXPNamespaceContext namespaceContext = new JAXPNamespaceContext(xmlNamespaceResolver); xPath.setNamespaceContext(namespaceContext); } XPathExpression xPathExpression = xPath.compile(xPathString); return (Node) xPathExpression.evaluate(contextNode, XPathConstants.NODE); } catch(XPathException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }
/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode * @param xPath * @param xmlNamespaceResolver * @return * @throws XMLPlatformException */ @Override public Node selectSingleNodeAdvanced(Node contextNode, String xPath, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XMLNode xmlNode = (XMLNode)contextNode; XDKNamespaceResolver xdkNamespaceResolver = new XDKNamespaceResolver(xmlNamespaceResolver); return xmlNode.selectSingleNode(xPath, xdkNamespaceResolver); } catch (XSLException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }
/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode * @param xPath * @param xmlNamespaceResolver * @return * @throws XMLPlatformException */ public Node selectSingleNodeAdvanced(Node contextNode, String xPath, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XMLNode xmlNode = (XMLNode)contextNode; XDKNamespaceResolver xdkNamespaceResolver = new XDKNamespaceResolver(xmlNamespaceResolver); return xmlNode.selectSingleNode(xPath, xdkNamespaceResolver); } catch (XSLException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }
/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode the node relative to which the XPath * statement will be executed. * xPath the XPath statement * namespaceResolver used to resolve namespace prefixes * to the corresponding namespace URI * @return the XPath result * @throws XMLPlatformException */ @Override public NodeList selectNodesAdvanced(Node contextNode, String xPath, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XMLNode xmlNode = (XMLNode)contextNode; XDKNamespaceResolver xdkNamespaceResolver = new XDKNamespaceResolver(xmlNamespaceResolver); return xmlNode.selectNodes(xPath, xdkNamespaceResolver); } catch (XSLException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }
/** * Execute advanced XPath statements that are required for TopLink EIS. * @param contextNode the node relative to which the XPath * statement will be executed. * xPath the XPath statement * namespaceResolver used to resolve namespace prefixes * to the corresponding namespace URI * @return the XPath result * @throws XMLPlatformException */ public NodeList selectNodesAdvanced(Node contextNode, String xPath, XMLNamespaceResolver xmlNamespaceResolver) throws XMLPlatformException { try { XMLNode xmlNode = (XMLNode)contextNode; XDKNamespaceResolver xdkNamespaceResolver = new XDKNamespaceResolver(xmlNamespaceResolver); return xmlNode.selectNodes(xPath, xdkNamespaceResolver); } catch (XSLException e) { throw XMLPlatformException.xmlPlatformInvalidXPath(e); } }