protected static URL buildURL ( URL sonarURL , Query query ) throws MalformedURLException , IllegalArgumentException { if ( query . getSonarKey ( ) == null || query . getSonarKey ( ) . length ( ) == 0 ) { throw new IllegalArgumentException ( "No resource specified in the Query" ) ; } String sonarPathWithResource = String . format ( SONAR_FORMAT_PATH , query . getSonarKey ( ) ) ; return new URL ( sonarURL , sonarPathWithResource ) ; }
Creates a url for the specified quality gate query