JAL-3365 expand range of allowed DSSP secondary structure symbols in Stockholm files
[jalview.git] / src / jalview / io / FastaFile.java
index 9c8cdf6..c698a31 100755 (executable)
  */
 package jalview.io;
 
+import java.io.IOException;
+
 import jalview.datamodel.Alignment;
 import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.Annotation;
 import jalview.datamodel.Sequence;
 import jalview.datamodel.SequenceI;
 
-import java.io.IOException;
-
 /**
  * DOCUMENT ME!
  * 
@@ -69,7 +69,12 @@ public class FastaFile extends AlignFile
 
   public FastaFile(FileParse source) throws IOException
   {
-    super(source);
+    this(source, true);
+  }
+
+  public FastaFile(FileParse source, boolean closeData) throws IOException
+  {
+    super(true, source, closeData);
   }
 
   public FastaFile(SequenceI[] seqs)
@@ -164,8 +169,8 @@ public class FastaFile extends AlignFile
         anots[i] = new Annotation("" + cn, null, ' ', Float.NaN);
       }
     }
-    AlignmentAnnotation aa = new AlignmentAnnotation(seq.getName()
-            .substring(2), seq.getDescription(), anots);
+    AlignmentAnnotation aa = new AlignmentAnnotation(
+            seq.getName().substring(2), seq.getDescription(), anots);
     return aa;
   }
 
@@ -180,8 +185,7 @@ public class FastaFile extends AlignFile
     addProperties(al);
     for (int i = 0; i < annotations.size(); i++)
     {
-      AlignmentAnnotation aa = annotations
-              .elementAt(i);
+      AlignmentAnnotation aa = annotations.elementAt(i);
       aa.setPadGaps(true, al.getGapCharacter());
       al.addAnnotation(aa);
     }