Package sonia.scm.store
Interface DataStoreFactory
public interface DataStoreFactory
The DataStoreFactory can be used to create new or get existing
You can either create a global
DataStore
s.
You can either create a global
DataStore
or a DataStore
for a specific repository.
To create a global DataStore
call:
dataStoreFactory
.withType(PersistedType.class)
.withName("name")
.build();
To create a DataStore
for a specific repository call:
dataStoreFactory
.withType(PersistedType.class)
.withName("name")
.forRepository(repository)
.build();
- Since:
- 1.23
-
Method Summary
Modifier and TypeMethodDescription<T> DataStore<T>
getStore
(TypedStoreParameters<T> storeParameters) Creates a new or gets an existingDataStore
.default <T> TypedStoreParametersBuilder<T,
DataStore<T>> Use this to create a new or get an existingDataStore
with a floating API.
-
Method Details
-
getStore
Creates a new or gets an existingDataStore
. Instead of calling this method you should use the floating API fromwithType(Class)
. -
withType
Use this to create a new or get an existingDataStore
with a floating API.
-