X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fanalysis%2FGeneticCodes.java;h=c91cfa2ed0149f84c64d09454b30340fb563f5ef;hb=a3f65dbb5ba8bd470a31ba2af72db6d8ddf60546;hp=a2ecdca85b84a0ec0ec03b46fc54fd953aab2779;hpb=cb8e52fbbc5f725e3f7f48c672cdddb0690bd978;p=jalview.git diff --git a/src/jalview/analysis/GeneticCodes.java b/src/jalview/analysis/GeneticCodes.java index a2ecdca..c91cfa2 100644 --- a/src/jalview/analysis/GeneticCodes.java +++ b/src/jalview/analysis/GeneticCodes.java @@ -140,7 +140,8 @@ public final class GeneticCodes InputStream is = getClass().getResourceAsStream(fileName); if (is == null) { - System.err.println("Resource file not found: " + fileName); + jalview.bin.Console + .errPrintln("Resource file not found: " + fileName); return; } BufferedReader dataIn = new BufferedReader(new InputStreamReader(is)); @@ -161,13 +162,12 @@ public final class GeneticCodes } } catch (IOException | NullPointerException e) { - Console.error( - "Error reading genetic codes data file " + fileName + ": " - + e.getMessage()); + Console.error("Error reading genetic codes data file " + fileName + + ": " + e.getMessage()); } if (codeTables.isEmpty()) { - System.err.println( + jalview.bin.Console.errPrintln( "No genetic code tables loaded, check format of file " + fileName); } @@ -191,7 +191,8 @@ public final class GeneticCodes InputStream is = getClass().getResourceAsStream(fileName); if (is == null) { - System.err.println("Resource file not found: " + fileName); + jalview.bin.Console + .errPrintln("Resource file not found: " + fileName); return; } BufferedReader dataIn = new BufferedReader(new InputStreamReader(is)); @@ -204,21 +205,20 @@ public final class GeneticCodes String[] tokens = line.split("\\t"); if (tokens.length == 2) { - ambiguityCodes.put(tokens[0].toUpperCase(Locale.ROOT), - tokens[1].toUpperCase(Locale.ROOT)); + ambiguityCodes.put(tokens[0].toUpperCase(Locale.ROOT), + tokens[1].toUpperCase(Locale.ROOT)); } else { - System.err.println( + jalview.bin.Console.errPrintln( "Unexpected data in " + fileName + ": " + line); } } } } catch (IOException e) { - Console.error( - "Error reading nucleotide ambiguity codes data file: " - + e.getMessage()); + Console.error("Error reading nucleotide ambiguity codes data file: " + + e.getMessage()); } }