test_class.file: flink-core/src/test/java/org/apache/flink/api/common/io/FileInputFormatTest.java
test_class.identifier: FileInputFormatTest
test_case.body: @Test
  	public void testDecorateInputStream() throws IOException {
  		// create temporary file with 3 blocks
  		final File tempFile = File.createTempFile("input-stream-decoration-test", "tmp");
  		tempFile.deleteOnExit();
  		final int blockSize = 8;
  		final int numBlocks = 3;
  		FileOutputStream fileOutputStream = new FileOutputStream(tempFile);
  		for (int i = 0; i < blockSize * numBlocks; i++) {
  			fileOutputStream.write(new byte[]{1});
  		}
  		fileOutputStream.close();
  
  		final Configuration config = new Configuration();
  
  		final FileInputFormat<byte[]> inputFormat = new MyDecoratedInputFormat();
  		inputFormat.setFilePath(tempFile.toURI().toString());
  
  		inputFormat.configure(config);
  
  		FileInputSplit[] inputSplits = inputFormat.createInputSplits(3);
  
  		byte[] bytes = null;
  		for (FileInputSplit inputSplit : inputSplits) {
  			inputFormat.open(inputSplit);
  			while (!inputFormat.reachedEnd()) {
  				if ((bytes = inputFormat.nextRecord(bytes)) != null) {
  					Assert.assertArrayEquals(new byte[]{(byte) 0xFE}, bytes);
  				}
  			}
  		}
  	}
test_case.class_method_signature: FileInputFormatTest.testDecorateInputStream()
test_case.full_signature: @Test public void testDecorateInputStream()
test_case.identifier: testDecorateInputStream
test_case.invocations: createTempFile deleteOnExit write close setFilePath toString toURI configure createInputSplits open reachedEnd nextRecord assertArrayEquals
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testDecorateInputStream()
focal_class.declarator: LOG = LoggerFactory.getLogger(FileInputFormat.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOG = LoggerFactory.getLogger(FileInputFormat.class);
focal_class.type: Logger
focal_class.var_name: LOG
focal_class.declarator: serialVersionUID = 1L
focal_class.modifier: private static final
focal_class.original_string: private static final long serialVersionUID = 1L;
focal_class.type: long
focal_class.var_name: serialVersionUID
focal_class.declarator: MAX_SPLIT_SIZE_DISCREPANCY = 1.1f
focal_class.modifier: private static final
focal_class.original_string: private static final float MAX_SPLIT_SIZE_DISCREPANCY = 1.1f;
focal_class.type: float
focal_class.var_name: MAX_SPLIT_SIZE_DISCREPANCY
focal_class.declarator: DEFAULT_OPENING_TIMEOUT
focal_class.modifier: private static
focal_class.original_string: private static long DEFAULT_OPENING_TIMEOUT;
focal_class.type: long
focal_class.var_name: DEFAULT_OPENING_TIMEOUT
focal_class.declarator: INFLATER_INPUT_STREAM_FACTORIES =
  			new HashMap<String, InflaterInputStreamFactory<?>>()
focal_class.modifier: protected static final
focal_class.original_string: protected static final Map<String, InflaterInputStreamFactory<?>> INFLATER_INPUT_STREAM_FACTORIES =
  			new HashMap<String, InflaterInputStreamFactory<?>>();
focal_class.type: Map<String, InflaterInputStreamFactory<?>>
focal_class.var_name: INFLATER_INPUT_STREAM_FACTORIES
focal_class.declarator: READ_WHOLE_SPLIT_FLAG = -1L
focal_class.modifier: protected static final
focal_class.original_string: protected static final long READ_WHOLE_SPLIT_FLAG = -1L;
focal_class.type: long
focal_class.var_name: READ_WHOLE_SPLIT_FLAG
focal_class.declarator: stream
focal_class.modifier: protected transient
focal_class.original_string: protected transient FSDataInputStream stream;
focal_class.type: FSDataInputStream
focal_class.var_name: stream
focal_class.declarator: splitStart
focal_class.modifier: protected transient
focal_class.original_string: protected transient long splitStart;
focal_class.type: long
focal_class.var_name: splitStart
focal_class.declarator: splitLength
focal_class.modifier: protected transient
focal_class.original_string: protected transient long splitLength;
focal_class.type: long
focal_class.var_name: splitLength
focal_class.declarator: currentSplit
focal_class.modifier: protected transient
focal_class.original_string: protected transient FileInputSplit currentSplit;
focal_class.type: FileInputSplit
focal_class.var_name: currentSplit
focal_class.declarator: filePath
focal_class.modifier: protected
focal_class.original_string: protected Path filePath;
focal_class.type: Path
focal_class.var_name: filePath
focal_class.declarator: minSplitSize = 0
focal_class.modifier: protected
focal_class.original_string: protected long minSplitSize = 0;
focal_class.type: long
focal_class.var_name: minSplitSize
focal_class.declarator: numSplits = -1
focal_class.modifier: protected
focal_class.original_string: protected int numSplits = -1;
focal_class.type: int
focal_class.var_name: numSplits
focal_class.declarator: openTimeout = DEFAULT_OPENING_TIMEOUT
focal_class.modifier: protected
focal_class.original_string: protected long openTimeout = DEFAULT_OPENING_TIMEOUT;
focal_class.type: long
focal_class.var_name: openTimeout
focal_class.declarator: unsplittable = false
focal_class.modifier: protected
focal_class.original_string: protected boolean unsplittable = false;
focal_class.type: boolean
focal_class.var_name: unsplittable
focal_class.declarator: enumerateNestedFiles = false
focal_class.modifier: protected
focal_class.original_string: protected boolean enumerateNestedFiles = false;
focal_class.type: boolean
focal_class.var_name: enumerateNestedFiles
focal_class.declarator: FILE_PARAMETER_KEY = "input.file.path"
focal_class.modifier: private static final
focal_class.original_string: private static final String FILE_PARAMETER_KEY = "input.file.path";
focal_class.type: String
focal_class.var_name: FILE_PARAMETER_KEY
focal_class.declarator: ENUMERATE_NESTED_FILES_FLAG = "recursive.file.enumeration"
focal_class.modifier: public static final
focal_class.original_string: public static final String ENUMERATE_NESTED_FILES_FLAG = "recursive.file.enumeration";
focal_class.type: String
focal_class.var_name: ENUMERATE_NESTED_FILES_FLAG
focal_class.file: flink-core/src/main/java/org/apache/flink/api/common/io/FileInputFormat.java
focal_class.identifier: FileInputFormat
focal_class.class_method_signature: FileInputFormat.initDefaultsFromConfiguration()
focal_class.full_signature: private static void initDefaultsFromConfiguration()
focal_class.identifier: initDefaultsFromConfiguration
focal_class.modifiers: private static
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void initDefaultsFromConfiguration()
focal_class.class_method_signature: FileInputFormat.initDefaultInflaterInputStreamFactories()
focal_class.full_signature: private static void initDefaultInflaterInputStreamFactories()
focal_class.identifier: initDefaultInflaterInputStreamFactories
focal_class.modifiers: private static
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void initDefaultInflaterInputStreamFactories()
focal_class.class_method_signature: FileInputFormat.registerInflaterInputStreamFactory(String fileExtension, InflaterInputStreamFactory<?> factory)
focal_class.full_signature: public static void registerInflaterInputStreamFactory(String fileExtension, InflaterInputStreamFactory<?> factory)
focal_class.identifier: registerInflaterInputStreamFactory
focal_class.modifiers: public static
focal_class.parameters: (String fileExtension, InflaterInputStreamFactory<?> factory)
focal_class.return: void
focal_class.signature: void registerInflaterInputStreamFactory(String fileExtension, InflaterInputStreamFactory<?> factory)
focal_class.class_method_signature: FileInputFormat.getInflaterInputStreamFactory(String fileExtension)
focal_class.full_signature: protected static InflaterInputStreamFactory<?> getInflaterInputStreamFactory(String fileExtension)
focal_class.identifier: getInflaterInputStreamFactory
focal_class.modifiers: protected static
focal_class.parameters: (String fileExtension)
focal_class.return: InflaterInputStreamFactory<?>
focal_class.signature: InflaterInputStreamFactory<?> getInflaterInputStreamFactory(String fileExtension)
focal_class.class_method_signature: FileInputFormat.extractFileExtension(String fileName)
focal_class.full_signature: protected static String extractFileExtension(String fileName)
focal_class.identifier: extractFileExtension
focal_class.modifiers: protected static
focal_class.parameters: (String fileName)
focal_class.return: String
focal_class.signature: String extractFileExtension(String fileName)
focal_class.class_method_signature: FileInputFormat.getDefaultOpeningTimeout()
focal_class.full_signature: static long getDefaultOpeningTimeout()
focal_class.identifier: getDefaultOpeningTimeout
focal_class.modifiers: static
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long getDefaultOpeningTimeout()
focal_class.class_method_signature: FileInputFormat.FileInputFormat()
focal_class.full_signature: public  FileInputFormat()
focal_class.identifier: FileInputFormat
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  FileInputFormat()
focal_class.class_method_signature: FileInputFormat.FileInputFormat(Path filePath)
focal_class.full_signature: protected  FileInputFormat(Path filePath)
focal_class.identifier: FileInputFormat
focal_class.modifiers: protected
focal_class.parameters: (Path filePath)
focal_class.signature:  FileInputFormat(Path filePath)
focal_class.class_method_signature: FileInputFormat.getFilePath()
focal_class.full_signature: public Path getFilePath()
focal_class.identifier: getFilePath
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: Path
focal_class.signature: Path getFilePath()
focal_class.class_method_signature: FileInputFormat.setFilePath(String filePath)
focal_class.full_signature: public void setFilePath(String filePath)
focal_class.identifier: setFilePath
focal_class.modifiers: public
focal_class.parameters: (String filePath)
focal_class.return: void
focal_class.signature: void setFilePath(String filePath)
focal_class.class_method_signature: FileInputFormat.setFilePath(Path filePath)
focal_class.full_signature: public void setFilePath(Path filePath)
focal_class.identifier: setFilePath
focal_class.modifiers: public
focal_class.parameters: (Path filePath)
focal_class.return: void
focal_class.signature: void setFilePath(Path filePath)
focal_class.class_method_signature: FileInputFormat.getMinSplitSize()
focal_class.full_signature: public long getMinSplitSize()
focal_class.identifier: getMinSplitSize
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long getMinSplitSize()
focal_class.class_method_signature: FileInputFormat.setMinSplitSize(long minSplitSize)
focal_class.full_signature: public void setMinSplitSize(long minSplitSize)
focal_class.identifier: setMinSplitSize
focal_class.modifiers: public
focal_class.parameters: (long minSplitSize)
focal_class.return: void
focal_class.signature: void setMinSplitSize(long minSplitSize)
focal_class.class_method_signature: FileInputFormat.getNumSplits()
focal_class.full_signature: public int getNumSplits()
focal_class.identifier: getNumSplits
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int getNumSplits()
focal_class.class_method_signature: FileInputFormat.setNumSplits(int numSplits)
focal_class.full_signature: public void setNumSplits(int numSplits)
focal_class.identifier: setNumSplits
focal_class.modifiers: public
focal_class.parameters: (int numSplits)
focal_class.return: void
focal_class.signature: void setNumSplits(int numSplits)
focal_class.class_method_signature: FileInputFormat.getOpenTimeout()
focal_class.full_signature: public long getOpenTimeout()
focal_class.identifier: getOpenTimeout
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long getOpenTimeout()
focal_class.class_method_signature: FileInputFormat.setOpenTimeout(long openTimeout)
focal_class.full_signature: public void setOpenTimeout(long openTimeout)
focal_class.identifier: setOpenTimeout
focal_class.modifiers: public
focal_class.parameters: (long openTimeout)
focal_class.return: void
focal_class.signature: void setOpenTimeout(long openTimeout)
focal_class.class_method_signature: FileInputFormat.getSplitStart()
focal_class.full_signature: public long getSplitStart()
focal_class.identifier: getSplitStart
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long getSplitStart()
focal_class.class_method_signature: FileInputFormat.getSplitLength()
focal_class.full_signature: public long getSplitLength()
focal_class.identifier: getSplitLength
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long getSplitLength()
focal_class.class_method_signature: FileInputFormat.configure(Configuration parameters)
focal_class.full_signature: @Override public void configure(Configuration parameters)
focal_class.identifier: configure
focal_class.modifiers: @Override public
focal_class.parameters: (Configuration parameters)
focal_class.return: void
focal_class.signature: void configure(Configuration parameters)
focal_class.class_method_signature: FileInputFormat.getStatistics(BaseStatistics cachedStats)
focal_class.full_signature: @Override public FileBaseStatistics getStatistics(BaseStatistics cachedStats)
focal_class.identifier: getStatistics
focal_class.modifiers: @Override public
focal_class.parameters: (BaseStatistics cachedStats)
focal_class.return: FileBaseStatistics
focal_class.signature: FileBaseStatistics getStatistics(BaseStatistics cachedStats)
focal_class.class_method_signature: FileInputFormat.getFileStats(FileBaseStatistics cachedStats, Path filePath, FileSystem fs,
  			ArrayList<FileStatus> files)
focal_class.full_signature: protected FileBaseStatistics getFileStats(FileBaseStatistics cachedStats, Path filePath, FileSystem fs,
  			ArrayList<FileStatus> files)
focal_class.identifier: getFileStats
focal_class.modifiers: protected
focal_class.parameters: (FileBaseStatistics cachedStats, Path filePath, FileSystem fs,
  			ArrayList<FileStatus> files)
focal_class.return: FileBaseStatistics
focal_class.signature: FileBaseStatistics getFileStats(FileBaseStatistics cachedStats, Path filePath, FileSystem fs,
  			ArrayList<FileStatus> files)
focal_class.class_method_signature: FileInputFormat.getInputSplitAssigner(FileInputSplit[] splits)
focal_class.full_signature: @Override public LocatableInputSplitAssigner getInputSplitAssigner(FileInputSplit[] splits)
focal_class.identifier: getInputSplitAssigner
focal_class.modifiers: @Override public
focal_class.parameters: (FileInputSplit[] splits)
focal_class.return: LocatableInputSplitAssigner
focal_class.signature: LocatableInputSplitAssigner getInputSplitAssigner(FileInputSplit[] splits)
focal_class.class_method_signature: FileInputFormat.createInputSplits(int minNumSplits)
focal_class.full_signature: @Override public FileInputSplit[] createInputSplits(int minNumSplits)
focal_class.identifier: createInputSplits
focal_class.modifiers: @Override public
focal_class.parameters: (int minNumSplits)
focal_class.return: FileInputSplit[]
focal_class.signature: FileInputSplit[] createInputSplits(int minNumSplits)
focal_class.class_method_signature: FileInputFormat.addFilesInDir(Path path, List<FileStatus> files, boolean logExcludedFiles)
focal_class.full_signature: private long addFilesInDir(Path path, List<FileStatus> files, boolean logExcludedFiles)
focal_class.identifier: addFilesInDir
focal_class.modifiers: private
focal_class.parameters: (Path path, List<FileStatus> files, boolean logExcludedFiles)
focal_class.return: long
focal_class.signature: long addFilesInDir(Path path, List<FileStatus> files, boolean logExcludedFiles)
focal_class.class_method_signature: FileInputFormat.testForUnsplittable(FileStatus pathFile)
focal_class.full_signature: protected boolean testForUnsplittable(FileStatus pathFile)
focal_class.identifier: testForUnsplittable
focal_class.modifiers: protected
focal_class.parameters: (FileStatus pathFile)
focal_class.return: boolean
focal_class.signature: boolean testForUnsplittable(FileStatus pathFile)
focal_class.class_method_signature: FileInputFormat.getInflaterInputStreamFactory(Path path)
focal_class.full_signature: private InflaterInputStreamFactory<?> getInflaterInputStreamFactory(Path path)
focal_class.identifier: getInflaterInputStreamFactory
focal_class.modifiers: private
focal_class.parameters: (Path path)
focal_class.return: InflaterInputStreamFactory<?>
focal_class.signature: InflaterInputStreamFactory<?> getInflaterInputStreamFactory(Path path)
focal_class.class_method_signature: FileInputFormat.acceptFile(FileStatus fileStatus)
focal_class.full_signature: protected boolean acceptFile(FileStatus fileStatus)
focal_class.identifier: acceptFile
focal_class.modifiers: protected
focal_class.parameters: (FileStatus fileStatus)
focal_class.return: boolean
focal_class.signature: boolean acceptFile(FileStatus fileStatus)
focal_class.class_method_signature: FileInputFormat.getBlockIndexForPosition(BlockLocation[] blocks, long offset, long halfSplitSize, int startIndex)
focal_class.full_signature: private int getBlockIndexForPosition(BlockLocation[] blocks, long offset, long halfSplitSize, int startIndex)
focal_class.identifier: getBlockIndexForPosition
focal_class.modifiers: private
focal_class.parameters: (BlockLocation[] blocks, long offset, long halfSplitSize, int startIndex)
focal_class.return: int
focal_class.signature: int getBlockIndexForPosition(BlockLocation[] blocks, long offset, long halfSplitSize, int startIndex)
focal_class.class_method_signature: FileInputFormat.open(FileInputSplit fileSplit)
focal_class.full_signature: @Override public void open(FileInputSplit fileSplit)
focal_class.identifier: open
focal_class.modifiers: @Override public
focal_class.parameters: (FileInputSplit fileSplit)
focal_class.return: void
focal_class.signature: void open(FileInputSplit fileSplit)
focal_class.class_method_signature: FileInputFormat.decorateInputStream(FSDataInputStream inputStream, FileInputSplit fileSplit)
focal_class.full_signature: protected FSDataInputStream decorateInputStream(FSDataInputStream inputStream, FileInputSplit fileSplit)
focal_class.identifier: decorateInputStream
focal_class.modifiers: protected
focal_class.parameters: (FSDataInputStream inputStream, FileInputSplit fileSplit)
focal_class.return: FSDataInputStream
focal_class.signature: FSDataInputStream decorateInputStream(FSDataInputStream inputStream, FileInputSplit fileSplit)
focal_class.class_method_signature: FileInputFormat.close()
focal_class.full_signature: @Override public void close()
focal_class.identifier: close
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void close()
focal_class.class_method_signature: FileInputFormat.toString()
focal_class.full_signature: public String toString()
focal_class.identifier: toString
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String toString()
focal_class.superclass: extends RichInputFormat<OT, FileInputSplit>
focal_method.body: protected FSDataInputStream decorateInputStream(FSDataInputStream inputStream, FileInputSplit fileSplit) throws Throwable {
  		// Wrap stream in a extracting (decompressing) stream if file ends with a known compression file extension.
  		InflaterInputStreamFactory<?> inflaterInputStreamFactory = getInflaterInputStreamFactory(fileSplit.getPath());
  		if (inflaterInputStreamFactory != null) {
  			return new InputStreamFSInputWrapper(inflaterInputStreamFactory.create(stream));
  		}
  
  		return inputStream;
  	}
focal_method.class_method_signature: FileInputFormat.decorateInputStream(FSDataInputStream inputStream, FileInputSplit fileSplit)
focal_method.full_signature: protected FSDataInputStream decorateInputStream(FSDataInputStream inputStream, FileInputSplit fileSplit)
focal_method.identifier: decorateInputStream
focal_method.invocations: getInflaterInputStreamFactory getPath create
focal_method.modifiers: protected
focal_method.parameters: (FSDataInputStream inputStream, FileInputSplit fileSplit)
focal_method.return: FSDataInputStream
focal_method.signature: FSDataInputStream decorateInputStream(FSDataInputStream inputStream, FileInputSplit fileSplit)