Package org.topbraid.shacl.model.impl
Class SHPropertyShapeImpl
- java.lang.Object
-
- org.apache.jena.enhanced.Polymorphic<org.apache.jena.rdf.model.RDFNode>
-
- org.apache.jena.enhanced.EnhNode
-
- org.apache.jena.rdf.model.impl.ResourceImpl
-
- org.topbraid.shacl.model.impl.SHResourceImpl
-
- org.topbraid.shacl.model.impl.SHParameterizableInstanceImpl
-
- org.topbraid.shacl.model.impl.SHShapeImpl
-
- org.topbraid.shacl.model.impl.SHPropertyShapeImpl
-
- All Implemented Interfaces:
org.apache.jena.graph.FrontsNode,org.apache.jena.rdf.model.RDFNode,org.apache.jena.rdf.model.Resource,SHParameterizableInstance,SHPropertyShape,SHResource,SHShape
- Direct Known Subclasses:
SHParameterImpl
public class SHPropertyShapeImpl extends SHShapeImpl implements SHPropertyShape
-
-
Constructor Summary
Constructors Constructor Description SHPropertyShapeImpl(org.apache.jena.graph.Node node, org.apache.jena.enhanced.EnhGraph graph)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.jena.rdf.model.ResourcegetClassOrDatatype()Gets the declared sh:class or sh:datatype (if any).org.apache.jena.rdf.model.ResourcegetContext()Returns either sh:NodeShape or sh:PropertyShape.StringgetCountDisplayString()StringgetDescription()Gets the sh:description, if it exists.IntegergetMaxCount()IntegergetMinCount()StringgetName()Gets the sh:name, if it exists.IntegergetOrder()Gets the sh:order of thisorg.apache.jena.rdf.model.PropertygetPredicate()Gets the property represented by the sh:path, assuming it's a IRI.StringgetVarName()Gets the variable name associated with this.StringtoString()-
Methods inherited from class org.topbraid.shacl.model.impl.SHShapeImpl
getPath, getPropertyShapes, getPropertyShapes, getRules, getSeverity, hasTargetNode, isDeactivated, isPropertyShape
-
Methods inherited from class org.topbraid.shacl.model.impl.SHParameterizableInstanceImpl
addBindings, getParameterizable, getParameterMapByVarNames
-
Methods inherited from class org.apache.jena.rdf.model.impl.ResourceImpl
abort, addLiteral, addLiteral, addLiteral, addLiteral, addLiteral, addLiteral, addLiteral, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, asLiteral, asResource, begin, commit, getId, getLocalName, getModel, getModelCom, getNameSpace, getProperty, getProperty, getPropertyResourceValue, getRequiredProperty, getRequiredProperty, getStmtTerm, getURI, hasLiteral, hasLiteral, hasLiteral, hasLiteral, hasLiteral, hasLiteral, hasProperty, hasProperty, hasProperty, hasProperty, hasURI, inModel, listProperties, listProperties, listProperties, mustHaveModel, removeAll, removeProperties, visitWith
-
Methods inherited from class org.apache.jena.enhanced.EnhNode
as, asNode, canAs, canSupport, convertTo, equals, getGraph, getPersonality, hashCode, isAnon, isLiteral, isResource, isStmtResource, isURIResource, isValid, viewAs
-
Methods inherited from class org.apache.jena.enhanced.Polymorphic
addView, alreadyHasView, asInternal, supports
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.apache.jena.rdf.model.RDFNode
as, asLiteral, asResource, canAs, getModel, isAnon, isLiteral, isResource, isStmtResource, isURIResource, visitWith
-
Methods inherited from interface org.apache.jena.rdf.model.Resource
abort, addLiteral, addLiteral, addLiteral, addLiteral, addLiteral, addLiteral, addLiteral, addProperty, addProperty, addProperty, addProperty, begin, commit, equals, getId, getLocalName, getNameSpace, getProperty, getProperty, getPropertyResourceValue, getRequiredProperty, getRequiredProperty, getStmtTerm, getURI, hasLiteral, hasLiteral, hasLiteral, hasLiteral, hasLiteral, hasLiteral, hasProperty, hasProperty, hasProperty, hasProperty, hasURI, inModel, listProperties, listProperties, listProperties, removeAll, removeProperties
-
Methods inherited from interface org.topbraid.shacl.model.SHShape
getPath, getPropertyShapes, getPropertyShapes, getRules, getSeverity, hasTargetNode, isDeactivated, isPropertyShape
-
-
-
-
Method Detail
-
getClassOrDatatype
public org.apache.jena.rdf.model.Resource getClassOrDatatype()
Description copied from interface:SHPropertyShapeGets the declared sh:class or sh:datatype (if any). If none is declared, falls back to sh:nodeKind, e.g. returning rdfs:Resource if sh:nodeKind is sh:IRI.- Specified by:
getClassOrDatatypein interfaceSHPropertyShape- Returns:
- the value type or data type
-
getContext
public org.apache.jena.rdf.model.Resource getContext()
Description copied from interface:SHShapeReturns either sh:NodeShape or sh:PropertyShape.- Specified by:
getContextin interfaceSHShape- Returns:
- the context
-
getCountDisplayString
public String getCountDisplayString()
- Specified by:
getCountDisplayStringin interfaceSHPropertyShape
-
getDescription
public String getDescription()
Description copied from interface:SHPropertyShapeGets the sh:description, if it exists.- Specified by:
getDescriptionin interfaceSHPropertyShape- Returns:
- the description or null
-
getMaxCount
public Integer getMaxCount()
- Specified by:
getMaxCountin interfaceSHPropertyShape
-
getMinCount
public Integer getMinCount()
- Specified by:
getMinCountin interfaceSHPropertyShape
-
getName
public String getName()
Description copied from interface:SHPropertyShapeGets the sh:name, if it exists.- Specified by:
getNamein interfaceSHPropertyShape- Returns:
- the name or null
-
getOrder
public Integer getOrder()
Description copied from interface:SHPropertyShapeGets the sh:order of this- Specified by:
getOrderin interfaceSHPropertyShape- Returns:
- the order or null no sh:order is given
-
getPredicate
public org.apache.jena.rdf.model.Property getPredicate()
Description copied from interface:SHPropertyShapeGets the property represented by the sh:path, assuming it's a IRI. Returns null if it's a property path (blank node).- Specified by:
getPredicatein interfaceSHPropertyShape- Returns:
- the predicate or null
-
getVarName
public String getVarName()
Description copied from interface:SHPropertyShapeGets the variable name associated with this. This is the local name of the predicate, i.e. implementations can assume that this value is not null iff getPredicate() != null.- Specified by:
getVarNamein interfaceSHPropertyShape- Returns:
- the variable name
-
toString
public String toString()
- Specified by:
toStringin interfaceorg.apache.jena.rdf.model.RDFNode- Specified by:
toStringin interfaceorg.apache.jena.rdf.model.Resource- Overrides:
toStringin classorg.apache.jena.rdf.model.impl.ResourceImpl
-
-