Interface ExecutableInsertOperation
- All Known Subinterfaces:
FluentMongoOperations
,MongoOperations
- All Known Implementing Classes:
MongoTemplate
public interface ExecutableInsertOperation
ExecutableInsertOperation
allows creation and execution of MongoDB insert and bulk insert operations in a
fluent API style. The collection to operate on is by default derived from the initial domainType and can be defined there via
Document
. Using inCollection
allows to override the
collection name for the execution.
insert(Jedi.class)
.inCollection("star-wars")
.one(luke);
- Since:
- 2.0
- Author:
- Christoph Strobl, Mark Paluch
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic interface
static interface
static interface
Collection override (optional).static interface
Trigger bulk insert execution by calling one of the terminating methods.static interface
Trigger insert execution by calling one of the terminating methods. -
Method Summary
Modifier and TypeMethodDescriptionStart creating an insert operation for given domainType.
-
Method Details
-
insert
Start creating an insert operation for given domainType.- Parameters:
domainType
- must not be null.- Returns:
- new instance of
ExecutableInsertOperation.ExecutableInsert
. - Throws:
IllegalArgumentException
- if domainType is null.
-