private static class HFileArchiver.FileablePath extends HFileArchiver.File
Modifier and Type | Field and Description |
---|---|
private org.apache.hadoop.fs.Path |
file |
private HFileArchiver.FileStatusConverter |
getAsFile |
fs
Constructor and Description |
---|
FileablePath(org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path file) |
Modifier and Type | Method and Description |
---|---|
void |
close()
close any outside readers of the file n
|
void |
delete()
Delete the file
|
Collection<HFileArchiver.File> |
getChildren() |
String |
getName()
Returns the name of the file (not the full fs path, just the individual file name)
|
(package private) org.apache.hadoop.fs.Path |
getPath()
Returns the path to this file
|
boolean |
isFile()
Check to see if this is a file or a directory
|
getFileSystem, moveAndClose, toString
private final org.apache.hadoop.fs.Path file
private final HFileArchiver.FileStatusConverter getAsFile
public FileablePath(org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path file)
public void delete() throws IOException
HFileArchiver.File
delete
in class HFileArchiver.File
IOException
- on failurepublic String getName()
HFileArchiver.File
getName
in class HFileArchiver.File
public Collection<HFileArchiver.File> getChildren() throws IOException
getChildren
in class HFileArchiver.File
IOException
public boolean isFile() throws IOException
HFileArchiver.File
isFile
in class HFileArchiver.File
IOException
- on FileSystem
connection errorpublic void close() throws IOException
HFileArchiver.File
close
in class HFileArchiver.File
IOException
org.apache.hadoop.fs.Path getPath()
HFileArchiver.File
getPath
in class HFileArchiver.File
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.