Class EmbeddedStorage
public final class EmbeddedStorage extends Object
In the simplest case, the following call is enough to setup and start an embedded object graph database:
EmbeddedStorageManager storage = EmbeddedStorage.start();
Anything beyond that is optimization and customization. As it should be.
-
Constructor Summary
Constructors Constructor Description EmbeddedStorage()
-
Method Summary
Modifier and Type Method Description static EmbeddedStorageConnectionFoundation<?>
ConnectionFoundation(ADirectory directory)
Pseudo-constructor method to create a newEmbeddedStorageConnectionFoundation
instance using the passed directory and default method references provided byPersistence
.static EmbeddedStorageConnectionFoundation<?>
ConnectionFoundation(PersistenceTypeDictionaryIoHandler typeDictionaryIoHandler)
Pseudo-constructor method to create a newEmbeddedStorageConnectionFoundation
instance using the passedPersistenceTypeDictionaryIoHandler
and default method references provided byPersistence
.static EmbeddedStorageConnectionFoundation<?>
ConnectionFoundation(PersistenceTypeDictionaryIoHandler typeDictionaryIoHandler, PersistenceTypeEvaluator typeEvaluatorPersistable)
Pseudo-constructor method to create a newEmbeddedStorageConnectionFoundation
instance using the passed logic instances as its essential parts.static EmbeddedStorageConnectionFoundation<?>
ConnectionFoundation(StorageConfiguration configuration, PersistenceTypeEvaluator typeEvaluatorPersistable)
static EmbeddedStorageFoundation<?>
createFoundation()
Creates an instance of anEmbeddedStorageFoundation
default implementation without any assembly parts set.static EmbeddedStorageFoundation<?>
Foundation()
Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using#defaultStorageDirectory()
as its storage directory and default values for itsStorageConfiguration
.static EmbeddedStorageFoundation<?>
Foundation(File directory)
Deprecated.replaced byFoundation(Path)
static EmbeddedStorageFoundation<?>
Foundation(Path directory)
static EmbeddedStorageFoundation<?>
Foundation(ADirectory directory)
Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using the passed directory and default values for the remaining parts of itsStorageConfiguration
.static EmbeddedStorageFoundation<?>
Foundation(StorageConfiguration configuration)
Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using the passedStorageConfiguration
.static EmbeddedStorageFoundation<?>
Foundation(StorageConfiguration.Builder<?> configuration)
Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using the passedStorageConfiguration.Builder
to build itsStorageConfiguration
.static EmbeddedStorageFoundation<?>
Foundation(StorageConfiguration configuration, EmbeddedStorageConnectionFoundation<?> connectionFoundation)
Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using the passedStorageConfiguration
andEmbeddedStorageConnectionFoundation
.static EmbeddedStorageManager
start()
Convenience method to configure, create and start aEmbeddedStorageManager
using purely default values.static EmbeddedStorageManager
start(File directory)
Deprecated.replaced bystart(Path)
static EmbeddedStorageManager
start(Object root)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance and defaults for the remainings values.static EmbeddedStorageManager
start(Object root, File directory)
Deprecated.replaced bystart(Object,Path)
andstart(Object,ADirectory)
static EmbeddedStorageManager
start(Object root, Path directory)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance, the passed directory as its storage location and defaults for the remainings values.static EmbeddedStorageManager
start(Object root, ADirectory directory)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance, the passed directory as its storage location and defaults for the remainings values.static EmbeddedStorageManager
start(Object root, StorageConfiguration configuration)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance and the passedStorageConfiguration
.static EmbeddedStorageManager
start(Object root, StorageConfiguration.Builder<?> configuration)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance and the passedStorageConfiguration.Builder
to build itsStorageConfiguration
.static EmbeddedStorageManager
start(Object root, StorageConfiguration configuration, EmbeddedStorageConnectionFoundation<?> connectionFoundation)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance,StorageConfiguration
andEmbeddedStorageConnectionFoundation
.static EmbeddedStorageManager
start(Path directory)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed directory as its storage location and defaults for the remainings values.static EmbeddedStorageManager
start(ADirectory directory)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed directory as its storage location and defaults for the remainings values.static EmbeddedStorageManager
start(StorageConfiguration configuration)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passedStorageConfiguration
.static EmbeddedStorageManager
start(StorageConfiguration.Builder<?> configuration)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passedStorageConfiguration.Builder
to build itsStorageConfiguration
.static EmbeddedStorageManager
start(StorageConfiguration configuration, EmbeddedStorageConnectionFoundation<?> connectionFoundation)
Convenience method to configure, create and start aEmbeddedStorageManager
using the passedStorageConfiguration
andEmbeddedStorageConnectionFoundation
.
-
Constructor Details
-
EmbeddedStorage
public EmbeddedStorage()
-
-
Method Details
-
createFoundation
Creates an instance of anEmbeddedStorageFoundation
default implementation without any assembly parts set.- Returns:
- a new
EmbeddedStorageFoundation
instance.
-
ConnectionFoundation
public static final EmbeddedStorageConnectionFoundation<?> ConnectionFoundation(PersistenceTypeDictionaryIoHandler typeDictionaryIoHandler)Pseudo-constructor method to create a newEmbeddedStorageConnectionFoundation
instance using the passedPersistenceTypeDictionaryIoHandler
and default method references provided byPersistence
.Calls
ConnectionFoundation(PersistenceTypeDictionaryIoHandler,PersistenceTypeEvaluator)
withPersistence.isPersistable(Class)
method references as the other parameter.For explanations and customizing values, see
ConnectionFoundation(PersistenceTypeDictionaryIoHandler,PersistenceTypeEvaluator)
.- Parameters:
typeDictionaryIoHandler
- a logic instance to handle a type dictionary's IO operations.- Returns:
- a new
EmbeddedStorageConnectionFoundation
instance. - See Also:
ConnectionFoundation(ADirectory)
,ConnectionFoundation(PersistenceTypeDictionaryIoHandler,PersistenceTypeEvaluator)
,Persistence
-
ConnectionFoundation
public static final EmbeddedStorageConnectionFoundation<?> ConnectionFoundation(StorageConfiguration configuration, PersistenceTypeEvaluator typeEvaluatorPersistable) -
ConnectionFoundation
public static final EmbeddedStorageConnectionFoundation<?> ConnectionFoundation(ADirectory directory)Pseudo-constructor method to create a newEmbeddedStorageConnectionFoundation
instance using the passed directory and default method references provided byPersistence
.Calls
ConnectionFoundation(PersistenceTypeDictionaryIoHandler)
with aPersistenceTypeDictionaryIoHandler
instance constructed from the passed directory.- Parameters:
directory
- the directory where thePersistenceTypeDictionary
information will be stored.- Returns:
- a new
EmbeddedStorageConnectionFoundation
instance. - See Also:
ConnectionFoundation(PersistenceTypeDictionaryIoHandler)
,ConnectionFoundation(PersistenceTypeDictionaryIoHandler,PersistenceTypeEvaluator)
,Persistence
-
ConnectionFoundation
public static final EmbeddedStorageConnectionFoundation<?> ConnectionFoundation(PersistenceTypeDictionaryIoHandler typeDictionaryIoHandler, PersistenceTypeEvaluator typeEvaluatorPersistable)Pseudo-constructor method to create a newEmbeddedStorageConnectionFoundation
instance using the passed logic instances as its essential parts.- Parameters:
typeDictionaryIoHandler
- a logic instance to handle a type dictionary's IO operations.typeEvaluatorPersistable
- evaluator function to determine if instances of a type are persistable.- Returns:
- a new
EmbeddedStorageConnectionFoundation
instance. - See Also:
ConnectionFoundation(PersistenceTypeDictionaryIoHandler)
,ConnectionFoundation(ADirectory)
-
Foundation
Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using#defaultStorageDirectory()
as its storage directory and default values for itsStorageConfiguration
.Calls
ConnectionFoundation(ADirectory)
with#defaultStorageDirectory()
.- Returns:
- a new all-default
EmbeddedStorageFoundation
instance. - See Also:
Foundation(ADirectory)
,Foundation(StorageConfiguration)
,Foundation(StorageConfiguration.Builder)
,Foundation(StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
Foundation
Deprecated.replaced byFoundation(Path)
-
Foundation
-
Foundation
Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using the passed directory and default values for the remaining parts of itsStorageConfiguration
.Calls
Foundation(StorageConfiguration)
with a newly createdStorageConfiguration
using the passed directory as its storage location.- Parameters:
directory
- the directory where the storage will be located.- Returns:
- a new
EmbeddedStorageFoundation
instance using the passed storage directory. - See Also:
Foundation()
,Foundation(StorageConfiguration)
,Foundation(StorageConfiguration.Builder)
,Foundation(StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
Foundation
Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using the passedStorageConfiguration
.- Parameters:
configuration
- theStorageConfiguration
to be used.- Returns:
- a new
EmbeddedStorageFoundation
instance using the passed configuration. - See Also:
Foundation()
,Foundation(ADirectory)
,Foundation(StorageConfiguration.Builder)
,Foundation(StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
Foundation
public static final EmbeddedStorageFoundation<?> Foundation(StorageConfiguration.Builder<?> configuration)Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using the passedStorageConfiguration.Builder
to build itsStorageConfiguration
.This is merely a convenience alias for
Foundation(configuration.createConfiguration());
- Parameters:
configuration
- theStorageConfiguration.Builder
to be used.- Returns:
- a new
EmbeddedStorageFoundation
instance using the passed directory and configuration. - See Also:
Foundation()
,Foundation(Path)
,Foundation(StorageConfiguration)
,Foundation(StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
Foundation
public static final EmbeddedStorageFoundation<?> Foundation(StorageConfiguration configuration, EmbeddedStorageConnectionFoundation<?> connectionFoundation)Pseudo-constructor method to create a newEmbeddedStorageFoundation
instance using the passedStorageConfiguration
andEmbeddedStorageConnectionFoundation
.- Parameters:
configuration
- theStorageConfiguration
to be used.connectionFoundation
- theEmbeddedStorageConnectionFoundation
instance to be used for creating new connections, i.e. the context for issuing commands and storing and loading data.- Returns:
- a new
EmbeddedStorageFoundation
instance using the passed configuration. - See Also:
Foundation()
,Foundation(ADirectory)
,Foundation(StorageConfiguration)
,Foundation(StorageConfiguration.Builder)
-
start
Convenience method to configure, create and start aEmbeddedStorageManager
using purely default values.See
Foundation()
variants for more practical/configurable alternatives.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start(ADirectory)
,start(StorageConfiguration)
,start(StorageConfiguration.Builder)
,start(Object,one.microstream.storage.types.StorageConfiguration.Builder)
,start(StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
Deprecated.replaced bystart(Path)
-
start
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed directory as its storage location and defaults for the remainings values.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
directory
- the directory where the storage will be located.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start()
,start(StorageConfiguration)
,start(StorageConfiguration.Builder)
,start(StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed directory as its storage location and defaults for the remainings values.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
directory
- the directory where the storage will be located.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start()
,start(StorageConfiguration)
,start(StorageConfiguration.Builder)
,start(StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
Convenience method to configure, create and start aEmbeddedStorageManager
using the passedStorageConfiguration
.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
configuration
- theStorageConfiguration
to be used.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start()
,start(ADirectory)
,start(StorageConfiguration.Builder)
,start(StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
Convenience method to configure, create and start aEmbeddedStorageManager
using the passedStorageConfiguration.Builder
to build itsStorageConfiguration
.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
configuration
- theStorageConfiguration.Builder
to be used.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start()
,start(ADirectory)
,start(StorageConfiguration)
,start(StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
public static final EmbeddedStorageManager start(StorageConfiguration configuration, EmbeddedStorageConnectionFoundation<?> connectionFoundation)Convenience method to configure, create and start aEmbeddedStorageManager
using the passedStorageConfiguration
andEmbeddedStorageConnectionFoundation
.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
configuration
- theStorageConfiguration
to be used.connectionFoundation
- theEmbeddedStorageConnectionFoundation
to be used instead of a generically created one.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start()
,start(ADirectory)
,start(StorageConfiguration)
,start(StorageConfiguration.Builder)
-
start
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance and defaults for the remainings values.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
root
- the explicitely defined root instance of the persistent entity graph.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start(Object,ADirectory)
,start(Object,StorageConfiguration)
,start(Object,StorageConfiguration.Builder)
,start(Object,StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
Deprecated.replaced bystart(Object,Path)
andstart(Object,ADirectory)
-
start
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance, the passed directory as its storage location and defaults for the remainings values.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
root
- the explicitely defined root instance of the persistent entity graph.directory
- the directory where the storage will be located.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start(Object)
,start(Object,StorageConfiguration)
,start(Object,StorageConfiguration.Builder)
,start(Object,StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance, the passed directory as its storage location and defaults for the remainings values.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
root
- the explicitely defined root instance of the persistent entity graph.directory
- the directory where the storage will be located.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start(Object)
,start(Object,StorageConfiguration)
,start(Object,StorageConfiguration.Builder)
,start(Object,StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance and the passedStorageConfiguration
.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
root
- the explicitely defined root instance of the persistent entity graph.configuration
- theStorageConfiguration
to be used.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start(Object)
,start(Object,ADirectory)
,start(Object,StorageConfiguration.Builder)
,start(Object,StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
public static final EmbeddedStorageManager start(Object root, StorageConfiguration.Builder<?> configuration)Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance and the passedStorageConfiguration.Builder
to build itsStorageConfiguration
.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
root
- the explicitely defined root instance of the persistent entity graph.configuration
- theStorageConfiguration.Builder
to be used.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start(Object)
,start(Object,ADirectory)
,start(Object,StorageConfiguration)
,start(Object,StorageConfiguration,EmbeddedStorageConnectionFoundation)
-
start
public static final EmbeddedStorageManager start(Object root, StorageConfiguration configuration, EmbeddedStorageConnectionFoundation<?> connectionFoundation)Convenience method to configure, create and start aEmbeddedStorageManager
using the passed root as the persistent entity graph's root instance,StorageConfiguration
andEmbeddedStorageConnectionFoundation
.See
Foundation()
variants for more practical/configurable alternatives.- Parameters:
root
- the explicitely defined root instance of the persistent entity graph.configuration
- theStorageConfiguration
to be used.connectionFoundation
- theEmbeddedStorageConnectionFoundation
to be used instead of agenerically created one.- Returns:
- an
EmbeddedStorageManager
instance connected to an actively running database. - See Also:
start(Object)
,start(Object,ADirectory)
,start(Object,StorageConfiguration)
,start(Object,StorageConfiguration.Builder)
-