Package com.networknt.schema.annotation
Class AnnotationPredicate
java.lang.Object
com.networknt.schema.annotation.AnnotationPredicate
- All Implemented Interfaces:
Predicate<Annotation>
A predicate for filtering annotations.
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAnnotationPredicate(Predicate<NodePath> instanceLocationPredicate, Predicate<NodePath> evaluationPathPredicate, Predicate<SchemaLocation> schemaLocationPredicate, Predicate<String> keywordPredicate, Predicate<Object> valuePredicate) Initialize a new instance of this class. -
Method Summary
Modifier and TypeMethodDescriptionstatic AnnotationPredicate.Builderbuilder()Creates a new builder to create the predicate.Gets the predicate to filter on evaluationPath.Gets the predicate to filter on instanceLocation.Gets the predicate to filter on keyword.Gets the predicate to filter on schemaLocation.Gets the predicate to filter on value.booleantest(Annotation t)
-
Constructor Details
-
AnnotationPredicate
protected AnnotationPredicate(Predicate<NodePath> instanceLocationPredicate, Predicate<NodePath> evaluationPathPredicate, Predicate<SchemaLocation> schemaLocationPredicate, Predicate<String> keywordPredicate, Predicate<Object> valuePredicate) Initialize a new instance of this class.- Parameters:
instanceLocationPredicate- for instanceLocationevaluationPathPredicate- for evaluationPathschemaLocationPredicate- for schemaLocationkeywordPredicate- for keywordvaluePredicate- for value
-
-
Method Details
-
test
- Specified by:
testin interfacePredicate<Annotation>
-
getInstanceLocationPredicate
Gets the predicate to filter on instanceLocation.- Returns:
- the predicate
-
getEvaluationPathPredicate
Gets the predicate to filter on evaluationPath.- Returns:
- the predicate
-
getSchemaLocationPredicate
Gets the predicate to filter on schemaLocation.- Returns:
- the predicate
-
getKeywordPredicate
Gets the predicate to filter on keyword.- Returns:
- the predicate
-
getValuePredicate
Gets the predicate to filter on value.- Returns:
- the predicate
-
builder
Creates a new builder to create the predicate.- Returns:
- the builder
-