java.lang.Object
org.cryptomator.frontend.fuse.OpenFile
- All Implemented Interfaces:
Closeable,AutoCloseable
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()voidfsync(boolean metaData) intread(ByteBuffer buf, long num, long offset) Reads up tonumbytes beginning atoffsetintobuftoString()voidtruncate(long size) intwrite(ByteBuffer buf, long num, long offset) Writes up tonumbytes frombuffromoffsetinto the current file
-
Method Details
-
read
Reads up tonumbytes beginning atoffsetintobuf- Parameters:
buf- Buffernum- Number of bytes to readoffset- Position of first byte to read- Returns:
- Actual number of bytes read (can be less than
sizeif reached EOF). - Throws:
IOException- If an exception occurs during read.
-
write
Writes up tonumbytes frombuffromoffsetinto the current file- Parameters:
buf- Buffernum- Number of bytes to writeoffset- Position of first byte to write at- Returns:
- Actual number of bytes written
- Throws:
IOException- If an exception occurs during write.
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
fsync
- Throws:
IOException
-
truncate
- Throws:
IOException
-
toString
-