Package | Description |
---|---|
com.speedment.runtime.application |
The runtime application package of Speedment.
|
com.speedment.runtime.config |
The configuration system is located in this package.
|
com.speedment.runtime.config.mutator |
Implementations of the
DocumentMutator
interface that help modify a Document in a
type-safe manner are located in this package. |
com.speedment.runtime.config.trait |
Common traits used in the typed configuration documents are located in this
package.
|
com.speedment.runtime.config.util |
Utility methods for this module.
|
com.speedment.runtime.core |
The base package of Speedment.
|
Modifier and Type | Method and Description |
---|---|
<C extends Document & HasEnabled> |
AbstractApplicationBuilder.with(Class<C> type,
BiConsumer<com.speedment.common.injector.Injector,C> consumer) |
<C extends Document & HasEnabled> |
AbstractApplicationBuilder.with(Class<C> type,
Consumer<C> consumer) |
<C extends Document & HasEnabled> |
AbstractApplicationBuilder.with(Class<C> type,
String name,
BiConsumer<com.speedment.common.injector.Injector,C> consumer) |
Modifier and Type | Interface and Description |
---|---|
interface |
Column
A typed
Document that represents a column in the database. |
interface |
Dbms
A typed
Document that represents a dbms instance in the database. |
interface |
ForeignKey
A typed
Document that represents a foreign key instance in the
database. |
interface |
ForeignKeyColumn
A typed
Document that represents the column referenced by a foreign
key instance in the database. |
interface |
Index
A typed
Document that represents an index instance in the database. |
interface |
IndexColumn
A typed
Document that represents the column referenced by an index
key instance in the database. |
interface |
PrimaryKeyColumn
A typed
Document that represents the primary key column instance in
the database. |
interface |
Project
A typed
Document that represents a database project. |
interface |
Schema
A typed
Document that represents a schema instance in the database. |
interface |
Table
A typed
Document that represents a table instance in the database. |
Modifier and Type | Method and Description |
---|---|
default <P extends Document,T extends Document> |
Document.children(String key,
BiFunction<P,Map<String,Object>,T> constructor)
Returns the children on the specified key, instantiated using the
specified constructor.
|
default <P extends Document,T extends Document> |
Document.children(String key,
BiFunction<P,Map<String,Object>,T> constructor)
Returns the children on the specified key, instantiated using the
specified constructor.
|
Modifier and Type | Method and Description |
---|---|
default Stream<Document> |
Document.ancestors()
Returns a
Stream of every ancestor to this Document ,
beginning with the first ancestor (the root) and ending with the parent
of this Document . |
Stream<? extends Document> |
Document.children()
Returns a
Stream of child documents, instantiated using the
default document implementation. |
Optional<? extends Document> |
Document.getParent()
Returns the parent of this Document or
Optional.empty() if the
Document does not have a parent. |
Modifier and Type | Interface and Description |
---|---|
interface |
DocumentMutator<DOC extends Document> |
Modifier and Type | Interface and Description |
---|---|
interface |
HasParent<PARENT extends Document>
Trait for
Document implementations that is not the root. |
Modifier and Type | Interface and Description |
---|---|
interface |
HasAlias
Trait for
Document implementations that implement the
HasAlias.getAlias() method. |
interface |
HasChildren
Trait for
Document implementations that has named children and
therefore implements the defaultNameFor(Document) method. |
interface |
HasColumn
Trait for
Document implementations that reference another
Column document and therefore has a HasColumn.findColumn() method. |
interface |
HasColumnSize
A trait for documents that contains column size information.
|
interface |
HasDecimalDigits
A trait for documents that contains decimal digits information.
|
interface |
HasEnabled
Trait for
Document implementations that implement the
HasEnabled.isEnabled() method. |
interface |
HasEnumConstants
A trait for
documents that implement the
HasEnumConstants.getEnumConstants() method. |
interface |
HasId
Trait for
Document implementations that implement the
HasId.getId() method. |
interface |
HasMainInterface
A trait for
documents that implement the
HasMainInterface.mainInterface() method. |
interface |
HasName
Trait for
Document implementations that implement the
HasName.getName() method. |
interface |
HasNullable
Trait for
Document implementations that implement the
HasNullable.isNullable() method. |
interface |
HasOrderType
Trait for
Document implementations that implement the
HasOrderType.getOrderType() method. |
interface |
HasOrdinalPosition
Trait for
Document implementations that implement the
HasOrdinalPosition.getOrdinalPosition() method. |
interface |
HasPackageName |
interface |
HasParent<PARENT extends Document>
Trait for
Document implementations that is not the root. |
interface |
HasTypeMapper
Trait for documents that have a
TypeMapper specified. |
Modifier and Type | Method and Description |
---|---|
default <C extends Document & HasName & HasMainInterface> |
HasChildren.defaultNameFor(C childDocument)
Generates a new default name for the specified child by appending an
unique number to the
HasMainInterface.mainInterface() of that
document. |
Modifier and Type | Method and Description |
---|---|
Class<? extends Document> |
HasMainInterface.mainInterface()
Returns the
Class of the interface of this node. |
Modifier and Type | Method and Description |
---|---|
static HasOrdinalPosition |
HasOrdinalPosition.of(Document document)
Returns a wrapper of the specified document that implements the
HasOrdinalPosition trait. |
static HasEnabled |
HasEnabled.of(Document document)
Returns a wrapper of the specified document that implements the
HasEnabled trait. |
static HasColumn |
HasColumn.of(Document document)
Returns a wrapper of the specified document that implements the
HasColumn trait. |
static HasNullable |
HasNullable.of(Document document)
Returns a wrapper of the specified document that implements the
HasNullable trait. |
static HasName |
HasName.of(Document document)
Returns a wrapper of the specified document that implements the
HasName trait. |
static HasPackageName |
HasPackageName.of(Document document)
Returns a wrapper of the specified document that implements the
HasPackageName trait. |
static HasId |
HasId.of(Document document)
Returns a wrapper of the specified document that implements the
HasId trait. |
static HasAlias |
HasAlias.of(Document document)
Returns a wrapper of the specified document that implements the
HasAlias trait. |
static HasOrderType |
HasOrderType.of(Document document)
Returns a wrapper of the specified document that implements the
HasOrderType trait. |
static boolean |
HasEnabled.test(Document doc)
|
Modifier and Type | Method and Description |
---|---|
static <E extends Document> |
DocumentUtil.ancestor(Document document,
Class<E> clazz)
Returns the first ancestor found of the specified type to the specified
document when walking up the tree.
|
static <E extends Document> |
DocumentUtil.childrenOf(Document document,
BiFunction<Document,Map<String,Object>,E> childConstructor)
Returns a stream of child documents to a specified document by using the
supplied constructor.
|
static <P extends Document,DOC extends Document & HasParent<P>> |
DocumentUtil.deepCopy(DOC document,
BiFunction<P,Map<String,Object>,DOC> constructor)
Creates a deep copy of the raw map in the specified document and wrap it
in a new typed document using the specified constructor.
|
static <P extends Document,DOC extends Document & HasParent<P>> |
DocumentUtil.deepCopy(DOC document,
BiFunction<P,Map<String,Object>,DOC> constructor)
Creates a deep copy of the raw map in the specified document and wrap it
in a new typed document using the specified constructor.
|
static <DOC extends Document> |
DocumentUtil.deepCopy(DOC document,
Function<Map<String,Object>,DOC> constructor)
Creates a deep copy of the raw map in the specified document and wrap it
in a new typed document using the specified constructor.
|
static <T extends Document & HasName,D extends Document & HasName> |
DocumentUtil.relativeName(D document,
Class<T> from,
DocumentUtil.Name name)
Returns the relative name for the given Document up to the point given by
the parent Class.
|
static <T extends Document & HasName,D extends Document & HasName> |
DocumentUtil.relativeName(D document,
Class<T> from,
DocumentUtil.Name name)
Returns the relative name for the given Document up to the point given by
the parent Class.
|
static <T extends Document & HasName,D extends Document & HasName> |
DocumentUtil.relativeName(D document,
Class<T> from,
DocumentUtil.Name name,
CharSequence separator,
Function<String,String> nameMapper)
Returns the relative name for the given Document up to the point given by
the parent Class by successively applying the provided nameMapper onto
the Node names and separating the names with the provided separator.
|
static <T extends Document & HasName,D extends Document & HasName> |
DocumentUtil.relativeName(D document,
Class<T> from,
DocumentUtil.Name name,
CharSequence separator,
Function<String,String> nameMapper)
Returns the relative name for the given Document up to the point given by
the parent Class by successively applying the provided nameMapper onto
the Node names and separating the names with the provided separator.
|
static <T extends Document & HasName,D extends Document & HasName> |
DocumentUtil.relativeName(D document,
Class<T> from,
DocumentUtil.Name name,
Function<String,String> nameMapper)
Returns the relative name for the given Document up to the point given by
the parent Class by successively applying the provided nameMapper onto
the Node names.
|
static <T extends Document & HasName,D extends Document & HasName> |
DocumentUtil.relativeName(D document,
Class<T> from,
DocumentUtil.Name name,
Function<String,String> nameMapper)
Returns the relative name for the given Document up to the point given by
the parent Class by successively applying the provided nameMapper onto
the Node names.
|
static <TRAIT extends Document> |
TraitUtil.viewOf(Document document,
Class<TRAIT> trait,
TraitUtil.TraitViewConstructor<? extends TRAIT> constructor)
Returns a view of the specified document that implements the specified
trait.
|
Modifier and Type | Method and Description |
---|---|
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(Column column) |
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(Dbms dbms) |
static Stream<? extends Document> |
DocumentUtil.traverseOver(Document document)
Traverses all the documents at and below the specified document in a
tree.
|
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(ForeignKey foreignKey) |
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(ForeignKeyColumn foreignKeyColumn) |
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(Index index) |
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(IndexColumn indexColumn) |
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(PrimaryKeyColumn primaryKeyColumn) |
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(Project project) |
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(Schema schema) |
static Stream<? extends Document> |
DocumentDbUtil.traverseOver(Table table) |
static Stream<? extends Document> |
DocumentDbUtil.typedChildrenOf(Table table) |
Modifier and Type | Method and Description |
---|---|
static <E extends Document> |
DocumentUtil.ancestor(Document document,
Class<E> clazz)
Returns the first ancestor found of the specified type to the specified
document when walking up the tree.
|
static <E extends Document> |
DocumentUtil.childrenOf(Document document,
BiFunction<Document,Map<String,Object>,E> childConstructor)
Returns a stream of child documents to a specified document by using the
supplied constructor.
|
TRAIT |
TraitUtil.TraitViewConstructor.create(Document parent,
Map<String,Object> data,
Class<? extends Document> mainInterface) |
static boolean |
DocumentDbUtil.isAllAncestorsEnabled(Document document)
Returns
true if the specified document and all its ancestors are
enabled. |
static Map<String,Object> |
DocumentUtil.newDocument(Document parent,
String key)
Creates and returns a new raw map on a specified key in the specified
document.
|
static Supplier<NoSuchElementException> |
DocumentUtil.newNoSuchElementExceptionFor(Document document,
String key)
Returns an
Exception supplier for when no attribute could be
found on a specified key in a specified document. |
static String |
DocumentUtil.toStringHelper(Document document)
Helps documents to format a
toString() -method. |
static Stream<? extends Document> |
DocumentUtil.traverseOver(Document document)
Traverses all the documents at and below the specified document in a
tree.
|
static <TRAIT extends Document> |
TraitUtil.viewOf(Document document,
Class<TRAIT> trait,
TraitUtil.TraitViewConstructor<? extends TRAIT> constructor)
Returns a view of the specified document that implements the specified
trait.
|
Modifier and Type | Method and Description |
---|---|
static <E extends Document> |
DocumentUtil.childrenOf(Document document,
BiFunction<Document,Map<String,Object>,E> childConstructor)
Returns a stream of child documents to a specified document by using the
supplied constructor.
|
TRAIT |
TraitUtil.TraitViewConstructor.create(Document parent,
Map<String,Object> data,
Class<? extends Document> mainInterface) |
Modifier and Type | Method and Description |
---|---|
<C extends Document & HasEnabled> |
ApplicationBuilder.with(Class<C> type,
BiConsumer<com.speedment.common.injector.Injector,C> consumer)
Configures a parameter for all
Document of a certain class. |
<C extends Document & HasEnabled> |
ApplicationBuilder.with(Class<C> type,
Consumer<C> consumer)
Configures a parameter for all
Document of a certain class. |
<C extends Document & HasEnabled> |
ApplicationBuilder.with(Class<C> type,
String name,
BiConsumer<com.speedment.common.injector.Injector,C> consumer)
Configures a parameter for the named
Document of a certain class. |
default <C extends Document & HasEnabled> |
ApplicationBuilder.with(Class<C> type,
String name,
Consumer<C> consumer)
Configures a parameter for the named
Document of a certain class. |
Copyright © 2018 Speedment, Inc.. All rights reserved.