public static class OrcFileSystemFormatFactory.OrcRowDataInputFormat extends FileInputFormat<RowData>
FileInputFormat
to read RowData
records from orc files.FileInputFormat.FileBaseStatistics, FileInputFormat.InputSplitOpenThread
currentSplit, ENUMERATE_NESTED_FILES_FLAG, enumerateNestedFiles, filePath, INFLATER_INPUT_STREAM_FACTORIES, minSplitSize, numSplits, openTimeout, READ_WHOLE_SPLIT_FLAG, splitLength, splitStart, stream, unsplittable
Constructor and Description |
---|
OrcRowDataInputFormat(Path[] paths,
String[] fullFieldNames,
DataType[] fullFieldTypes,
int[] selectedFields,
String partDefaultName,
long limit,
Properties properties) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes the file input stream of the input format.
|
RowData |
nextRecord(RowData reuse)
Reads the next record from the input.
|
void |
open(FileInputSplit fileSplit)
Opens an input stream to the file defined in the input format.
|
boolean |
reachedEnd()
Method used to check if the end of the input is reached.
|
boolean |
supportsMultiPaths()
Override this method to supports multiple paths.
|
acceptFile, configure, createInputSplits, decorateInputStream, extractFileExtension, getFilePath, getFilePaths, getFileStats, getFileStats, getInflaterInputStreamFactory, getInputSplitAssigner, getMinSplitSize, getNestedFileEnumeration, getNumSplits, getOpenTimeout, getSplitLength, getSplitStart, getStatistics, registerInflaterInputStreamFactory, setFilePath, setFilePath, setFilePaths, setFilePaths, setFilesFilter, setMinSplitSize, setNestedFileEnumeration, setNumSplits, setOpenTimeout, testForUnsplittable, toString
closeInputFormat, getRuntimeContext, openInputFormat, setRuntimeContext
public OrcRowDataInputFormat(Path[] paths, String[] fullFieldNames, DataType[] fullFieldTypes, int[] selectedFields, String partDefaultName, long limit, Properties properties)
public void open(FileInputSplit fileSplit) throws IOException
FileInputFormat
The stream is actually opened in an asynchronous thread to make sure any interruptions to the thread working on the input format do not reach the file system.
open
in interface InputFormat<RowData,FileInputSplit>
open
in class FileInputFormat<RowData>
fileSplit
- The split to be opened.IOException
- Thrown, if the spit could not be opened due to an I/O problem.public boolean supportsMultiPaths()
FileInputFormat
supportsMultiPaths
in class FileInputFormat<RowData>
public boolean reachedEnd() throws IOException
InputFormat
When this method is called, the input format it guaranteed to be opened.
IOException
- Thrown, if an I/O error occurred.public RowData nextRecord(RowData reuse)
InputFormat
When this method is called, the input format it guaranteed to be opened.
reuse
- Object that may be reused.public void close() throws IOException
FileInputFormat
close
in interface InputFormat<RowData,FileInputSplit>
close
in class FileInputFormat<RowData>
IOException
- Thrown, if the input could not be closed properly.Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.