question: public Element selectElementMatchingXPath ( String xpath , Element toSearch ) { List < Element > results = selectElementsMatchingXPath ( xpath , toSearch ) ; if ( results . isEmpty ( ) ) { throw new ElementNotFoundException ( xpath , toSearch ) ; } Element match = results . get ( 0 ) ; return match ; }
target:  The following will search the given element for the specified XPath and return any node that matches.