|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.hadoop.conf.Configured org.apache.hadoop.fs.FileSystem org.apache.hadoop.fs.FilterFileSystem org.apache.hadoop.fs.ChecksumFileSystem org.apache.hadoop.fs.LocalFileSystem
@InterfaceAudience.Public @InterfaceStability.Stable public class LocalFileSystem
Implement the FileSystem API for the checksumed local filesystem.
Field Summary |
---|
Fields inherited from class org.apache.hadoop.fs.FilterFileSystem |
---|
fs, swapScheme |
Fields inherited from class org.apache.hadoop.fs.FileSystem |
---|
DEFAULT_FS, FS_DEFAULT_NAME_KEY, LOG, SHUTDOWN_HOOK_PRIORITY, statistics |
Constructor Summary | |
---|---|
LocalFileSystem()
|
|
LocalFileSystem(FileSystem rawLocalFileSystem)
|
Method Summary | |
---|---|
void |
copyFromLocalFile(boolean delSrc,
Path src,
Path dst)
The src file is on the local disk. |
void |
copyToLocalFile(boolean delSrc,
Path src,
Path dst)
The src file is under FS, and the dst is on the local disk. |
void |
createSymlink(Path target,
Path link,
boolean createParent)
See FileContext.createSymlink(Path, Path, boolean) |
FileStatus |
getFileLinkStatus(Path f)
See FileContext.getFileLinkStatus(Path) |
Path |
getLinkTarget(Path f)
See FileContext.getLinkTarget(Path) |
FileSystem |
getRaw()
|
String |
getScheme()
Return the protocol scheme for the FileSystem. |
void |
initialize(URI name,
Configuration conf)
Called after a new FileSystem instance is constructed. |
File |
pathToFile(Path path)
Convert a path to a File. |
boolean |
reportChecksumFailure(Path p,
FSDataInputStream in,
long inPos,
FSDataInputStream sums,
long sumsPos)
Moves files to a bad file directory on the same device, so that their storage will not be reused. |
boolean |
supportsSymlinks()
See AbstractFileSystem.supportsSymlinks() |
Methods inherited from class org.apache.hadoop.fs.ChecksumFileSystem |
---|
append, completeLocalOutput, copyToLocalFile, create, createNonRecursive, delete, getApproxChkSumLength, getBytesPerSum, getChecksumFile, getChecksumFileLength, getChecksumLength, getRawFileSystem, isChecksumFile, listLocatedStatus, listStatus, mkdirs, open, rename, setConf, setReplication, setVerifyChecksum, setWriteChecksum, startLocalOutput |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LocalFileSystem()
public LocalFileSystem(FileSystem rawLocalFileSystem)
Method Detail |
---|
public void initialize(URI name, Configuration conf) throws IOException
FilterFileSystem
initialize
in class FilterFileSystem
name
- a uri whose authority section names the host, port, etc.
for this FileSystemconf
- the configuration
IOException
public String getScheme()
getScheme
in class FileSystem
file
public FileSystem getRaw()
public File pathToFile(Path path)
public void copyFromLocalFile(boolean delSrc, Path src, Path dst) throws IOException
FilterFileSystem
copyFromLocalFile
in class ChecksumFileSystem
delSrc
- whether to delete the srcsrc
- pathdst
- path
IOException
public void copyToLocalFile(boolean delSrc, Path src, Path dst) throws IOException
ChecksumFileSystem
copyToLocalFile
in class ChecksumFileSystem
delSrc
- whether to delete the srcsrc
- pathdst
- path
IOException
public boolean reportChecksumFailure(Path p, FSDataInputStream in, long inPos, FSDataInputStream sums, long sumsPos)
reportChecksumFailure
in class ChecksumFileSystem
p
- the file name containing the errorin
- the stream open on the fileinPos
- the position of the beginning of the bad data in the filesums
- the stream open on the checksum filesumsPos
- the position of the beginning of the bad data in the checksum file
public boolean supportsSymlinks()
FileSystem
AbstractFileSystem.supportsSymlinks()
supportsSymlinks
in class FilterFileSystem
public void createSymlink(Path target, Path link, boolean createParent) throws IOException
FileSystem
FileContext.createSymlink(Path, Path, boolean)
createSymlink
in class FilterFileSystem
IOException
public FileStatus getFileLinkStatus(Path f) throws IOException
FileSystem
FileContext.getFileLinkStatus(Path)
getFileLinkStatus
in class FilterFileSystem
IOException
public Path getLinkTarget(Path f) throws IOException
FileSystem
FileContext.getLinkTarget(Path)
getLinkTarget
in class FilterFileSystem
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |