question: public static List < Attr > findAttributeByValue ( Document doc , String attributeValue ) { List < Attr > returnedElements = new ArrayList < Attr > ( ) ; String xpath = String . format ( "//attribute::*[string()='%s']" , attributeValue ) ; try { returnedElements = ( List < Attr > ) evaluateXPath ( doc , xpath ) ; LOG . trace ( String . format ( "### Element with Attribute '%s' ### \n%s" , attributeValue , nodelistToFastXPathList ( returnedElements ) ) ) ; } catch ( XPathExpressionException e ) { LOG . warn ( String . format ( "BAD XPATH: %s" , xpath ) ) ; } return returnedElements ; }
target:  Finds an Element by its ID name. Looks for wsu:Id.