Package org.biojava.bio.seq.io
Class FastaAlignmentFormat
java.lang.Object
org.biojava.bio.seq.io.FastaAlignmentFormat
- All Implemented Interfaces:
AlignmentFormat
This class implements the AlignmentFormat interface to read FASTA alignments.
It is modeled after the MSFAlignmentFormat class.
- Author:
- Nimesh Singh
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionread
(BufferedReader br) Reads an alignment in FASTA format.void
write
(OutputStream os, Alignment align, int fileType) Writes out the alignment to an FASTA file.void
writeDna
(OutputStream os, Alignment align) void
writeProtein
(OutputStream os, Alignment align)
-
Field Details
-
DNA
- See Also:
-
PROTEIN
- See Also:
-
-
Constructor Details
-
FastaAlignmentFormat
public FastaAlignmentFormat()
-
-
Method Details
-
read
Reads an alignment in FASTA format.- Specified by:
read
in interfaceAlignmentFormat
- Parameters:
br
- the reader from which to read in the alignment
-
write
public void write(OutputStream os, Alignment align, int fileType) throws BioException, IllegalSymbolException Writes out the alignment to an FASTA file.- Throws:
BioException
IllegalSymbolException
-
writeDna
- Throws:
BioException
IllegalSymbolException
-
writeProtein
public void writeProtein(OutputStream os, Alignment align) throws BioException, IllegalSymbolException - Throws:
BioException
IllegalSymbolException
-