Interface IAkavacheBuilder
- Namespace
- Akavache
- Assembly
- Akavache.dll
Interface for building and configuring BlobCache instances.
- Inherited Members
- Extension Methods
Properties
FileLocationOption
Gets the file location option.
Property Value
- File
Location Option The file location option.
Methods
Build()
Builds the configuration and returns the configured Akavache instance.
Returns
- IAkavache
Instance The configured Akavache instance ready for use.
UseForcedDateTimeKind(DateTimeKind)
Sets the forced DateTime kind for serialization operations.
Parameters
kindDateTime Kind The DateTime kind to use for all DateTime serialization.
Returns
- IAkavache
Builder The builder instance for fluent configuration.
WithApplicationName(string?)
Sets the application name for cache directory paths.
Parameters
applicationNamestringThe application name.
Returns
- IAkavache
Builder The builder instance for fluent configuration.
WithInMemory(IBlobCache)
Sets the InMemory cache instance.
Parameters
cacheIBlobCache The cache instance to use for InMemory operations.
Returns
- IAkavache
Builder The builder instance for fluent configuration.
WithInMemoryDefaults()
Configures default in-memory caches for all cache types. Uses the appropriate InMemoryBlobCache based on the configured serializer.
Returns
- IAkavache
Builder The builder instance for fluent configuration.
WithLocalMachine(IBlobCache)
Sets the LocalMachine cache instance.
Parameters
cacheIBlobCache The cache instance to use for LocalMachine operations.
Returns
- IAkavache
Builder The builder instance for fluent configuration.
WithSecure(ISecureBlobCache)
Sets the Secure cache instance.
Parameters
cacheISecureBlob Cache The secure cache instance to use for Secure operations.
Returns
- IAkavache
Builder The builder instance for fluent configuration.
WithSerializer<T>()
Configures the serializer to use for cache operations.
[RequiresUnreferencedCode("Serializers require types to be preserved for serialization.")]
IAkavacheBuilder WithSerializer<T>() where T : ISerializer, new()
Returns
- IAkavache
Builder The builder instance for fluent configuration.
Type Parameters
TThe type of serializer to configure.
WithSerializer<T>(Func<T>)
Configures the serializer to use for cache operations with a custom factory function.
[RequiresUnreferencedCode("Serializers require types to be preserved for serialization.")]
IAkavacheBuilder WithSerializer<T>(Func<T> configure) where T : ISerializer
Parameters
configureFunc<T>A function that creates and configures the serializer instance.
Returns
- IAkavache
Builder The builder instance for fluent configuration.
Type Parameters
TThe type of serializer to configure.
WithUserAccount(IBlobCache)
Sets the UserAccount cache instance.
Parameters
cacheIBlobCache The cache instance to use for UserAccount operations.
Returns
- IAkavache
Builder The builder instance for fluent configuration.