Class PHYLIPFileFormat


  • public class PHYLIPFileFormat
    extends java.lang.Object
    Reads PHYLIP interleaved alignment files and fires events at a PHYLIPFileListener object.
    Since:
    1.6
    Author:
    Richard Holland, Tobias Thierer, Jim Balhoff
    • Method Detail

      • writeFile

        public static void writeFile​(java.io.File file,
                                     Alignment alignment)
                              throws java.io.IOException
        Writes the given Alignment in PHYLIP format to a file.
        Parameters:
        file - the file to write to.
        alignment - the Alignment object to write.
        Throws:
        java.io.IOException - if there is a problem during writing.
      • writeStream

        public static void writeStream​(java.io.OutputStream os,
                                       Alignment alignment)
                                throws java.io.IOException
        Writes the given Alignment in PHYLIP format to a stream.
        Parameters:
        os - the stream to write to.
        alignment - the Alignment object to write.
        Throws:
        java.io.IOException - if there is a problem during writing.
      • writeWriter

        public static void writeWriter​(java.io.Writer writer,
                                       Alignment alignment)
                                throws java.io.IOException
        Writes the given Alignment in PHYLIP format to a writer.
        Parameters:
        writer - the writer to write to.
        alignment - the Alignment object to write.
        Throws:
        java.io.IOException - if there is a problem during writing.