private List < String > findUrlsInAttributeValue ( final String attributeValue ) { List < String > foundUrls = new ArrayList <> ( ) ; urlPatterns . stream ( ) . map ( ( Pattern urlPattern ) -> urlPattern . matcher ( attributeValue ) ) . forEach ( ( Matcher urlPatternMatcher ) -> { while ( urlPatternMatcher . find ( ) ) { String foundUrl = urlPatternMatcher . group ( ) . trim ( ) ; if ( validator . test ( foundUrl ) ) { foundUrls . add ( foundUrl ) ; } } } ) ; return foundUrls ; }
Returns a list of validated URLs found in the attribute s value .