public class ORCFormatterShimImpl extends AbstractRecordFormatter implements ORCFormatterShim
Constructor and Description |
---|
ORCFormatterShimImpl() |
ORCFormatterShimImpl(ORCOptions orcOptions) |
Modifier and Type | Method and Description |
---|---|
protected void |
bindInputFields(RecordValued source)
Provides the buffer holding input data to be formatted.
|
void |
close()
Called to signal that writing is complete.
|
protected void |
formatRecord()
Called to write a formatted record.
|
protected void |
initialize(ByteSink sink,
WriteMode mode)
Prepares the formatter for writing to the provided sink.
|
bindInput, writeData
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
bindInput, writeData
public ORCFormatterShimImpl(ORCOptions orcOptions)
public ORCFormatterShimImpl()
protected void bindInputFields(RecordValued source)
AbstractRecordFormatter
bindInputFields
in class AbstractRecordFormatter
source
- a record valued container which will hold
the current value to be formattedprotected void initialize(ByteSink sink, WriteMode mode) throws IOException
AbstractRecordFormatter
#bindInput(RecordInput)
has been called, but before AbstractRecordFormatter.formatRecord()
is called.
This method is always called, even if the input has no data.
initialize
in class AbstractRecordFormatter
sink
- the target to which data is writtenmode
- how an existing sink should be handledIOException
- if an I/O error occursprotected void formatRecord() throws IOException
AbstractRecordFormatter
AbstractRecordFormatter.bindInputFields(RecordValued)
and write it to the sink passed to AbstractRecordFormatter.initialize(ByteSink, WriteMode)
.
This method is called repeatedly while the record source still has data.
formatRecord
in class AbstractRecordFormatter
IOException
- if an I/O error occurs while writing the recordpublic void close()
AbstractRecordFormatter
AbstractRecordFormatter.bindInputFields(RecordValued)
has returned
successfully, it is guaranteed that this method
will be called, even if errors occur.
This method is called once,
after the last call to AbstractRecordFormatter.formatRecord()
Any allocated resources which need to be released should be
handled within the implementation of this method.
close
in interface DataFormat.DataFormatter
close
in class AbstractRecordFormatter
Copyright © 2016 Actian Corporation. All Rights Reserved.