See: Description
Interface | Description |
---|---|
BlueprintsResourceOptions |
PersistentResourceOptions that hold Blueprints related resource-level features, such as the Blueprints
implementation used or the autocommit chunk size. |
Class | Description |
---|---|
AbstractBlueprintsOptions |
An abstract
PersistenceOptions that holds generic options for all Blueprints based implementations. |
AbstractBlueprintsOptionsBuilder<B extends AbstractBlueprintsOptionsBuilder<B,O>,O extends AbstractBlueprintsOptions> |
An abstract
PersistenceOptionsBuilder that provides utility methods to create generic Blueprints options. |
BlueprintsOptions |
A
PersistenceOptions that holds Blueprints TinkerGraph specific options. |
BlueprintsOptionsBuilder |
A
PersistenceOptionsBuilder that creates Blueprints TinkerGraph specific options. |
Enum | Description |
---|---|
BlueprintsStoreOptions |
PersistentStoreOptions that hold Blueprints related database access features, such as autocommit or direct
write behavior. |
This package defines two APIs extending PersistentResourceOptions
and PersistenceOptionsBuilder
:
BlueprintsResourceOptions
:
defines generic Blueprints options (not tailored to a specific graph implementation), such as the automatic commit of
pending transaction, and the default graph backend to use. Blueprints specific options can be combined with generic
options defined in PersistentResourceOptions
BlueprintsOptionsBuilder
: a fluent API allowing to easily set
Blueprints specific options in client applications. Since the builder implements PersistenceOptionsBuilder
it can be used to combine Blueprints specific and generic
options.
Options defined using the classes inside this package are usable for each Blueprints implementation. For
backend-specific configuration refers to the corresponding package in the backend plugin (fr.inria.atlanmod.neoemf.data.blueprints.[backend]
).
These classes are used to create option maps used in EMF save and load methods. For example, the following code creates a map that tells the framework to use a direct write approach (meaning that modifications are directly stored in the underlying database) and cache the accessed features to retrieve them efficiently. The direct write behavior is a Blueprints specific option, while the caching behavior is defined at the core level.
// Create the option map
Map<String, Object> options = BlueprintsOptionsBuilder.newBuilder()
.directWrite()
.cacheFeatures()
.asMap();
// Load the resource with the specified options
myResource.load(options);
// Manipulate the resource with a direct write approach and feature cache enabled
myResource.getContents() [...]
Copyright © 2013–2017 Atlanmod INRIA LINA Mines Nantes. All rights reserved.