From: amwaterhouse Date: Mon, 21 Mar 2005 18:48:58 +0000 (+0000) Subject: identifies more varied blc files X-Git-Tag: Release_2_0~530 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=198a43209e4ed9b8b51b7818ca323748bf4c24b3;p=jalview.git identifies more varied blc files --- diff --git a/src/jalview/io/IdentifyFile.java b/src/jalview/io/IdentifyFile.java index 2baf323..c457b58 100755 --- a/src/jalview/io/IdentifyFile.java +++ b/src/jalview/io/IdentifyFile.java @@ -15,7 +15,7 @@ public class IdentifyFile { public static String Identify(String file, String protocol) { - String reply = "error"; + String reply = "PFAM"; try{ BufferedReader reader = null; @@ -56,23 +56,17 @@ public class IdentifyFile reply = "PIR"; break; } - else if(data.indexOf(">")==0) + else if(data.indexOf(">")>-1) { // could be BLC file data = reader.readLine(); - if(data.indexOf(">")==0) + if(data.indexOf(">")>-1) reply = "BLC"; else reply = "FASTA"; break; } - else - { - reply = "PFAM"; - break; - } - } reader.close(); }