Class TableFile

java.lang.Object
org.snpeff.fileIterator.TableFile
All Implemented Interfaces:
Serializable

public class TableFile extends Object implements Serializable
Load a table from a file. The table is loaded into an arbitrary object having arrays to hold the data.
Author:
pcingola
See Also:
  • Field Details

    • FIELD_NAME_SEPARATOR

      protected static final char FIELD_NAME_SEPARATOR
      See Also:
    • size

      protected int size
    • verbose

      protected boolean verbose
    • hasTitle

      protected boolean hasTitle
    • fileName

      protected String fileName
    • separator

      protected String separator
    • fieldStr

      protected String fieldStr
    • fieldNames

      protected String[] fieldNames
    • fieldByName

      protected HashMap<String,Field> fieldByName
  • Constructor Details

    • TableFile

      public TableFile(int size)
    • TableFile

      public TableFile(String fileName)
    • TableFile

      public TableFile(String fileName, String fieldStr)
  • Method Details

    • assign

      protected void assign(String line, int idx)
      Assign values parse from 'line' into array elements indexed by 'idx'
      Parameters:
      line -
      idx -
    • initFields

      protected void initFields()
      Map field names to Field objects
    • load

      public void load()
      Load all data into memory
    • save

      public void save(String binaryFile)
      Save this object to a binary file (using Java serialization)
      Parameters:
      binaryFile -
    • size

      public int size()
      Array size
      Returns:
    • toString

      public String toString(int index)
      Return line number 'index' as a string
      Parameters:
      index -
      Returns: