]> source.dussan.org Git - sonarqube.git/commitdiff
Fix warnings
authorDavid Gageot <david@gageot.net>
Mon, 16 Jul 2012 06:58:39 +0000 (08:58 +0200)
committerDavid Gageot <david@gageot.net>
Mon, 16 Jul 2012 06:58:39 +0000 (08:58 +0200)
sonar-plugin-api/src/main/java/org/sonar/api/utils/HttpDownloader.java
sonar-plugin-api/src/main/java/org/sonar/api/utils/UriReader.java

index 2d5ec5dbbbc41cc5e8f7f4355017e27571522227..7abc27a262b1985acbbfeb4573e457034742d22e 100644 (file)
@@ -92,6 +92,7 @@ public class HttpDownloader extends UriReader.SchemeProcessor implements BatchCo
     return Joiner.on(", ").join(descriptions);
   }
 
+  @Override
   String description(URI uri) {
     return String.format("%s (%s)", uri.toString(), getProxySynthesis(uri));
   }
@@ -170,18 +171,22 @@ public class HttpDownloader extends UriReader.SchemeProcessor implements BatchCo
     }
   }
 
+  @Override
   String[] getSupportedSchemes() {
     return new String[]{"http", "https"};
   }
 
+  @Override
   byte[] readBytes(URI uri) {
     return download(uri);
   }
 
+  @Override
   String readString(URI uri, Charset charset) {
     return downloadPlainText(uri, charset.name());
   }
 
+  @Override
   InputStream openStream(URI uri) {
     try {
       HttpURLConnection connection = newHttpConnection(uri);
index 4a7978ed8ebb1a3d01b902972b21e76845618797..96f3e14406f532dcaeed1f0ac367b562a6ef72b5 100644 (file)
@@ -112,10 +112,12 @@ public class UriReader implements BatchComponent, ServerComponent {
    */
   private static class FileProcessor extends SchemeProcessor {
 
+    @Override
     public String[] getSupportedSchemes() {
       return new String[]{"file"};
     }
 
+    @Override
     byte[] readBytes(URI uri) {
       try {
         return Files.toByteArray(new File(uri));
@@ -124,6 +126,7 @@ public class UriReader implements BatchComponent, ServerComponent {
       }
     }
 
+    @Override
     String readString(URI uri, Charset charset) {
       try {
         return Files.toString(new File(uri), charset);
@@ -132,6 +135,7 @@ public class UriReader implements BatchComponent, ServerComponent {
       }
     }
 
+    @Override
     InputStream openStream(URI uri) {
       try {
         return Files.newInputStreamSupplier(new File(uri)).getInput();
@@ -140,6 +144,7 @@ public class UriReader implements BatchComponent, ServerComponent {
       }
     }
 
+    @Override
     String description(URI uri) {
       return new File(uri).getAbsolutePath();
     }