Interface JacksonRequireThat
- All Known Subinterfaces:
JacksonValidators
public interface JacksonRequireThat
Creates validators for the Jackson API that throw exceptions immediately on validation failure.
-
Method Summary
Modifier and TypeMethodDescription<T extends JsonNode>
JsonNodeValidator<T> requireThat
(T value, String name) Validates the state of aJsonNode
.
-
Method Details
-
requireThat
Validates the state of aJsonNode
.The returned validator throws an exception immediately if a validation fails.
- Type Parameters:
T
- the type of theJsonNode
- Parameters:
value
- the valuename
- the name of the value- Returns:
- a validator for the value
- Throws:
NullPointerException
- ifname
is nullIllegalArgumentException
- ifname
contains whitespace, or is empty
-