Uses of Class
de.odrotbohm.spring.web.model.MappedPayloads.MappedErrors
Packages that use MappedPayloads.MappedErrors
-
Uses of MappedPayloads.MappedErrors in de.odrotbohm.spring.web.model
Subclasses of MappedPayloads.MappedErrors in de.odrotbohm.spring.web.modelModifier and TypeClassDescriptionstatic classA monadic type to work with a mapped payload alongsideErrorsto build up pipelines to eventually result in anHttpEntitybased on the processing steps.Methods in de.odrotbohm.spring.web.model that return MappedPayloads.MappedErrorsModifier and TypeMethodDescriptionstatic MappedPayloads.MappedErrorsMappedPayloads.of(org.springframework.validation.Errors errors) Creates a newMappedPayloads.MappedErrorsfrom the givenErrorsinstance.MappedPayloads.MappedErrors.onErrors(Function<org.springframework.validation.Errors, org.springframework.http.ResponseEntity<?>> callback) MappedPayloads.MappedErrors.peekErrors(Consumer<org.springframework.validation.Errors> errors) Allows to peek at the currentErrorsinstance.MappedPayloads.MappedErrors.rejectField(boolean condition, String field, String errorCode) Rejects the field with the given name with the given error code if the given condition is true.MappedPayloads.MappedErrors.rejectField(boolean condition, String field, String errorCode, Function<org.springframework.validation.Errors, org.springframework.http.ResponseEntity<?>> errorHandler) Rejects the field with the given name with the given error code if the given condition is true.MappedPayloads.MappedErrors.rejectField(String field, String errorCode) Rejects the field of the given name with the given error code.MappedPayloads.MappedErrors.rejectField(String field, String errorCode, String defaultMessage) Rejects the field with the given name with the given error code and default message.Method parameters in de.odrotbohm.spring.web.model with type arguments of type MappedPayloads.MappedErrorsModifier and TypeMethodDescriptionorg.springframework.http.HttpEntity<?>MappedPayloads.MappedPayload.concludeSelfIfValid(BiFunction<? super T, MappedPayloads.MappedErrors, ? extends org.springframework.http.ResponseEntity<?>> finalizer) Concludes the processing of the current payload with the given finalizer, but automatically produces an error response via the callbacks registered forMappedPayloads.MappedPayload.onErrors(java.util.function.Function<org.springframework.validation.Errors, org.springframework.http.ResponseEntity<?>>)andMappedPayloads.MappedPayload.onAbsence.