git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
JAL-4366 allow a 3di alignment to be loaded and shown as a split frame with existing...
[jalview.git]
/
src
/
jalview
/
analysis
/
GeneticCodes.java
diff --git
a/src/jalview/analysis/GeneticCodes.java
b/src/jalview/analysis/GeneticCodes.java
index
59b698d
..
c91cfa2
100644
(file)
--- a/
src/jalview/analysis/GeneticCodes.java
+++ b/
src/jalview/analysis/GeneticCodes.java
@@
-21,9
+21,6
@@
package jalview.analysis;
import java.util.Locale;
package jalview.analysis;
import java.util.Locale;
-
-import jalview.bin.Cache;
-
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
@@
-33,6
+30,8
@@
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.StringTokenizer;
import java.util.Map;
import java.util.StringTokenizer;
+import jalview.bin.Console;
+
/**
* A singleton that provides instances of genetic code translation tables
*
/**
* A singleton that provides instances of genetic code translation tables
*
@@
-141,7
+140,8
@@
public final class GeneticCodes
InputStream is = getClass().getResourceAsStream(fileName);
if (is == null)
{
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));
return;
}
BufferedReader dataIn = new BufferedReader(new InputStreamReader(is));
@@
-162,13
+162,12
@@
public final class GeneticCodes
}
} catch (IOException | NullPointerException e)
{
}
} catch (IOException | NullPointerException e)
{
- Cache.error(
- "Error reading genetic codes data file " + fileName + ": "
- + e.getMessage());
+ Console.error("Error reading genetic codes data file " + fileName
+ + ": " + e.getMessage());
}
if (codeTables.isEmpty())
{
}
if (codeTables.isEmpty())
{
- System.err.println(
+ jalview.bin.Console.errPrintln(
"No genetic code tables loaded, check format of file "
+ fileName);
}
"No genetic code tables loaded, check format of file "
+ fileName);
}
@@
-192,7
+191,8
@@
public final class GeneticCodes
InputStream is = getClass().getResourceAsStream(fileName);
if (is == null)
{
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));
return;
}
BufferedReader dataIn = new BufferedReader(new InputStreamReader(is));
@@
-205,21
+205,20
@@
public final class GeneticCodes
String[] tokens = line.split("\\t");
if (tokens.length == 2)
{
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
{
}
else
{
- System.err.println(
+ jalview.bin.Console.errPrintln(
"Unexpected data in " + fileName + ": " + line);
}
}
}
} catch (IOException e)
{
"Unexpected data in " + fileName + ": " + line);
}
}
}
} catch (IOException e)
{
- Cache.error(
- "Error reading nucleotide ambiguity codes data file: "
- + e.getMessage());
+ Console.error("Error reading nucleotide ambiguity codes data file: "
+ + e.getMessage());
}
}
}
}
@@
-294,7
+293,7
@@
public final class GeneticCodes
line.lastIndexOf(QUOTE));
if (aminos.length() != NUCS_COUNT_CUBED) // 4 * 4 * 4 combinations
{
line.lastIndexOf(QUOTE));
if (aminos.length() != NUCS_COUNT_CUBED) // 4 * 4 * 4 combinations
{
- Cache.error("wrong data length in code table: " + line);
+ Console.error("wrong data length in code table: " + line);
}
else
{
}
else
{