Package org.topbraid.shacl.validation
Interface ValidationSuggestionGenerator
-
public interface ValidationSuggestionGeneratorAn interface for objects that can produce suggestions for a given results graph.- Author:
- Holger Knublauch
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intaddSuggestions(org.apache.jena.rdf.model.Model results, int maxCount, Function<org.apache.jena.rdf.model.RDFNode,String> labelFunction)Adds dash:suggestion triples for all result resource in the given results Model.intaddSuggestions(org.apache.jena.rdf.model.Resource result, int maxCount, Function<org.apache.jena.rdf.model.RDFNode,String> labelFunction)Adds dash:suggestion triples for a given result resource.booleancanHandle(org.apache.jena.rdf.model.Resource result)Checks if this is (in principle) capable of adding suggestions for a given result.
-
-
-
Method Detail
-
addSuggestions
int addSuggestions(org.apache.jena.rdf.model.Model results, int maxCount, Function<org.apache.jena.rdf.model.RDFNode,String> labelFunction)Adds dash:suggestion triples for all result resource in the given results Model.- Parameters:
results- the results ModelmaxCount- the maximum number of suggestions to produce per resultlabelFunction- an optional function producing labels of nodes- Returns:
- the number of suggestions that were created
-
addSuggestions
int addSuggestions(org.apache.jena.rdf.model.Resource result, int maxCount, Function<org.apache.jena.rdf.model.RDFNode,String> labelFunction)Adds dash:suggestion triples for a given result resource.- Parameters:
result- the sh:ValidationResult to add the suggestions tomaxCount- the maximum number of suggestions to producelabelFunction- an optional function producing labels of nodes- Returns:
- the number of suggestions that were created
-
canHandle
boolean canHandle(org.apache.jena.rdf.model.Resource result)
Checks if this is (in principle) capable of adding suggestions for a given result.- Parameters:
result- the validation result- Returns:
- true if this can
-
-