liquibase.util.csv.opencsv
Class CSVIterator

java.lang.Object
  extended by liquibase.util.csv.opencsv.CSVIterator
All Implemented Interfaces:
Iterator<String[]>

public class CSVIterator
extends Object
implements Iterator<String[]>

Provides an Iterator over the data found in opencsv.


Constructor Summary
CSVIterator(CSVReader reader)
           
 
Method Summary
 boolean hasNext()
          Returns true if the iteration has more elements.
 String[] next()
          Returns the next elenebt in the iterator.
 void remove()
          This method is not supported by openCSV and will throw a UnsupportedOperationException if called.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CSVIterator

public CSVIterator(CSVReader reader)
            throws IOException
Parameters:
reader - reader for the csv data.
Throws:
IOException - if unable to read data from the reader.
Method Detail

hasNext

public boolean hasNext()
Returns true if the iteration has more elements. In other words, returns true if next() would return an element rather than throwing an exception.

Specified by:
hasNext in interface Iterator<String[]>
Returns:
true if the CSVIterator has more elements.

next

public String[] next()
Returns the next elenebt in the iterator.

Specified by:
next in interface Iterator<String[]>
Returns:
The next element of the iterator.

remove

public void remove()
This method is not supported by openCSV and will throw a UnsupportedOperationException if called.

Specified by:
remove in interface Iterator<String[]>


Copyright © 2016 Liquibase.org. All rights reserved.