Class CSVSource

java.lang.Object
com.espertech.esperio.csv.CSVSource

public class CSVSource extends Object
A wrapper for a Reader or an InputStream.
  • Constructor Details

    • CSVSource

      public CSVSource(AdapterInputSource source)
      Ctor.
      Parameters:
      source - - the AdapterInputSource from which to obtain the uderlying resource
  • Method Details

    • close

      public void close() throws IOException
      Close the underlying resource.
      Throws:
      IOException - to indicate an io error
    • read

      public int read() throws IOException
      Read from the underlying resource.
      Returns:
      the result of the read
      Throws:
      IOException - for io errors
    • isResettable

      public boolean isResettable()
      Return true if the underlying resource is resettable.
      Returns:
      true if resettable, false otherwise
    • resetToMark

      public void resetToMark() throws IOException
      Reset to the last mark position.
      Throws:
      IOException - for io errors
    • mark

      public void mark(int readAheadLimit) throws IOException
      Set the mark position.
      Parameters:
      readAheadLimit - is the maximum number of read-ahead events
      Throws:
      IOException - when an io error occurs
    • reset

      public void reset()
      Reset to the beginning of the resource.