public interface SplitParsingContext
Modifier and Type | Method and Description |
---|---|
void |
bulkPublish(RecordTokenSequence records)
Provides a set of records to publish.
|
void |
discardRecord()
Signals that the current record should be ignored.
|
DataSplit |
getSplit()
Gets the split being parsed.
|
void |
handleExtraField(String message)
Reports an extra field being found in a record.
|
void |
handleFieldError(String message)
Reports a field parsing error.
|
void |
handleMissingFields(String message)
Reports a record being found to having missing fields.
|
void |
handleParseException(long offsetInSplit,
Exception e)
Reports an exception occurring during parsing of the split.
|
void |
publishRecord()
Signals that the current record is ready to be published.
|
void |
startRecord(long offsetInSplit)
Establishes the context for the current record.
|
DataSplit getSplit()
void startRecord(long offsetInSplit)
offsetInSplit
- the offset within the split
at which the record begins. This offset should
be either in bytes or characters as appropriate
for the format.void publishRecord()
DataParser#bindOutput(RecordSettable)
.void discardRecord()
DataParser#bindOutput(RecordSettable)
should
be discarded.void bulkPublish(RecordTokenSequence records)
This method is intended only for column oriented block formats
which assemble multiple records at once. For row oriented formats,
publishRecord()
should be used instead.
records
- void handleFieldError(String message)
message
- additional information about the error.
The message is interpreted within the context of the
current split, so this data need not be included.void handleMissingFields(String message)
message
- additional information about the error.
The message is interpreted within the context of the
current split, so this data need not be included.void handleExtraField(String message)
message
- additional information about the error.
The message is interpreted within the context of the
current split, so this data need not be included.void handleParseException(long offsetInSplit, Exception e)
DataParser#parseSplit(SplitParsingContext)
.offsetInSplit
- the current offset, in bytes or characters, within the
split when the error occurred. The appropriate units for the format
should be used.e
- the exception that occurredCopyright © 2024 Actian Corporation. All rights reserved.