Class CsvIndex

java.lang.Object
de.siegmar.fastcsv.reader.CsvIndex
All Implemented Interfaces:
Serializable

public final class CsvIndex extends Object implements Serializable
Index built by IndexedCsvReader to access large CSV data files.
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      See Also:
    • bomHeaderLength

      private final int bomHeaderLength
      The length of an optional BOM header.
    • fileSize

      private final long fileSize
      The CSV file size this index was built for.
    • fieldSeparator

      private final byte fieldSeparator
      The field separator used when building this index.
    • quoteCharacter

      private final byte quoteCharacter
      The quote character used when building this index.
    • commentStrategy

      private final CommentStrategy commentStrategy
      The comment strategy used when building this index.
    • commentCharacter

      private final byte commentCharacter
      The comment character used when building this index.
    • recordCounter

      private final long recordCounter
      The total number of records the CSV file contains this index was built for.
    • pages

      private final List<CsvIndex.CsvPage> pages
      The pages this index is partitioned.
  • Constructor Details

    • CsvIndex

      CsvIndex(int bomHeaderLength, long fileSize, byte fieldSeparator, byte quoteCharacter, CommentStrategy commentStrategy, byte commentCharacter, long recordCounter, List<CsvIndex.CsvPage> pages)
  • Method Details

    • getBomHeaderLength

      int getBomHeaderLength()
    • getFileSize

      long getFileSize()
    • getFieldSeparator

      byte getFieldSeparator()
    • getQuoteCharacter

      byte getQuoteCharacter()
    • getCommentStrategy

      CommentStrategy getCommentStrategy()
    • getCommentCharacter

      byte getCommentCharacter()
    • getPageCount

      public int getPageCount()
      Gets the number of pages the file contents is partitioned to.
      Returns:
      the number of pages the file contents is partitioned to
    • getRecordCount

      public long getRecordCount()
      Gets the number of records the file contains.
      Returns:
      the number of records the file contains
    • getPage

      CsvIndex.CsvPage getPage(int pageNumber)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object