X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Fjalview%2Fio%2FFileFormat.java;h=3354b883153e80e81810d0c6bff9639d0a6e5389;hb=refs%2Fheads%2Fbug%2FJAL-2576;hp=5a95a9ed02eee4286239a522e415c4b8a5d61b8d;hpb=35ce4609cc8a776b1d85a1f2c2c70aaa106c1a3b;p=jalview.git diff --git a/src/jalview/io/FileFormat.java b/src/jalview/io/FileFormat.java index 5a95a9e..3354b88 100644 --- a/src/jalview/io/FileFormat.java +++ b/src/jalview/io/FileFormat.java @@ -256,6 +256,21 @@ public enum FileFormat implements FileFormatI return new FeaturesFile(); } }, + ScoreMatrix("Substitution matrix", "", false, false) + { + @Override + public AlignmentFileReaderI getReader(FileParse source) + throws IOException + { + return new ScoreMatrixFile(source); + } + + @Override + public AlignmentFileWriterI getWriter(AlignmentI al) + { + return null; + } + }, PDB("PDB", "pdb,ent", true, false) { @Override @@ -332,6 +347,12 @@ public enum FileFormat implements FileFormatI { return false; } + + @Override + public boolean isIdentifiable() + { + return false; + } }; private boolean writable; @@ -405,4 +426,14 @@ public enum FileFormat implements FileFormatI { return false; } + + /** + * By default, answers true, indicating the format is one that can be + * identified by IdentifyFile. Formats that cannot be identified should + * override this method to return false. + */ + public boolean isIdentifiable() + { + return true; + } }