public class HdfsDirectory extends BaseDirectory
Modifier and Type | Class and Description |
---|---|
static class |
HdfsDirectory.HdfsIndexInput |
Modifier and Type | Field and Description |
---|---|
protected org.apache.hadoop.conf.Configuration |
configuration |
static int |
DEFAULT_BUFFER_SIZE |
protected org.apache.hadoop.fs.Path |
hdfsDirPath |
isOpen, lockFactory
Constructor and Description |
---|
HdfsDirectory(org.apache.hadoop.fs.Path hdfsDirPath,
org.apache.hadoop.conf.Configuration configuration) |
HdfsDirectory(org.apache.hadoop.fs.Path hdfsDirPath,
LockFactory lockFactory,
org.apache.hadoop.conf.Configuration configuration,
int bufferSize) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
IndexOutput |
createOutput(String name,
IOContext context) |
IndexOutput |
createTempOutput(String prefix,
String suffix,
IOContext context) |
void |
deleteFile(String name) |
boolean |
equals(Object obj) |
long |
fileLength(String name) |
long |
fileModified(String name) |
org.apache.hadoop.conf.Configuration |
getConfiguration() |
org.apache.hadoop.fs.FileSystem |
getFileSystem() |
org.apache.hadoop.fs.Path |
getHdfsDirPath() |
int |
hashCode() |
boolean |
isClosed()
Check whether this directory is open or closed.
|
String[] |
listAll() |
IndexInput |
openInput(String name,
IOContext context) |
void |
rename(String source,
String dest) |
void |
sync(Collection<String> names) |
void |
syncMetaData() |
String |
toString() |
ensureOpen, obtainLock
copyFrom, openChecksumInput
public static final int DEFAULT_BUFFER_SIZE
protected final org.apache.hadoop.fs.Path hdfsDirPath
protected final org.apache.hadoop.conf.Configuration configuration
public HdfsDirectory(org.apache.hadoop.fs.Path hdfsDirPath, org.apache.hadoop.conf.Configuration configuration) throws IOException
IOException
public HdfsDirectory(org.apache.hadoop.fs.Path hdfsDirPath, LockFactory lockFactory, org.apache.hadoop.conf.Configuration configuration, int bufferSize) throws IOException
IOException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in class Directory
IOException
public boolean isClosed()
public IndexOutput createOutput(String name, IOContext context) throws IOException
createOutput
in class Directory
IOException
public IndexOutput createTempOutput(String prefix, String suffix, IOContext context) throws IOException
createTempOutput
in class Directory
IOException
public IndexInput openInput(String name, IOContext context) throws IOException
openInput
in class Directory
IOException
public void deleteFile(String name) throws IOException
deleteFile
in class Directory
IOException
public void rename(String source, String dest) throws IOException
rename
in class Directory
IOException
public void syncMetaData() throws IOException
syncMetaData
in class Directory
IOException
public long fileLength(String name) throws IOException
fileLength
in class Directory
IOException
public long fileModified(String name) throws IOException
IOException
public String[] listAll() throws IOException
listAll
in class Directory
IOException
public org.apache.hadoop.fs.Path getHdfsDirPath()
public org.apache.hadoop.fs.FileSystem getFileSystem()
public org.apache.hadoop.conf.Configuration getConfiguration()
public void sync(Collection<String> names) throws IOException
sync
in class Directory
IOException
public String toString()
toString
in class BaseDirectory
Copyright © 2000-2018 Apache Software Foundation. All Rights Reserved.