com.univocity.api.io
Class InputReaderQueue

java.lang.Object
  extended by com.univocity.api.io.ReaderProvider
      extended by com.univocity.api.io.InputQueue<ReaderProvider>
          extended by com.univocity.api.io.InputReaderQueue
All Implemented Interfaces:
ResourceProvider<Reader>

public class InputReaderQueue
extends InputQueue<ReaderProvider>

A queue of a sequence of ReaderProvider and plain Reader inputs to be processed. Variables can be used to assign values to each input and provide more control and information about what the input represents (e.g. date the input was produced, some user ID associated with the input, etc)

Author:
uniVocity Software Pty Ltd - dev@univocity.com
See Also:
InputQueue, ReaderProvider

Constructor Summary
InputReaderQueue()
           
 
Method Summary
 void add(Reader reader)
          Adds a Reader to the input queue.
 void add(ReaderProvider readerProvider)
          Adds a ReaderProvider to the input queue
protected  Reader open(ReaderProvider input)
          Opens an input and returns an instanceof Reader which will be used to consume it.
 
Methods inherited from class com.univocity.api.io.InputQueue
assignVariablesToLastEntry, assignVariableToLastEntry, getCurrentVariables, getResource, isEmpty, offer, peek, readVariable, readVariable, readVariable, size
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InputReaderQueue

public InputReaderQueue()
Method Detail

add

public void add(ReaderProvider readerProvider)
Adds a ReaderProvider to the input queue

Parameters:
readerProvider - the ReaderProvider to be added to this queue

add

public void add(Reader reader)
Adds a Reader to the input queue.

Parameters:
reader - the Reader to be added to this queue.

open

protected Reader open(ReaderProvider input)
Description copied from class: InputQueue
Opens an input and returns an instanceof Reader which will be used to consume it. Used when InputQueue.getResource() is called.

Specified by:
open in class InputQueue<ReaderProvider>
Parameters:
input - the input to be read
Returns:
Reader that can be used to consume the given input.


Copyright © 2018 uniVocity Software Pty Ltd. All rights reserved.