public class MongoItemWriterBuilder<T>
extends java.lang.Object
MongoItemWriter
MongoItemWriter
Constructor and Description |
---|
MongoItemWriterBuilder() |
Modifier and Type | Method and Description |
---|---|
MongoItemWriter<T> |
build()
Validates and builds a
MongoItemWriter . |
MongoItemWriterBuilder<T> |
collection(java.lang.String collection)
Set the name of the Mongo collection to be written to.
|
MongoItemWriterBuilder<T> |
delete(boolean delete)
Indicates if the items being passed to the writer are to be saved or removed from
the data store.
|
MongoItemWriterBuilder<T> |
template(org.springframework.data.mongodb.core.MongoOperations template)
Set the
MongoOperations to be used to save items to be written. |
public MongoItemWriterBuilder<T> delete(boolean delete)
delete
- removal indicatorMongoItemWriter.setDelete(boolean)
public MongoItemWriterBuilder<T> template(org.springframework.data.mongodb.core.MongoOperations template)
MongoOperations
to be used to save items to be written.template
- the template implementation to be used.MongoItemWriter.setTemplate(MongoOperations)
public MongoItemWriterBuilder<T> collection(java.lang.String collection)
collection
- the name of the collection.MongoItemWriter.setCollection(String)
public MongoItemWriter<T> build()
MongoItemWriter
.MongoItemWriter