T
- Class of the request to be handled, currently Buffer and JsonObjectpublic abstract class DbRequestParametersBuilder<T>
extends java.lang.Object
Builder to ease the creation of DbRequestParameters objects Builder for DbRequests
DbRequestParameters = new DbRequestParametersBuilder()
.db(aNotesDB)
.factory(KeepFactory)
.incoming(someJson)
.session(KeepSession)
.observer(someObserver)
.validator(aFunction)
.build();
Instead of validator(aFunction)
we have some alternative methods to configure the validation (see below)
Constructor and Description |
---|
DbRequestParametersBuilder() |
Modifier and Type | Method and Description |
---|---|
DbRequestParameters<T> |
build() |
DbRequestParametersBuilder<T> |
client(com.hcl.domino.DominoClient dominoClient) |
DbRequestParametersBuilder<T> |
db(com.hcl.domino.data.Database dominoDb) |
DbRequestParametersBuilder<T> |
factory(KeepFactory incomingFactory) |
DbRequestParametersBuilder<T> |
incoming(io.vertx.core.json.JsonObject incomingJson) |
DbRequestParametersBuilder<T> |
observer(io.reactivex.Observer<T> observer) |
DbRequestParametersBuilder<T> |
session(KeepJnxSession incomingSession) |
DbRequestParametersBuilder<T> |
skipValidation()
Shortcut function for a non-validating DBRequest
|
DbRequestParametersBuilder<T> |
validator(java.util.function.Predicate<io.vertx.core.json.JsonObject> incomingValidator) |
abstract DbRequestParametersBuilder<T> |
validatorFromEventBusId(java.lang.String eventBusId,
java.util.function.Predicate<io.vertx.core.json.JsonObject> customValidator) |
abstract DbRequestParametersBuilder<T> |
validatorFromEventBusId(java.lang.String eventBusId,
java.util.function.Predicate<io.vertx.core.json.JsonObject> customValidator,
io.reactivex.Observer<T> observer) |
abstract DbRequestParametersBuilder<T> |
validatorFromEventBusId(java.lang.String eventBusId,
java.util.function.Predicate<io.vertx.core.json.JsonObject> customValidator,
io.reactivex.Observer<T> observer,
boolean failIfMissing) |
public DbRequestParameters<T> build() throws KeepExceptionMissingParameters
KeepExceptionMissingParameters
public DbRequestParametersBuilder<T> client(@Nonnull com.hcl.domino.DominoClient dominoClient)
dominoClient
- Domino clientpublic DbRequestParametersBuilder<T> db(@Nonnull com.hcl.domino.data.Database dominoDb)
dominoDb
- Domino databasepublic DbRequestParametersBuilder<T> factory(@Nonnull KeepFactory incomingFactory)
incomingFactory
- Keep sessionpublic DbRequestParametersBuilder<T> incoming(@Nonnull io.vertx.core.json.JsonObject incomingJson)
incomingJson
- Json Payload params/bodypublic DbRequestParametersBuilder<T> observer(@Nonnull io.reactivex.Observer<T> observer)
observer
- destination for resultspublic DbRequestParametersBuilder<T> session(@Nonnull KeepJnxSession incomingSession)
incomingSession
- Keep sessionpublic DbRequestParametersBuilder<T> skipValidation()
Shortcut function for a non-validating DBRequest
public DbRequestParametersBuilder<T> validator(@Nonnull java.util.function.Predicate<io.vertx.core.json.JsonObject> incomingValidator)
incomingValidator
- public abstract DbRequestParametersBuilder<T> validatorFromEventBusId(java.lang.String eventBusId, java.util.function.Predicate<io.vertx.core.json.JsonObject> customValidator) throws KeepExceptionMissingParameters
eventBusId
- customValidator
- KeepExceptionMissingParameters
- public abstract DbRequestParametersBuilder<T> validatorFromEventBusId(java.lang.String eventBusId, java.util.function.Predicate<io.vertx.core.json.JsonObject> customValidator, io.reactivex.Observer<T> observer) throws KeepExceptionMissingParameters
eventBusId
- customValidator
- observer
- KeepExceptionMissingParameters
public abstract DbRequestParametersBuilder<T> validatorFromEventBusId(java.lang.String eventBusId, java.util.function.Predicate<io.vertx.core.json.JsonObject> customValidator, io.reactivex.Observer<T> observer, boolean failIfMissing) throws KeepExceptionMissingParameters
eventBusId
- customValidator
- observer
- failIfMissing
- KeepExceptionMissingParameters