Package fr.ght1pc9kc.testy.mongo
Class WithMongoData.WithMongoDataBuilder
java.lang.Object
fr.ght1pc9kc.testy.mongo.WithMongoData.WithMongoDataBuilder
- Enclosing class:
- WithMongoData
Builder for the extension class
WithMongoData
.-
Method Summary
Modifier and TypeMethodDescriptionaddDataset
(String collectionName, MongoDataSet<?> dataSet) Add a data set.build()
Build the extension.withObjectMapper
(WithObjectMapper wObjectMapper) Add a customized object mapper to convert the objects to documents.
-
Method Details
-
withObjectMapper
Add a customized object mapper to convert the objects to documents.- Parameters:
wObjectMapper
- TheWithObjectMapper
extension to map the documents.- Returns:
- Builder instance.
-
addDataset
public WithMongoData.WithMongoDataBuilder addDataset(String collectionName, MongoDataSet<?> dataSet) Add a data set.- Parameters:
collectionName
- Name of the collection the data-set will fill.dataSet
- Set of data to initialize the collection with.- Returns:
- Builder instance.
-
build
Build the extension.- Returns:
- The built
WithMongoData
extension.
-