public class FlippingDirectory
extends Directory
Modifier and Type | Field and Description |
---|---|
private Directory |
wrapped |
Constructor and Description |
---|
FlippingDirectory(Directory toWrap)
Wrap a directory to start with
|
Modifier and Type | Method and Description |
---|---|
void |
clearLock(String name) |
void |
close() |
IndexOutput |
createOutput(String name) |
void |
deleteFile(String name) |
boolean |
fileExists(String name) |
long |
fileLength(String name) |
long |
fileModified(String name) |
void |
flipTo(Directory other)
Switch to a different underlying directory.
|
LockFactory |
getLockFactory() |
String |
getLockID() |
String[] |
list() |
Lock |
makeLock(String name) |
IndexInput |
openInput(String name) |
void |
renameFile(String from,
String to) |
void |
setLockFactory(LockFactory lockFactory) |
void |
touchFile(String name) |
public FlippingDirectory(Directory toWrap)
public void flipTo(Directory other)
public void clearLock(String name) throws IOException
clearLock
in class Directory
IOException
public void close() throws IOException
close
in class Directory
IOException
public IndexOutput createOutput(String name) throws IOException
createOutput
in class Directory
IOException
public void deleteFile(String name) throws IOException
deleteFile
in class Directory
IOException
public boolean fileExists(String name) throws IOException
fileExists
in class Directory
IOException
public long fileLength(String name) throws IOException
fileLength
in class Directory
IOException
public long fileModified(String name) throws IOException
fileModified
in class Directory
IOException
public LockFactory getLockFactory()
getLockFactory
in class Directory
public String getLockID()
getLockID
in class Directory
public String[] list() throws IOException
list
in class Directory
IOException
public Lock makeLock(String name)
makeLock
in class Directory
public IndexInput openInput(String name) throws IOException
openInput
in class Directory
IOException
public void renameFile(String from, String to) throws IOException
renameFile
in class Directory
IOException
public void setLockFactory(LockFactory lockFactory)
setLockFactory
in class Directory
public void touchFile(String name) throws IOException
touchFile
in class Directory
IOException