org.dbunit.dataset.stream
Class StreamingIterator

java.lang.Object
  extended by org.dbunit.dataset.stream.StreamingIterator
All Implemented Interfaces:
ITableIterator

public class StreamingIterator
extends Object
implements ITableIterator

Asynchronous table iterator that uses a new Thread for asynchronous processing.

Since:
Apr 17, 2003
Version:
$Revision: 780 $ $Date: 2008-08-10 23:00:11 +0200 (Sun, 10 Aug 2008) $
Author:
Manuel Laflamme, Last changed by: $Author: gommma $

Constructor Summary
StreamingIterator(IDataSetProducer source)
          Iterator that creates a table iterator by reading the input from the given source in an asynchronous way.
 
Method Summary
 ITable getTable()
          Returns the current table.
 ITableMetaData getTableMetaData()
          Returns the metadata of the current table.
 boolean next()
          Position this iterator to the next table.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StreamingIterator

public StreamingIterator(IDataSetProducer source)
                  throws DataSetException
Iterator that creates a table iterator by reading the input from the given source in an asynchronous way. Therefore a Thread is created.

Parameters:
source - The source of the data
Throws:
DataSetException
Method Detail

next

public boolean next()
             throws DataSetException
Description copied from interface: ITableIterator
Position this iterator to the next table. The iterator is initially positioned before the first table; the first call to the method next makes the first table the current table; the second call makes the second table the current table, and so on.

Specified by:
next in interface ITableIterator
Returns:
true if the new current table is valid; false if there are no more table
Throws:
DataSetException

getTableMetaData

public ITableMetaData getTableMetaData()
                                throws DataSetException
Description copied from interface: ITableIterator
Returns the metadata of the current table.

Specified by:
getTableMetaData in interface ITableIterator
Throws:
DataSetException

getTable

public ITable getTable()
                throws DataSetException
Description copied from interface: ITableIterator
Returns the current table.

Specified by:
getTable in interface ITableIterator
Throws:
DataSetException


Copyright © 2002-2012. All Rights Reserved.