@PublicApi @NotThreadSafe public class OpenOptions extends Object
UnderFileSystem
.Modifier | Constructor and Description |
---|---|
protected |
OpenOptions()
Constructs a default
OpenOptions . |
Modifier and Type | Method and Description |
---|---|
static OpenOptions |
defaults() |
boolean |
equals(Object o) |
long |
getLength() |
long |
getOffset() |
boolean |
getPositionShort() |
boolean |
getRecoverFailedOpen() |
int |
hashCode() |
OpenOptions |
setLength(long length) |
OpenOptions |
setOffset(long offset)
Sets the offset from the start of a file to be opened for reading.
|
OpenOptions |
setPositionShort(boolean positionShort) |
OpenOptions |
setRecoverFailedOpen(boolean recover) |
String |
toString() |
protected OpenOptions()
OpenOptions
.public static OpenOptions defaults()
OpenOptions
public long getOffset()
public long getLength()
public boolean getRecoverFailedOpen()
public boolean getPositionShort()
public OpenOptions setOffset(long offset)
offset
- within a file in bytespublic OpenOptions setLength(long length)
length
- the maximum length of the filepublic OpenOptions setRecoverFailedOpen(boolean recover)
recover
- true if failed open attempts should be recoveredpublic OpenOptions setPositionShort(boolean positionShort)
positionShort
- whether the operation is positioned read to a small bufferCopyright © 2023. All Rights Reserved.