Package one.microstream.storage.types
Interface StorageFileWriter
- All Known Subinterfaces:
StorageFileWriterBackupping
- All Known Implementing Classes:
StorageFileWriter.Default,StorageFileWriterBackupping.Default
public interface StorageFileWriter
Function type that encapsulates handling of all writing accesses to persistent data, including copying,
truncation, deletion.
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classStorageFileWriter.Defaultstatic interfaceStorageFileWriter.Provider -
Method Summary
Modifier and Type Method Description static voidcreateFileFullCopy(StorageFile sourceFile, AFile targetFile)default voiddelete(StorageLiveDataFile file, StorageWriteController writeController, StorageFileProvider fileProvider)static voiddeleteFile(StorageChannelFile file, StorageWriteController writeController, StorageFileProvider fileProvider)static booleanrescueFromDeletion(StorageChannelFile file, StorageWriteController writeController, StorageFileProvider fileProvider)default voidtruncate(StorageLiveChannelFile<?> file, long newLength, StorageFileProvider fileProvider)static voidtruncateFile(StorageTruncatableChannelFile file, long newLength, StorageFileProvider fileProvider)static longvalidateIoByteCount(long specifiedByteCount, long actualByteCount)default longwrite(StorageFile file, Iterable<? extends ByteBuffer> buffers)default longwriteImport(StorageFile sourceFile, long sourceOffset, long copyLength, StorageLiveDataFile targetFile)Logically the same as a store, but technically the same as a transfer with an external source file.default longwriteStore(StorageLiveDataFile targetFile, Iterable<? extends ByteBuffer> byteBuffers)default longwriteTransactionEntryCreate(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile)default longwriteTransactionEntryDelete(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile)default longwriteTransactionEntryStore(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile, long dataFileOffset, long storeLength)default longwriteTransactionEntryTransfer(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile, long dataFileOffset, long storeLength)default longwriteTransactionEntryTruncate(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile, long newFileLength)default longwriteTransfer(StorageLiveDataFile sourceFile, long sourceOffset, long copyLength, StorageLiveDataFile targetFile)
-
Method Details
-
validateIoByteCount
static long validateIoByteCount(long specifiedByteCount, long actualByteCount) -
write
-
writeStore
default long writeStore(StorageLiveDataFile targetFile, Iterable<? extends ByteBuffer> byteBuffers) -
writeImport
default long writeImport(StorageFile sourceFile, long sourceOffset, long copyLength, StorageLiveDataFile targetFile)Logically the same as a store, but technically the same as a transfer with an external source file. -
writeTransfer
default long writeTransfer(StorageLiveDataFile sourceFile, long sourceOffset, long copyLength, StorageLiveDataFile targetFile) -
writeTransactionEntryCreate
default long writeTransactionEntryCreate(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile) -
writeTransactionEntryStore
default long writeTransactionEntryStore(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile, long dataFileOffset, long storeLength) -
writeTransactionEntryTransfer
default long writeTransactionEntryTransfer(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile, long dataFileOffset, long storeLength) -
writeTransactionEntryDelete
default long writeTransactionEntryDelete(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile) -
writeTransactionEntryTruncate
default long writeTransactionEntryTruncate(StorageLiveTransactionsFile transactionFile, Iterable<? extends ByteBuffer> byteBuffers, StorageLiveDataFile dataFile, long newFileLength) -
truncate
default void truncate(StorageLiveChannelFile<?> file, long newLength, StorageFileProvider fileProvider) -
truncateFile
static void truncateFile(StorageTruncatableChannelFile file, long newLength, StorageFileProvider fileProvider) -
delete
default void delete(StorageLiveDataFile file, StorageWriteController writeController, StorageFileProvider fileProvider) -
deleteFile
static void deleteFile(StorageChannelFile file, StorageWriteController writeController, StorageFileProvider fileProvider) -
createFileFullCopy
-
rescueFromDeletion
static boolean rescueFromDeletion(StorageChannelFile file, StorageWriteController writeController, StorageFileProvider fileProvider)
-