ParsingContext implementation that does nothing.
| Modifier and Type | Field and Description |
|---|---|
| pack-priv static final NoopParsingContext | |
| private RecordMetaData |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | columnsReordered()
Implements com. CommonSettings#selectFields and friends) are being reordered.
|
| public Map | comments()
Implements com. |
| public long | currentChar()
Implements com. |
| public int | currentColumn()
Implements com. |
| public long | currentLine()
Implements com. |
| public String | currentParsedContent()
Implements com. |
| public int | currentParsedContentLength()
Implements com. |
| public long | currentRecord()
Implements com. |
| public int | errorContentLength()
Implements com. If |
| public int[] | extractedFieldIndexes()
Implements com. CommonSettings#selectFields and friends).
|
| public String | fieldContentOnError()
Implements com. TextParsingException occurred.
|
| public String[] | headers()
Implements com. |
| public int | indexOf(String
the header whose position will be returned header)Implements com. |
| public int | indexOf(Enum<?>
the header whose position will be returned header)Implements com. |
| public boolean | isStopped()
Implements com. |
| public String | lastComment()
Implements com. |
| public char[] | lineSeparator()
Implements com. |
| public String[] | parsedHeaders()
Implements com. CommonParserSettings#headerExtractionEnabled is true.
|
| public RecordMetaData | recordMetaData()
Implements com. |
| public String[] | selectedHeaders()
Implements com. |
| public void | skipLines(long
the number of lines to be skipped. lines)Implements com. |
| public void | |
| public Record | toRecord(String[]
the row to be converted into a row)com.Implements com. com.
|
| instance | back to summary |
|---|---|
| pack-priv static final NoopParsingContext instance | |
| recordMetaData | back to summary |
|---|---|
| private RecordMetaData recordMetaData | |
| NoopParsingContext | back to summary |
|---|---|
| private NoopParsingContext() | |
| columnsReordered | back to summary |
|---|---|
| public boolean columnsReordered() Implements com. Doc from com. Indicates whether selected fields (using If columns are reordered, each parsed record will contain values only for the selected fields, as specified by
| |
| comments | back to summary |
|---|---|
| public Map Implements com. Doc from com. Returns all comments collected by the parser so far.
An empty map will be returned if | |
| currentChar | back to summary |
|---|---|
| public long currentChar() Implements com. Doc from com. Returns the index of the last char read from the input so far.
| |
| currentColumn | back to summary |
|---|---|
| public int currentColumn() Implements com. Doc from com. Returns the column index of the record being processed.
| |
| currentLine | back to summary |
|---|---|
| public long currentLine() Implements com. Doc from com. Returns the current line of text being processed by the parser
| |
| currentParsedContent | back to summary |
|---|---|
| public String currentParsedContent() Implements com. Doc from com. Returns a String with the input character sequence parsed to produce the current record. | |
| currentParsedContentLength | back to summary |
|---|---|
| public int currentParsedContentLength() Implements com. Doc from com. Returns the length of the character sequence parsed to produce the current record.
| |
| currentRecord | back to summary |
|---|---|
| public long currentRecord() Implements com. Doc from com. Returns the index of the last valid record parsed from the input
| |
| errorContentLength | back to summary |
|---|---|
| public int errorContentLength() Implements com. Doc from com. Returns the length limit of parsed contents appearing in exception messages when an error occurs If defaults to
| |
| extractedFieldIndexes | back to summary |
|---|---|
| public int[] extractedFieldIndexes() Implements com. Doc from com. Returns the indexes of each field extracted from the input when fields are selected in the parser settings (i.e. using The indexes are relative to their original position in the input. For example, if the input has the fields "A, B, C, D", and the selected fields are "A, D", then the extracted field indexes will return [0, 3] If no fields were selected, then this method will return null. This means all fields are being parsed.
| |
| fieldContentOnError | back to summary |
|---|---|
| public String fieldContentOnError() Implements com. Doc from com. Returns a String with the input character sequence accumulated on a field before | |
| headers | back to summary |
|---|---|
| public String[] headers() Implements com. Doc from com. Returns the file headers that identify each parsed record. If the headers are extracted from the input (i.e. If no headers are extracted from the input, then the configured headers in | |
| indexOf | back to summary |
|---|---|
| public int indexOf(String header) Implements com. Doc from com. Returns the position of a header (0 based). | |
| indexOf | back to summary |
|---|---|
| public int indexOf(Enum<?> header) Implements com. Doc from com. Returns the position of a header (0 based). | |
| isStopped | back to summary |
|---|---|
| public boolean isStopped() Implements com. Doc from com. Identifies whether the parser is running.
| |
| lastComment | back to summary |
|---|---|
| public String lastComment() Implements com. Doc from com. Returns the last comment found in the input.
| |
| lineSeparator | back to summary |
|---|---|
| public char[] lineSeparator() Implements com. Doc from com. Returns the line separator characters used to separate individual records when parsing. This could be the line
separator defined in the
| |
| parsedHeaders | back to summary |
|---|---|
| public String[] parsedHeaders() Implements com. Doc from com. Returns the headers parsed from the input, if and only if
| |
| recordMetaData | back to summary |
|---|---|
| public RecordMetaData recordMetaData() Implements com. Doc from com. Returns the metadata information associated with records produced by the current parsing process.
| |
| selectedHeaders | back to summary |
|---|---|
| public String[] selectedHeaders() Implements com. Doc from com. Returns the sequence of headers that have been selected. If no selection has been made, all available headers
will be returned, producing the same output as a call to method | |
| skipLines | back to summary |
|---|---|
| public void skipLines(long lines) Implements com. Doc from com. Skips a given number of lines from the current position.
| |
| stop | back to summary |
|---|---|
| public void stop() Implements com. Doc from com. Stops the parsing process. Any open resources in use by the parser are closed
automatically unless
| |
| toRecord | back to summary |
|---|---|
| public Record toRecord(String[] row) Implements com. Doc from com. Converts the given parsed row to a
| |