Package org.apache.xpath

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


           
            // 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

    // Create the XPath object.
    XPath xpath = new XPath(str, null, prefixResolver, XPath.SELECT, null);

    // Execute the XPath, and have it return the result
    return xpath.execute(xpathSupport, contextNode, prefixResolver);
  }

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

    //    XPathContext should be done away with.)
    // Create the XPath object.
    XPath xpath = new XPath(str, null, prefixResolver, XPath.SELECT, null);

    // Execute the XPath, and have it return the result
    return xpath.execute(new XPathContext(), contextNode, prefixResolver);
  }
}
View Full Code Here

                PrefixResolver prefixResolver =
                    new DataPrefixResolver(namespaces);
                XPath xpath = new XPath(path, null, prefixResolver,
                    XPath.SELECT);
                int ctxtNode = xpathSupport.getDTMHandleFromNode(dataNode);
                result = xpath.execute(xpathSupport, ctxtNode,
                    prefixResolver).nodelist();
            }
        } catch (TransformerException te) {
            Log log = LogFactory.getLog(Builtin.class);
            log.error(te.getMessage(), te);
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, Resource load, Resource save) {
        this.name = value;
        this.loadResource = load;
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

      // 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

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.