JAL-3878 Change Cache.log calls to Console
[jalview.git] / src / jalview / ws2 / client / slivka / SlivkaWSClient.java
index d7841af..47e43c1 100644 (file)
@@ -15,6 +15,7 @@ import java.util.regex.Pattern;
 
 import jalview.api.FeatureColourI;
 import jalview.bin.Cache;
+import jalview.bin.Console;
 import jalview.datamodel.Alignment;
 import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.AlignmentI;
@@ -94,7 +95,7 @@ public class SlivkaWSClient implements WebServiceClientI
         }
         if (format == null)
         {
-          Cache.log.warn(String.format(
+          Console.warn(String.format(
               "Unknown input format %s, assuming fasta.",
               fileParam.getMediaType()));
           format = FileFormat.Fasta;
@@ -200,7 +201,7 @@ public class SlivkaWSClient implements WebServiceClientI
   public void cancel(WebServiceJobHandle job)
       throws IOException, UnsupportedOperationException
   {
-    Cache.log.warn(
+    Console.warn(
         "slivka client does not support job cancellation");
   }
 }
@@ -235,7 +236,7 @@ class SlivkaAlignmentWSClient extends SlivkaWSClient
       return new FormatAdapter().readFile(f.getContentUrl().toString(),
           DataSourceType.URL, format);
     }
-    Cache.log.warn("No alignment found on the server");
+    Console.warn("No alignment found on the server");
     throw new IOException("no alignment found");
   }
 
@@ -270,7 +271,7 @@ class SlivkaAnnotationWSClient extends SlivkaWSClient
             aln, service.getId(), f.getContentUrl().toString(),
             DataSourceType.URL);
         if (annotPresent)
-          Cache.log.debug(format("loaded annotations for %s", service.getId()));
+          Console.debug(format("loaded annotations for %s", service.getId()));
       }
       else if (fmt.equalsIgnoreCase("jalview-features"))
       {
@@ -278,13 +279,13 @@ class SlivkaAnnotationWSClient extends SlivkaWSClient
             DataSourceType.URL);
         featPresent = ff.parse(aln, colours, true);
         if (featPresent)
-          Cache.log.debug(format("loaded features for %s", service.getId()));
+          Console.debug(format("loaded features for %s", service.getId()));
       }
     }
     if (!annotPresent)
-      Cache.log.debug(format("no annotations found for %s", service.getId()));
+      Console.debug(format("no annotations found for %s", service.getId()));
     if (!featPresent)
-      Cache.log.debug(format("no features found for %s", service.getId()));
+      Console.debug(format("no features found for %s", service.getId()));
     return aln.getAlignmentAnnotation() != null ? Arrays.asList(aln.getAlignmentAnnotation())
         : Collections.emptyList();
   }