@Deprecated public abstract class AbstractFileStateHandle extends AbstractCloseableHandle implements StateObject
Modifier | Constructor and Description |
---|---|
protected |
AbstractFileStateHandle(Path filePath)
Deprecated.
Creates a new file state for the given file path.
|
Modifier and Type | Method and Description |
---|---|
void |
discardState()
Deprecated.
Discard the state by deleting the file that stores the state.
|
Path |
getFilePath()
Deprecated.
Gets the path where this handle's state is stored.
|
protected long |
getFileSize()
Deprecated.
Returns the file size in bytes.
|
protected FileSystem |
getFileSystem()
Deprecated.
Gets the file system that stores the file state.
|
close, ensureNotClosed, isClosed, registerCloseable
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getStateSize
protected AbstractFileStateHandle(Path filePath)
filePath
- The path to the file that stores the state.public Path getFilePath()
public void discardState() throws Exception
discardState
in interface StateObject
Exception
- Thrown, if the file deletion (not the directory deletion) fails.protected FileSystem getFileSystem() throws IOException
IOException
- Thrown if the file system cannot be accessed.protected long getFileSize() throws IOException
IOException
- Thrown if the file system cannot be accessed.Copyright © 2014–2018 The Apache Software Foundation. All rights reserved.