code: public NodeList getMatchingNodes(String select, Document document)
          throws ConfigurationException, XpathException {
          try {
              return getXPathResultNode(select, document).getChildNodes();
          } catch (TransformerException ex) {
              throw new XpathException("Failed to apply stylesheet", ex);
          }
      }
docs: Execute the specified xpath syntax <code>select</code> expression
  on the specified document and return the list of nodes (could have
  length zero) that match
  @param select
  @param document
  @return list of matching nodes