public class LocalDiskFetchedInput extends FetchedInput
FetchedInput.State, FetchedInput.Type
actualSize, callback, compressedSize, id, inputAttemptIdentifier, state, type
Constructor and Description |
---|
LocalDiskFetchedInput(long startOffset,
long actualSize,
long compressedSize,
InputAttemptIdentifier inputAttemptIdentifier,
org.apache.hadoop.fs.Path inputFile,
org.apache.hadoop.conf.Configuration conf,
FetchedInputCallback callbackHandler) |
Modifier and Type | Method and Description |
---|---|
void |
abort()
Abort the output.
|
void |
commit()
Commit the output.
|
void |
free()
Called when this input has been consumed, so that resources can be
reclaimed.
|
protected org.apache.hadoop.fs.Path |
getInputFile() |
InputStream |
getInputStream()
Return an input stream to be used to read the previously fetched data.
|
protected org.apache.hadoop.fs.FileSystem |
getLocalFS() |
OutputStream |
getOutputStream()
Returns the output stream to be used to write fetched data.
|
protected long |
getStartOffset() |
String |
toString() |
equals, getActualSize, getCompressedSize, getInputAttemptIdentifier, getType, hashCode, notifyFetchComplete, notifyFetchFailure, notifyFreedResource
public LocalDiskFetchedInput(long startOffset, long actualSize, long compressedSize, InputAttemptIdentifier inputAttemptIdentifier, org.apache.hadoop.fs.Path inputFile, org.apache.hadoop.conf.Configuration conf, FetchedInputCallback callbackHandler) throws IOException
IOException
public OutputStream getOutputStream() throws IOException
FetchedInput
getOutputStream
in class FetchedInput
IOException
public InputStream getInputStream() throws IOException
FetchedInput
getInputStream
in class FetchedInput
IOException
public void commit()
FetchedInput
commit
in class FetchedInput
public void abort()
FetchedInput
abort
in class FetchedInput
public void free()
FetchedInput
free
in class FetchedInput
protected org.apache.hadoop.fs.Path getInputFile()
protected long getStartOffset()
protected org.apache.hadoop.fs.FileSystem getLocalFS()
Copyright © 2016 Apache Software Foundation. All rights reserved.