v2
[jalview.git] / src / jalview / io / BLCFile.java
index d0eb80e..6b59d02 100755 (executable)
@@ -1,6 +1,6 @@
 /*
- * Jalview - A Sequence Alignment Editor and Viewer (Version 2.6)
- * Copyright (C) 2010 J Procter, AM Waterhouse, G Barton, M Clamp, S Searle
+ * Jalview - A Sequence Alignment Editor and Viewer (Version 2.7)
+ * Copyright (C) 2011 J Procter, AM Waterhouse, J Engelhardt, LM Lui, G Barton, M Clamp, S Searle
  * 
  * This file is part of Jalview.
  * 
@@ -20,6 +20,14 @@ package jalview.io;
 import java.io.*;
 import java.util.*;
 
+import javax.xml.parsers.ParserConfigurationException;
+
+import org.xml.sax.SAXException;
+
+import fr.orsay.lri.varna.exceptions.ExceptionFileFormatOrSyntax;
+import fr.orsay.lri.varna.exceptions.ExceptionLoadingFailed;
+import fr.orsay.lri.varna.exceptions.ExceptionPermissionDenied;
+
 import jalview.datamodel.*;
 
 /**
@@ -49,13 +57,19 @@ public class BLCFile extends AlignFile
    * 
    * @throws IOException
    *           DOCUMENT ME!
+ * @throws SAXException 
+ * @throws ParserConfigurationException 
+ * @throws ExceptionFileFormatOrSyntax 
+ * @throws ExceptionLoadingFailed 
+ * @throws ExceptionPermissionDenied 
+ * @throws InterruptedException 
    */
-  public BLCFile(String inFile, String type) throws IOException
+  public BLCFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException
   {
     super(inFile, type);
   }
 
-  public BLCFile(FileParse source) throws IOException
+  public BLCFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException
   {
     super(source);
   }
@@ -142,7 +156,7 @@ public class BLCFile extends AlignFile
         {
           // header lines - keep them for the alignment comments.
           headerLines.append(line);
-          headerLines.append("\n");
+          headerLines.append(newline);
           numHeaderLines++;
         }
       } while (!idsFound);
@@ -240,7 +254,7 @@ public class BLCFile extends AlignFile
         out.append(" " + s[i].getDescription());
       }
 
-      out.append("\n");
+      out.append(newline);
 
       if (s[i].getSequence().length > max)
       {
@@ -250,7 +264,8 @@ public class BLCFile extends AlignFile
       i++;
     }
 
-    out.append("* iteration 1\n");
+    out.append("* iteration 1");
+    out.append(newline);
 
     for (int j = 0; j < max; j++)
     {
@@ -270,10 +285,11 @@ public class BLCFile extends AlignFile
         i++;
       }
 
-      out.append("\n");
+      out.append(newline);
     }
 
-    out.append("*\n");
+    out.append("*");
+    out.append(newline);
 
     return out.toString();
   }