Package sonia.scm.store
Interface DataStoreFactory
public interface DataStoreFactory
The DataStoreFactory can be used to create new or get existing
Call this to create a global
To create a
DataStore
s.
You can either create a global DataStore
or a DataStore
for a specific repository.
Call this to create a global
DataStore
:
dataStoreFactory.withType(PersistedType.class).withName("name").build();
To create a
DataStore
for a specific repository:
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.
-