public interface Validator
Modifier and Type | Method and Description |
---|---|
org.eclipse.lyo.shacl.ValidationReport |
validate(org.eclipse.lyo.oslc4j.core.model.AbstractResource resource)
Validate a single resource against the shape based on its class annotations.
|
org.eclipse.lyo.shacl.ValidationReport |
validate(org.apache.jena.rdf.model.Model dataModel,
Class<? extends org.eclipse.lyo.oslc4j.core.model.AbstractResource> clazz)
Validate
dataModel against the Shape that is constructed from
the shape annotations in the resource class passed in the
clazz variable. |
org.eclipse.lyo.shacl.ValidationReport |
validate(org.apache.jena.rdf.model.Model dataModel,
org.apache.jena.rdf.model.Model shapeModel)
Validate.
|
org.eclipse.lyo.shacl.ValidationReport validate(org.eclipse.lyo.oslc4j.core.model.AbstractResource resource) throws org.eclipse.lyo.oslc4j.core.exception.OslcCoreApplicationException, URISyntaxException, ParseException, IllegalAccessException, IllegalArgumentException, InvocationTargetException, DatatypeConfigurationException, InstantiationException, SecurityException, NoSuchMethodException
resource
- Resource to be validatedValidationReport
NoSuchMethodException
SecurityException
InstantiationException
org.eclipse.lyo.oslc4j.core.exception.OslcCoreApplicationException
URISyntaxException
ParseException
IllegalAccessException
IllegalArgumentException
InvocationTargetException
DatatypeConfigurationException
ShaclShapeFactory.createShaclShape(Class)
org.eclipse.lyo.shacl.ValidationReport validate(org.apache.jena.rdf.model.Model dataModel, org.apache.jena.rdf.model.Model shapeModel) throws IllegalAccessException, InvocationTargetException, DatatypeConfigurationException, org.eclipse.lyo.oslc4j.core.exception.OslcCoreApplicationException, IllegalArgumentException, InstantiationException, SecurityException, NoSuchMethodException, URISyntaxException
This method takes JenaModels as parameters, validates the dataModel against shapeModel and return the ValidationResultModel
It iterates on all the resources with in the dataModel
and returns all the errors
found in all resources.
dataModel
- the data modelshapeModel
- the shape modelValidationReport
IllegalAccessException
- the illegal access exceptionInvocationTargetException
- the invocation target exceptionDatatypeConfigurationException
- the datatype configuration exceptionorg.eclipse.lyo.oslc4j.core.exception.OslcCoreApplicationException
- the oslc core application exceptionURISyntaxException
NoSuchMethodException
SecurityException
InstantiationException
IllegalArgumentException
org.eclipse.lyo.shacl.ValidationReport validate(org.apache.jena.rdf.model.Model dataModel, Class<? extends org.eclipse.lyo.oslc4j.core.model.AbstractResource> clazz) throws IllegalAccessException, IllegalArgumentException, InvocationTargetException, DatatypeConfigurationException, org.eclipse.lyo.oslc4j.core.exception.OslcCoreApplicationException, URISyntaxException, ParseException, InstantiationException, SecurityException, NoSuchMethodException
dataModel
against the Shape
that is constructed from
the shape annotations in the resource class passed in the
clazz
variable. The target is set to the class type of the resource class.
It iterates on all the resources with in the dataModel
and returns all
the errors in each resource.
dataModel
- Data model to be validatedclazz
- Resource class with shape annotationsValidationReport
NoSuchMethodException
SecurityException
InstantiationException
IllegalAccessException
IllegalArgumentException
InvocationTargetException
DatatypeConfigurationException
org.eclipse.lyo.oslc4j.core.exception.OslcCoreApplicationException
URISyntaxException
ParseException
Copyright © 2020. All rights reserved.