public class ReaderManager
extends java.lang.Object
CSVReader instances. The ImpExReader uses this class for managing its reader
instances. The reader on top of the stack represents the current reader instance and the one at bottom the reader of
the main script.| Constructor and Description |
|---|
ReaderManager(CSVReader mainReader)
Creates a new manager initialized with given reader, which represents the main reader and will be pushed to the
bottom of the reader stack.
|
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Clears the stack by calling
popReader() for each reader at stack (includes closing of reader). |
int |
getCurrentColumnOffset()
Gets the column offset configured for current reader instance.
|
java.lang.String |
getCurrentLocation()
Gets the location of the current reading process by concatenating all locations of the reader at stack.
|
CSVReader |
getMainReader()
Gets the main reader (reader given at constructor).
|
CSVReader |
peekReader()
Gets the current reader instance.
|
CSVReader |
popReader()
Closes, removes and returns current reader.
|
void |
pushReader(CSVReader reader,
int columnOffset,
java.lang.String locationText)
Pushes a reader at the reader stack, so it will be the current one.
|
int |
readerCount()
Gets the count of reader managed by this instance.
|
public ReaderManager(CSVReader mainReader)
mainReader - main readerpublic void pushReader(CSVReader reader, int columnOffset, java.lang.String locationText)
reader - new reader instancecolumnOffset - column offset used when reading with given readerlocationText - location text used for logging of readerpublic CSVReader popReader()
public java.lang.String getCurrentLocation()
public void clear()
popReader() for each reader at stack (includes closing of reader).public CSVReader peekReader()
public CSVReader getMainReader()
public int getCurrentColumnOffset()
throws JaloSystemException
JaloSystemException - if no reader is registeredpublic int readerCount()
Copyright © 2018 SAP SE. All Rights Reserved.