Package org.apache.xpath

Examples of org.apache.xpath.XPath.execute()


    // Execute the XPath, and have it return the result
    XPathContext xpathSupport = new XPathContext();
    int ctxtNode = xpathSupport.getDTMHandleFromNode(contextNode);

    return xpath.execute(xpathSupport, ctxtNode, prefixResolver);
  }
}
View Full Code Here


      // Execute the XPath, and have it return the result
      // return xpath.execute(xpathSupport, contextNode, prefixResolver);
      int ctxtNode = this._funcHereContext.getDTMHandleFromNode(contextNode);

      return xpath.execute(this._funcHereContext, ctxtNode, prefixResolver);
   }

   /**
    *   Evaluate XPath string to an XObject.
    *   XPath namespace prefixes are resolved from the namespaceNode.
View Full Code Here

                                                     this._dtmManager);
      }

      int ctxtNode = this._funcHereContext.getDTMHandleFromNode(contextNode);

      return xpath.execute(this._funcHereContext, ctxtNode, prefixResolver);
   }

   /**
    * Method getStrFromNode
    *
 
View Full Code Here

      // Execute the XPath, and have it return the result
      // return xpath.execute(xpathSupport, contextNode, prefixResolver);
      int ctxtNode = xpathSupport.getDTMHandleFromNode(contextNode);

      return xpath.execute(xpathSupport, ctxtNode, prefixResolver);
   }

   /**
    *   Evaluate XPath string to an XObject.
    *   XPath namespace prefixes are resolved from the namespaceNode.
View Full Code Here

      // Execute the XPath, and have it return the result
      FuncHereContext xpathSupport = new FuncHereContext(xpathnode);
      int ctxtNode = xpathSupport.getDTMHandleFromNode(contextNode);

      return xpath.execute(xpathSupport, ctxtNode, prefixResolver);
   }

   /**
    * Method getStrFromNode
    *
 
View Full Code Here

        }
        Node node = (Node) context;
        try {
            XPath xpath = new XPath(xpathQuery, null, customPrefixResolver, XPath.SELECT, null);
            int ctxtNode = xpathContext.getDTMHandleFromNode(node);
            XObject xresult = xpath.execute(xpathContext, ctxtNode, customPrefixResolver);
            if (xresult instanceof XNodeSet) {
                NodeListModel result = new NodeListModel(node);
                result.xpathSupport = this;
                NodeIterator nodeIterator = xresult.nodeset();
                Node n;
View Full Code Here

           
            // Execute the XPath, and have it return the result
            int ctxtNode = xpathSupport.getDTMHandleFromNode(contextNode);
           
            // System.out.println("Context Node id ( after getDTMHandlerFromNode) => " + ctxtNode );
            XObject xobj = xpath.execute(xpathSupport, ctxtNode, prefixResolver);
            return xobj;
        } catch (TransformerException ex) {
            throw new JspTagException(
                Resources.getMessage("XPATH_ERROR_EVALUATING_EXPR", str, ex.toString()), ex);           
        } catch (IllegalArgumentException ex) {
View Full Code Here

            XPath xpath = new XPath(str, null, prefixResolver, XPath.SELECT, null);           
            xpath.fixupVariables( varQNames, varQNames.size());
            // Execute the XPath, and have it return the result
            int ctxtNode = xpathSupport.getDTMHandleFromNode(contextNode);           
            // System.out.println("Context Node id ( after getDTMHandlerFromNode) => " + ctxtNode );           
            return xpath.execute(xpathSupport, ctxtNode, prefixResolver);
        } catch (TransformerException ex) {
            throw new JspTagException(
            Resources.getMessage("XPATH_ERROR_EVALUATING_EXPR", str, ex.toString()), ex);
        } catch (IllegalArgumentException ex) {
            throw new JspTagException(
View Full Code Here

      XObject var;
      XPath param = xslParamElement.getSelect();

      if (null != param)
      {
        var = param.execute(getXPathContext(), sourceNode, xslParamElement);
      }
      else if (null == xslParamElement.getFirstChild())
      {
        var = XString.EMPTYSTRING;
      }
View Full Code Here

          XpathTable.put(path,xpath);
        }

        // Execute the XPath, and have it return the result
        int ctxtNode = xpathSupport.getDTMHandleFromNode(data);
        return xpath.execute(xpathSupport, ctxtNode, prefixResolver);
    }

    public void setup(String value, String loadResource, String saveResource) {
        this.name = value;
        this.loadResource = loadResource;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.