Package one.microstream.storage.types
Interface StorageFileProvider
- All Superinterfaces:
PersistenceTypeDictionaryIoHandler.Provider
- All Known Subinterfaces:
StorageIoHandler
- All Known Implementing Classes:
StorageFileProvider.Default,StorageIoHandler.Default
public interface StorageFileProvider extends PersistenceTypeDictionaryIoHandler.Provider
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceStorageFileProvider.Builder<B extends StorageFileProvider.Builder<?>>static classStorageFileProvider.Defaultstatic interfaceStorageFileProvider.Defaultsstatic classStorageFileProvider.Static -
Method Summary
Modifier and Type Method Description static StorageFileProvider.Builder<?>Builder()Pseudo-constructor method to create a newStorageFileProvider.Builderinstance.<P extends Consumer<StorageNumberedFile>>
PcollectDataFiles(P collector, int channelIndex)StringgetStorageLocationIdentifier()Returns a String that uniquely identifies the storage location.static StorageFileProviderNew()Pseudo-constructor method to create a newStorageFileProviderinstance with default values provided byStorageFileProvider.Defaults.static StorageFileProvider.DefaultNew(String baseDirectory, String deletionDirectory, String truncationDirectory, String channelDirectoryPrefix, String storageFilePrefix, String storageFileSuffix, String transactionsFilePrefix, String transactionsFileSuffix, String typeDictionaryFileName, String lockFileName, PersistenceTypeDictionaryFileHandler.Creator fileHandlerCreator)static StorageFileProviderNew(Path storageDirectory)Pseudo-constructor method to create a newStorageFileProviderinstance with the passed file as the storage directory and defaults provided byStorageFileProvider.Defaults.StorageNumberedFileprovideDataFile(int channelIndex, long fileNumber)StorageNumberedFileprovideDeletionTargetFile(StorageNumberedFile fileToBeDeleted)StorageLockedFileprovideLockFile()StorageNumberedFileprovideTransactionsFile(int channelIndex)StorageNumberedFileprovideTruncationBackupTargetFile(StorageNumberedFile fileToBeTruncated, long newLength)PersistenceTypeDictionaryIoHandlerprovideTypeDictionaryIoHandler(PersistenceTypeDictionaryStorer writeListener)Methods inherited from interface one.microstream.persistence.types.PersistenceTypeDictionaryIoHandler.Provider
provideTypeDictionaryIoHandler
-
Method Details
-
getStorageLocationIdentifier
String getStorageLocationIdentifier()Returns a String that uniquely identifies the storage location.- Returns:
- a String that uniquely identifies the storage location.
-
provideTypeDictionaryIoHandler
PersistenceTypeDictionaryIoHandler provideTypeDictionaryIoHandler(PersistenceTypeDictionaryStorer writeListener)- Specified by:
provideTypeDictionaryIoHandlerin interfacePersistenceTypeDictionaryIoHandler.Provider
-
provideDataFile
-
provideTransactionsFile
-
provideLockFile
StorageLockedFile provideLockFile() -
provideDeletionTargetFile
-
provideTruncationBackupTargetFile
StorageNumberedFile provideTruncationBackupTargetFile(StorageNumberedFile fileToBeTruncated, long newLength) -
collectDataFiles
-
Builder
Pseudo-constructor method to create a newStorageFileProvider.Builderinstance.For explanations and customizing values, see
StorageFileProvider.Builder.- Returns:
- a new
StorageFileProvider.Builderinstance.
-
New
Pseudo-constructor method to create a newStorageFileProviderinstance with default values provided byStorageFileProvider.Defaults.For explanations and customizing values, see
StorageFileProvider.Builder.- Returns:
- a new
StorageFileProviderinstance. - See Also:
New(Path),StorageFileProvider.Builder,StorageFileProvider.Defaults
-
New
Pseudo-constructor method to create a newStorageFileProviderinstance with the passed file as the storage directory and defaults provided byStorageFileProvider.Defaults.For explanations and customizing values, see
StorageFileProvider.Builder.- Parameters:
storageDirectory- the directory where the storage will be located.- Returns:
- a new
StorageFileProviderinstance. - See Also:
New(),StorageFileProvider.Builder,StorageFileProvider.Defaults
-
New
static StorageFileProvider.Default New(String baseDirectory, String deletionDirectory, String truncationDirectory, String channelDirectoryPrefix, String storageFilePrefix, String storageFileSuffix, String transactionsFilePrefix, String transactionsFileSuffix, String typeDictionaryFileName, String lockFileName, PersistenceTypeDictionaryFileHandler.Creator fileHandlerCreator)- Parameters:
baseDirectory- may not be null.channelDirectoryPrefix- may not be null.storageFilePrefix- may not be null.storageFileSuffix- may not be null.transactionsFilePrefix- may not be null.transactionsFileSuffix- may not be null.typeDictionaryFileName- may not be null.lockFileName- may not be null.fileHandlerCreator- may not be null.deletionDirectory- may be null.truncationDirectory- may be null.
-