E - the type of the objects contained in the list to readpublic class InputStreamListDataReader<E> extends java.lang.Object implements ListDataReader<E>
ListDataReader that reads objects by reading from a specific
InputDataSource and converts the read data with a specific
InputStreamIterableInputConverter.| Constructor and Description |
|---|
InputStreamListDataReader(InputDataSource dataSource,
InputStreamIterableInputConverter<E> converter)
Construct an instance that will use the specified data source to read data from and convert it to a list of
objects with the specified converter.
|
| Modifier and Type | Method and Description |
|---|---|
java.util.Iterator<E> |
iterator()
Returns an iterator that is able to iterate over the read objects from the list.
|
GluonObservableList<E> |
newGluonObservableList()
Provide an instance of a GluonObservableList.
|
public InputStreamListDataReader(InputDataSource dataSource, InputStreamIterableInputConverter<E> converter)
iterator method.dataSource - the data source where the data will be read fromconverter - the converter that is used for converting the data into a list of objectpublic GluonObservableList<E> newGluonObservableList()
ListDataReaderDataProvider.retrieveList(ListDataReader)
to get a GluonObservableList that can be populated. Most implementations will just return an instance of
GluonObservableList itself. Note that it is perfectly valid to return existing instances of
GluonObservableList.newGluonObservableList in interface ListDataReader<E>public java.util.Iterator<E> iterator() throws java.io.IOException
iterator method on the converter.iterator in interface ListDataReader<E>java.io.IOException - when something went wrong during the process of reading the objects