public final class DependenciesKeywordValidator extends KeywordValidator
dependencies keyword
This validator covers both property dependencies and schema dependencies.
| Modifier and Type | Field and Description |
|---|---|
private static Joiner |
DEP_JOINER |
private Map<String,JsonNode> |
schemas
Map of schema dependencies
|
private SetMultimap<String,String> |
simple
Map of simple dependencies (ie, property dependencies)
|
keyword, nodeFactory| Constructor and Description |
|---|
DependenciesKeywordValidator(JsonNode schema) |
| Modifier and Type | Method and Description |
|---|---|
private void |
computeSimpleDep(String field,
Set<String> fields,
ValidationReport report) |
private String |
schemasToString() |
String |
toString() |
void |
validate(ValidationContext context,
ValidationReport report,
JsonNode instance)
Method which all keyword validators must implement
|
newMsg, validateInstanceprivate static final Joiner DEP_JOINER
private final SetMultimap<String,String> simple
public DependenciesKeywordValidator(JsonNode schema)
public void validate(ValidationContext context, ValidationReport report, JsonNode instance)
KeywordValidatorvalidate in class KeywordValidatorcontext - the contextreport - the validation reportinstance - the instance to validateprivate void computeSimpleDep(String field, Set<String> fields, ValidationReport report)
public String toString()
toString in class KeywordValidatorprivate String schemasToString()
Copyright © 2012. All Rights Reserved.