code: public NodeList getMatchingNodes(String select, Document document)
          throws XpathException {
          try {
              return new NodeListForIterable(engine
                                             .selectNodes(select,
                                                          new DOMSource(document))
                                             );
          } catch (XMLUnitException ex) {
              throw new XpathException(ex.getCause());
          }
      }
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