it.uniroma2.art.owlart.models.impl
Class OWLModelImpl

java.lang.Object
  extended by it.uniroma2.art.owlart.models.impl.BaseRDFModelImpl
      extended by it.uniroma2.art.owlart.models.impl.RDFModelImpl
          extended by it.uniroma2.art.owlart.models.impl.RDFSModelImpl
              extended by it.uniroma2.art.owlart.models.impl.OWLModelImpl
All Implemented Interfaces:
RDFSerializer, ARTNodeFactory, BaseRDFTripleModel, OWLModel, OWLReasoner, PrefixMapping, RDFModel, RDFSModel, RDFSReasoner, SPARQLQueryModel, TripleQueryModel
Direct Known Subclasses:
SKOSModelImpl

public class OWLModelImpl
extends RDFSModelImpl
implements OWLModel, OWLReasoner


Nested Class Summary
protected  class OWLModelImpl.ARTLiteralIteratorImpl
           
protected  class OWLModelImpl.ARTResourceIteratorImpl
           
 
Field Summary
 
Fields inherited from class it.uniroma2.art.owlart.models.impl.RDFSModelImpl
logger
 
Fields inherited from class it.uniroma2.art.owlart.models.impl.RDFModelImpl
baseRep
 
Constructor Summary
OWLModelImpl(BaseRDFTripleModel baseRep)
           
 
Method Summary
 void addAnnotationProperty(java.lang.String propertyURI, ARTURIResource superProperty, ARTResource... graphs)
          /* ADD/REMOVE METHODS ***
 void addClass(java.lang.String uri, ARTResource... contexts)
          This method has a different behavior depending on the level of the vocabulary used by the repository implementation.
 void addDatatypeProperty(java.lang.String propertyURI, ARTURIResource superProperty, ARTResource... graphs)
          adds a datatype property with uri = propertyURI
 void addImportStatement(java.lang.String baseURI, ARTResource... contexts)
          adds an import statement to the given ontology graphs.
 void addObjectProperty(java.lang.String propertyURI, ARTURIResource superProperty, ARTResource... graphs)
          adds an object property with uri = propertyURI
 void addOntologyProperty(java.lang.String propertyURI, ARTURIResource superProperty, ARTResource... graphs)
          adds an ontology property with uri = propertyURI
 void addValuesToDatarange(ARTResource dataRange, java.util.Iterator<ARTLiteral> literals, ARTResource... graphs)
          it adds a list of literal values (using an iterator over RDF ARTLiteral) to an existing datarange
 void addValueToDatarange(ARTResource dataRange, ARTLiteral lit, ARTResource... graphs)
          it adds a literal value to an existing datarange
 void deleteIndividual(ARTResource res, ARTResource... graphs)
          deletes an owl:Individual (optimized wrt RDFModel#deleteResource(ARTResource, ARTResource...))
 ARTURIResource getInverseProperty(ARTURIResource objectProperty, boolean inferred, ARTResource... graphs)
          returns the inverse property of objectProperty.
protected  boolean hasInversePropertyBoundConcept(ARTResource resource, ARTURIResource property, ARTURIResource inverseProperty, ARTResource object, boolean inferred, ARTResource... graphs)
          this method is invoked by this OWLModel implementation when one needs to known exactly if a triple is available through inference on property which has an inverse.
protected  boolean hasSymmetricPropertyBoundConcept(ARTResource resource, ARTURIResource property, ARTResource object, boolean inferred, ARTResource... graphs)
          this method is invoked by this OWLModel implementation when one needs to known exactly if a triple is available through inference on property which is symmetric.
protected  boolean hasTransitiveInversePropertyBoundConcept(ARTResource resource, ARTURIResource nonTransitiveProperty, ARTURIResource nonTransitiveInverseProperty, ARTURIResource transitiveExtensionProperty, ARTURIResource transitiveExtensionInverseProperty, ARTResource object, boolean inferred, ARTResource... graphs)
           
protected  boolean hasTransitivePropertyBoundConcept(ARTResource resource, ARTURIResource property, ARTResource object, boolean inferred, ARTResource... graphs)
          this method is invoked by this OWLModel implementation when one needs to known exactly if a triple is available through inference on a transitive property.
protected  boolean hasTransitivePropertyBoundConcept(ARTResource resource, ARTURIResource nonTransitiveProperty, ARTURIResource transitiveExtensionProperty, ARTResource object, boolean inferred, ARTResource... graphs)
          * as for hasTransitivePropertyBoundConcept(ARTResource, ARTURIResource, ARTResource, boolean, ARTResource...)
 boolean hasValueInDatarange(ARTResource dataRange, ARTLiteral lit, ARTResource... graphs)
          check if the selected datarange has a particular literal as value
 void instantiateAnnotationProperty(ARTResource subject, ARTURIResource property, java.lang.String value, java.lang.String lang, ARTResource... contexts)
          creates a triple for the given subject, predicate and object, which is described by its label (value) and language (lang)
Arguments are already constrained considering the type of property which is being instantiated
 void instantiateDatatypeProperty(ARTResource subject, ARTURIResource predicate, java.lang.String literalString, ARTResource... contexts)
          TRIPLE INSTANTIATION METHODS ***
 void instantiateObjectProperty(ARTResource subject, ARTURIResource predicate, ARTResource object, ARTResource... contexts)
          creates a triple for the given subject, predicate and object
Arguments are already constrained considering the type of property which is being instantiated
 boolean isAnnotationProperty(ARTURIResource prop, ARTResource... contexts)
          BOOLEAN METHODS ***
 boolean isClass(ARTResource cls, ARTResource... graphs)
          /* BOOLEAN METHODS ***
 boolean isDataRange(ARTResource range, ARTResource... graphs)
          checks if the resource (which has been probably returned has the range of a datatype property, is a DataRange)
 boolean isDatatypeProperty(ARTURIResource prop, ARTResource... contexts)
          checks that prop is an Datatype property
 boolean isFunctionalProperty(ARTURIResource property, ARTResource... contexts)
          checks that prop is a Functional property
 boolean isInverseFunctionalProperty(ARTURIResource property, ARTResource... contexts)
          checks that prop is an InverseFunctional property
 boolean isObjectProperty(ARTURIResource property, ARTResource... contexts)
          checks that prop is an Object property
 boolean isOntology(ARTURIResource uri, ARTResource... contexts)
          checks that resource uri is an Ontology
 boolean isOntologyProperty(ARTURIResource prop, ARTResource... graphs)
          checks that prop is an Ontology property
 boolean isSymmetricProperty(ARTURIResource property, ARTResource... contexts)
          checks that prop is a Symmetric property
 boolean isTransitiveProperty(ARTURIResource property, ARTResource... contexts)
          checks that prop is a Transitive property
 ARTURIResourceIterator listAnnotationProperties(boolean inferred, ARTResource... graphs)
          returns an iterator over Annotation properties available from graphs graphs
 ARTResourceIterator listClasses(boolean inferred, ARTResource... graphs)
          list all the classes in the current Model (in graphs: graphs).
 ARTURIResourceIterator listDatatypeProperties(boolean inferred, ARTResource... graphs)
          returns an iterator over datatype properties available from graphs graphs
protected  ARTResourceIterator listInversePropertyBoundConcepts(ARTResource resource, ARTURIResource property, ARTURIResource inverseProperty, boolean inferred, ARTResource... graphs)
          method which is invoked by this OWLModel implementation when the complete set of results from a property which has an inverse has to be obtained.
 ARTURIResourceIterator listNamedClasses(boolean inferred, ARTResource... graphs)
          LIST/GET METHODS ***
 ARTURIResourceIterator listObjectProperties(boolean inferred, ARTResource... graphs)
          returns an iterator over object properties available from graphs graphs
 ARTURIResourceIterator listOntologyImports(ARTURIResource ontology, ARTResource... contexts)
          list all ontologies imported by ontology ontology (defined in graphs graphs
 ARTURIResourceIterator listOntologyProperties(boolean inferred, ARTResource... graphs)
          returns an iterator over Ontology properties available from graphs graphs
protected  ARTResourceIterator listSymmetricPropertyBoundConcepts(ARTResource resource, ARTURIResource property, boolean inferred, ARTResource... graphs)
          method which is invoked by this OWLModel implementation when the complete set of results from a property which is symmetric has to be obtained.
protected  ARTResourceIterator listTransitiveInversePropertyBoundConcepts(ARTResource resource, ARTURIResource nonTransitiveProperty, ARTURIResource nonTransitiveInverseProperty, ARTURIResource transitiveExtensionProperty, ARTURIResource transitiveExtensionInverseProperty, boolean inferred, ARTResource... graphs)
           
protected  ARTResourceIterator listTransitivePropertyBoundConcepts(ARTResource resource, ARTURIResource nonTransitiveProperty, ARTURIResource transitiveExtensionProperty, boolean inferred, ARTResource... graphs)
          as for listTransitivePropertyBoundConcepts(ARTResource, ARTURIResource, ARTURIResource, boolean, ARTResource...)
protected  ARTResourceIterator listTransitivePropertyBoundConcepts(ARTResource resource, ARTURIResource property, boolean inferred, ARTResource... graphs)
          method which is invoked by this OWLModel implementation when the complete set of results from a transitive property has to be obtained.
 ARTLiteralIterator listValuesOfSubjDTypePropertyPair(ARTResource instance, ARTURIResource property, boolean inferred, ARTResource... contexts)
          returns an iterator over the list of values bound to individual individual through datatype/annotation property property both parameters need to be instantiated
 ARTResourceIterator listValuesOfSubjObjPropertyPair(ARTResource individual, ARTURIResource property, boolean inferred, ARTResource... contexts)
          returns an iterator over the list of values bound to individual individual through object property property both parameters need to be instantiated
 ARTLiteralIterator parseDataRange(ARTResource dataRange, ARTResource... graphs)
          returns an iterator over the list of values allowed by this datarange
 void removeImportStatement(ARTURIResource URI, ARTResource... contexts)
          removes an import statement from graphs graphs
 void removeValueFromDatarange(ARTResource dataRange, ARTLiteral lit, ARTResource... graphs)
          remove a ARTLiteral value from the desired datarange
 void renameIndividual(ARTURIResource oldIndividual, java.lang.String newURI, ARTResource... graphs)
          renames an owl:Individual (optimized wrt RDFModel#renameResource(ARTURIResource, String) as an owl:Individual cannot appear as predicate of a triple)
 ARTURIResource retrieveClass(java.lang.String uri, ARTResource... contexts)
          /* RETRIEVE METHODS ***
 java.lang.String setDataRange(ARTURIResource property, RDFIterator<ARTLiteral> dataRangeIterator, ARTResource... graphs)
          given an iterator over RDF nodes, instantiates a set of triples realizing the datarange composed of elements in the iterator, assigned as range of property property
 boolean supportsInverseProperties()
           
 boolean supportsOWLThingMaterialization()
          OWL REASONING METHODS ***
 boolean supportsSymmetricProperties()
           
 boolean supportsTransitiveProperties()
           
 
Methods inherited from class it.uniroma2.art.owlart.models.impl.RDFSModelImpl
addComment, addLabel, addPropertyDomain, addPropertyRange, addSuperClass, addSuperProperty, deleteClass, listComments, listLabels, listNamedResources, listPropertiesForDomainClass, listPropertiesForRangeClass, listPropertyDomains, listPropertyRanges, listSubClasses, listSubProperties, listSuperClasses, listSuperProperties, listURISuperClasses, removeComment, removeLabel, removePropertyDomain, removePropertyRange, removeSuperClass, removeSuperProperty, renameClass, supportsClassIdentification, supportsSubClassOfClosure, supportsSubPropertyMaterialization, supportsSubPropertyOfClosure
 
Methods inherited from class it.uniroma2.art.owlart.models.impl.RDFModelImpl
addInstance, addProperty, addRDF, addRDF, addStatement, addTriple, addType, clearRDF, close, createBNode, createBNode, createBooleanQuery, createBooleanQuery, createBooleanQuery, createBooleanQuery, createGraphQuery, createGraphQuery, createGraphQuery, createGraphQuery, createLiteral, createLiteral, createLiteral, createQuery, createQuery, createQuery, createQuery, createStatement, createTupleQuery, createTupleQuery, createTupleQuery, createTupleQuery, createURIResource, deleteProperty, deleteResource, deleteStatement, deleteTriple, existsResource, expandQName, getBaseURI, getDefaultNamespace, getNamespacePrefixMapping, getNSForPrefix, getPrefixForNS, getQName, hasStatement, hasTriple, hasType, instantiatePropertyWithPlainLiteral, instantiatePropertyWithPlainLiteral, instantiatePropertyWithResource, instantiatePropertyWithTypedLiteral, isProperty, listInstances, listNamedGraphs, listNamedInstances, listNamespaces, listPredicatesOfSubjObjPair, listProperties, listStatements, listSubjectsOfPredObjPair, listTypes, listValuesOfSubjPredPair, removeNsPrefixMapping, removeType, renameProperty, renameResource, retrieveBNode, retrieveURIResource, setBaseURI, setDefaultNamespace, setNsPrefix, writeRDF, writeRDF, writeRDF, writeRDF
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface it.uniroma2.art.owlart.models.RDFSModel
addComment, addLabel, addPropertyDomain, addPropertyRange, addSuperClass, addSuperProperty, deleteClass, listComments, listLabels, listNamedResources, listPropertiesForDomainClass, listPropertiesForRangeClass, listPropertyDomains, listPropertyRanges, listSubClasses, listSubProperties, listSuperClasses, listSuperProperties, listURISuperClasses, removeComment, removeLabel, removePropertyDomain, removePropertyRange, removeSuperClass, removeSuperProperty, renameClass
 
Methods inherited from interface it.uniroma2.art.owlart.models.RDFModel
addInstance, addProperty, addType, deleteProperty, deleteResource, existsResource, hasType, instantiatePropertyWithPlainLiteral, instantiatePropertyWithPlainLiteral, instantiatePropertyWithResource, instantiatePropertyWithTypedLiteral, isProperty, listInstances, listNamedInstances, listProperties, listTypes, removeType, renameProperty, renameResource, retrieveBNode, retrieveURIResource
 
Methods inherited from interface it.uniroma2.art.owlart.models.BaseRDFTripleModel
addRDF, addRDF, addStatement, addTriple, clearRDF, close, deleteStatement, deleteTriple, getBaseURI, getDefaultNamespace, hasStatement, hasTriple, listNamedGraphs, listNamespaces, listPredicatesOfSubjObjPair, listStatements, listSubjectsOfPredObjPair, listValuesOfSubjPredPair, setBaseURI, setDefaultNamespace, writeRDF, writeRDF
 
Methods inherited from interface it.uniroma2.art.owlart.models.PrefixMapping
expandQName, getNamespacePrefixMapping, getNSForPrefix, getPrefixForNS, getQName, removeNsPrefixMapping, setNsPrefix
 
Methods inherited from interface it.uniroma2.art.owlart.model.ARTNodeFactory
createBNode, createBNode, createLiteral, createLiteral, createLiteral, createStatement, createURIResource
 
Methods inherited from interface it.uniroma2.art.owlart.io.RDFSerializer
writeRDF, writeRDF
 
Methods inherited from interface it.uniroma2.art.owlart.models.SPARQLQueryModel
createBooleanQuery, createBooleanQuery, createBooleanQuery, createGraphQuery, createGraphQuery, createGraphQuery, createQuery, createQuery, createQuery, createTupleQuery, createTupleQuery, createTupleQuery
 
Methods inherited from interface it.uniroma2.art.owlart.models.TripleQueryModel
createBooleanQuery, createGraphQuery, createQuery, createTupleQuery
 
Methods inherited from interface it.uniroma2.art.owlart.models.RDFSReasoner
supportsClassIdentification, supportsSubClassOfClosure, supportsSubPropertyMaterialization, supportsSubPropertyOfClosure
 

Constructor Detail

OWLModelImpl

public OWLModelImpl(BaseRDFTripleModel baseRep)
Method Detail

addAnnotationProperty

public void addAnnotationProperty(java.lang.String propertyURI,
                                  ARTURIResource superProperty,
                                  ARTResource... graphs)
                           throws ModelUpdateException
/* ADD/REMOVE METHODS ***

Specified by:
addAnnotationProperty in interface OWLModel
Throws:
ModelUpdateException

addDatatypeProperty

public void addDatatypeProperty(java.lang.String propertyURI,
                                ARTURIResource superProperty,
                                ARTResource... graphs)
                         throws ModelUpdateException
Description copied from interface: OWLModel
adds a datatype property with uri = propertyURI

Specified by:
addDatatypeProperty in interface OWLModel
Throws:
ModelUpdateException

addObjectProperty

public void addObjectProperty(java.lang.String propertyURI,
                              ARTURIResource superProperty,
                              ARTResource... graphs)
                       throws ModelUpdateException
Description copied from interface: OWLModel
adds an object property with uri = propertyURI

Specified by:
addObjectProperty in interface OWLModel
Throws:
ModelUpdateException

addOntologyProperty

public void addOntologyProperty(java.lang.String propertyURI,
                                ARTURIResource superProperty,
                                ARTResource... graphs)
                         throws ModelUpdateException
Description copied from interface: OWLModel
adds an ontology property with uri = propertyURI

Specified by:
addOntologyProperty in interface OWLModel
Throws:
ModelUpdateException

addImportStatement

public void addImportStatement(java.lang.String baseURI,
                               ARTResource... contexts)
                        throws ModelUpdateException
Description copied from interface: OWLModel
adds an import statement to the given ontology graphs. Note that this method should be commonly invoked on the main graph, since the subject of the import is the uri of the main ontology of this model. However, the methods allows to state the import also in other graphs

Specified by:
addImportStatement in interface OWLModel
Parameters:
baseURI - the baseURI of the ontology being imported
Throws:
ModelUpdateException

addClass

public void addClass(java.lang.String uri,
                     ARTResource... contexts)
              throws ModelUpdateException
Description copied from interface: RDFSModel
This method has a different behavior depending on the level of the vocabulary used by the repository implementation. The newly created class will be an rdfs:Class in RDFS repositories and owl:Class in OWL repositories

Specified by:
addClass in interface RDFSModel
Overrides:
addClass in class RDFSModelImpl
Parameters:
uri - URI string of the class being created
Throws:
ModelUpdateException

removeImportStatement

public void removeImportStatement(ARTURIResource URI,
                                  ARTResource... contexts)
                           throws ModelUpdateException
Description copied from interface: OWLModel
removes an import statement from graphs graphs

Specified by:
removeImportStatement in interface OWLModel
Parameters:
URI - the baseURI of the ontology being imported
Throws:
ModelUpdateException

addValuesToDatarange

public void addValuesToDatarange(ARTResource dataRange,
                                 java.util.Iterator<ARTLiteral> literals,
                                 ARTResource... graphs)
                          throws ModelAccessException,
                                 ModelUpdateException
Description copied from interface: OWLModel
it adds a list of literal values (using an iterator over RDF ARTLiteral) to an existing datarange

Specified by:
addValuesToDatarange in interface OWLModel
Throws:
ModelAccessException
ModelUpdateException

addValueToDatarange

public void addValueToDatarange(ARTResource dataRange,
                                ARTLiteral lit,
                                ARTResource... graphs)
                         throws ModelAccessException,
                                ModelUpdateException
Description copied from interface: OWLModel
it adds a literal value to an existing datarange

Specified by:
addValueToDatarange in interface OWLModel
Throws:
ModelAccessException
ModelUpdateException

removeValueFromDatarange

public void removeValueFromDatarange(ARTResource dataRange,
                                     ARTLiteral lit,
                                     ARTResource... graphs)
                              throws ModelAccessException,
                                     ModelUpdateException
Description copied from interface: OWLModel
remove a ARTLiteral value from the desired datarange

Specified by:
removeValueFromDatarange in interface OWLModel
Throws:
ModelAccessException
ModelUpdateException

instantiateDatatypeProperty

public void instantiateDatatypeProperty(ARTResource subject,
                                        ARTURIResource predicate,
                                        java.lang.String literalString,
                                        ARTResource... contexts)
                                 throws ModelUpdateException
TRIPLE INSTANTIATION METHODS ***

Specified by:
instantiateDatatypeProperty in interface OWLModel
Throws:
ModelUpdateException

instantiateObjectProperty

public void instantiateObjectProperty(ARTResource subject,
                                      ARTURIResource predicate,
                                      ARTResource object,
                                      ARTResource... contexts)
                               throws ModelUpdateException
Description copied from interface: OWLModel
creates a triple for the given subject, predicate and object
Arguments are already constrained considering the type of property which is being instantiated

Specified by:
instantiateObjectProperty in interface OWLModel
Throws:
ModelUpdateException

instantiateAnnotationProperty

public void instantiateAnnotationProperty(ARTResource subject,
                                          ARTURIResource property,
                                          java.lang.String value,
                                          java.lang.String lang,
                                          ARTResource... contexts)
                                   throws ModelUpdateException
Description copied from interface: OWLModel
creates a triple for the given subject, predicate and object, which is described by its label (value) and language (lang)
Arguments are already constrained considering the type of property which is being instantiated

Specified by:
instantiateAnnotationProperty in interface OWLModel
Throws:
ModelUpdateException

setDataRange

public java.lang.String setDataRange(ARTURIResource property,
                                     RDFIterator<ARTLiteral> dataRangeIterator,
                                     ARTResource... graphs)
                              throws ModelAccessException,
                                     ModelUpdateException
Description copied from interface: OWLModel
given an iterator over RDF nodes, instantiates a set of triples realizing the datarange composed of elements in the iterator, assigned as range of property property

Specified by:
setDataRange in interface OWLModel
Returns:
Throws:
ModelAccessException
ModelUpdateException

isAnnotationProperty

public boolean isAnnotationProperty(ARTURIResource prop,
                                    ARTResource... contexts)
                             throws ModelAccessException
BOOLEAN METHODS ***

Specified by:
isAnnotationProperty in interface OWLModel
Returns:
Throws:
ModelAccessException

isDatatypeProperty

public boolean isDatatypeProperty(ARTURIResource prop,
                                  ARTResource... contexts)
                           throws ModelAccessException
Description copied from interface: OWLModel
checks that prop is an Datatype property

Specified by:
isDatatypeProperty in interface OWLModel
Returns:
Throws:
ModelAccessException

isOntologyProperty

public boolean isOntologyProperty(ARTURIResource prop,
                                  ARTResource... graphs)
                           throws ModelAccessException
Description copied from interface: OWLModel
checks that prop is an Ontology property

Specified by:
isOntologyProperty in interface OWLModel
Returns:
Throws:
ModelAccessException

isFunctionalProperty

public boolean isFunctionalProperty(ARTURIResource property,
                                    ARTResource... contexts)
                             throws ModelAccessException
Description copied from interface: OWLModel
checks that prop is a Functional property

Specified by:
isFunctionalProperty in interface OWLModel
Returns:
Throws:
ModelAccessException

isInverseFunctionalProperty

public boolean isInverseFunctionalProperty(ARTURIResource property,
                                           ARTResource... contexts)
                                    throws ModelAccessException
Description copied from interface: OWLModel
checks that prop is an InverseFunctional property

Specified by:
isInverseFunctionalProperty in interface OWLModel
Returns:
Throws:
ModelAccessException

isObjectProperty

public boolean isObjectProperty(ARTURIResource property,
                                ARTResource... contexts)
                         throws ModelAccessException
Description copied from interface: OWLModel
checks that prop is an Object property

Specified by:
isObjectProperty in interface OWLModel
Returns:
Throws:
ModelAccessException

isSymmetricProperty

public boolean isSymmetricProperty(ARTURIResource property,
                                   ARTResource... contexts)
                            throws ModelAccessException
Description copied from interface: OWLModel
checks that prop is a Symmetric property

Specified by:
isSymmetricProperty in interface OWLModel
Returns:
Throws:
ModelAccessException

isTransitiveProperty

public boolean isTransitiveProperty(ARTURIResource property,
                                    ARTResource... contexts)
                             throws ModelAccessException
Description copied from interface: OWLModel
checks that prop is a Transitive property

Specified by:
isTransitiveProperty in interface OWLModel
Returns:
Throws:
ModelAccessException

isDataRange

public boolean isDataRange(ARTResource range,
                           ARTResource... graphs)
                    throws ModelAccessException
Description copied from interface: OWLModel
checks if the resource (which has been probably returned has the range of a datatype property, is a DataRange)

Specified by:
isDataRange in interface OWLModel
Returns:
Throws:
ModelAccessException

isOntology

public boolean isOntology(ARTURIResource uri,
                          ARTResource... contexts)
                   throws ModelAccessException
Description copied from interface: OWLModel
checks that resource uri is an Ontology

Specified by:
isOntology in interface OWLModel
Returns:
Throws:
ModelAccessException

hasValueInDatarange

public boolean hasValueInDatarange(ARTResource dataRange,
                                   ARTLiteral lit,
                                   ARTResource... graphs)
                            throws ModelAccessException
Description copied from interface: OWLModel
check if the selected datarange has a particular literal as value

Specified by:
hasValueInDatarange in interface OWLModel
Returns:
Throws:
ModelAccessException

listNamedClasses

public ARTURIResourceIterator listNamedClasses(boolean inferred,
                                               ARTResource... graphs)
                                        throws ModelAccessException
LIST/GET METHODS ***

Specified by:
listNamedClasses in interface RDFSModel
Overrides:
listNamedClasses in class RDFSModelImpl
Returns:
Collection arrayList
Throws:
ModelAccessException

listClasses

public ARTResourceIterator listClasses(boolean inferred,
                                       ARTResource... graphs)
                                throws ModelAccessException
Description copied from interface: RDFSModel
list all the classes in the current Model (in graphs: graphs). If this model is also an RDFSReasoner which RDFSReasoner.supportsSubClassOfClosure(), the returned URIs are all rdf instances of RDFS.CLASS. If negative case, the returned URIs are those specified as subjects of triples present in the given graphs where the predicate is RDF.TYPE or RDFS.SUBCLASSOF.

Specified by:
listClasses in interface RDFSModel
Overrides:
listClasses in class RDFSModelImpl
Returns:
Collection arrayList
Throws:
ModelAccessException

listAnnotationProperties

public ARTURIResourceIterator listAnnotationProperties(boolean inferred,
                                                       ARTResource... graphs)
                                                throws ModelAccessException
Description copied from interface: OWLModel
returns an iterator over Annotation properties available from graphs graphs

Specified by:
listAnnotationProperties in interface OWLModel
Returns:
Throws:
ModelAccessException

listDatatypeProperties

public ARTURIResourceIterator listDatatypeProperties(boolean inferred,
                                                     ARTResource... graphs)
                                              throws ModelAccessException
Description copied from interface: OWLModel
returns an iterator over datatype properties available from graphs graphs

Specified by:
listDatatypeProperties in interface OWLModel
Returns:
Throws:
ModelAccessException

listObjectProperties

public ARTURIResourceIterator listObjectProperties(boolean inferred,
                                                   ARTResource... graphs)
                                            throws ModelAccessException
Description copied from interface: OWLModel
returns an iterator over object properties available from graphs graphs

Specified by:
listObjectProperties in interface OWLModel
Returns:
Throws:
ModelAccessException

listOntologyProperties

public ARTURIResourceIterator listOntologyProperties(boolean inferred,
                                                     ARTResource... graphs)
                                              throws ModelAccessException
Description copied from interface: OWLModel
returns an iterator over Ontology properties available from graphs graphs

Specified by:
listOntologyProperties in interface OWLModel
Returns:
Throws:
ModelAccessException

getInverseProperty

public ARTURIResource getInverseProperty(ARTURIResource objectProperty,
                                         boolean inferred,
                                         ARTResource... graphs)
                                  throws ModelAccessException
Description copied from interface: OWLModel
returns the inverse property of objectProperty. If more than one inverse is defined, the first declared one is returned (all other properties are equivalentProperties then). If no declaration is available, null is returned.

Specified by:
getInverseProperty in interface OWLModel
Returns:
Throws:
ModelAccessException

listOntologyImports

public ARTURIResourceIterator listOntologyImports(ARTURIResource ontology,
                                                  ARTResource... contexts)
                                           throws ModelAccessException
Description copied from interface: OWLModel
list all ontologies imported by ontology ontology (defined in graphs graphs

Specified by:
listOntologyImports in interface OWLModel
Returns:
Throws:
ModelAccessException

listValuesOfSubjDTypePropertyPair

public ARTLiteralIterator listValuesOfSubjDTypePropertyPair(ARTResource instance,
                                                            ARTURIResource property,
                                                            boolean inferred,
                                                            ARTResource... contexts)
                                                     throws ModelAccessException
Description copied from interface: OWLModel
returns an iterator over the list of values bound to individual individual through datatype/annotation property property both parameters need to be instantiated

Specified by:
listValuesOfSubjDTypePropertyPair in interface OWLModel
Returns:
Throws:
ModelAccessException

listValuesOfSubjObjPropertyPair

public ARTResourceIterator listValuesOfSubjObjPropertyPair(ARTResource individual,
                                                           ARTURIResource property,
                                                           boolean inferred,
                                                           ARTResource... contexts)
                                                    throws ModelAccessException
Description copied from interface: OWLModel
returns an iterator over the list of values bound to individual individual through object property property both parameters need to be instantiated

Specified by:
listValuesOfSubjObjPropertyPair in interface OWLModel
Returns:
Throws:
ModelAccessException

retrieveClass

public ARTURIResource retrieveClass(java.lang.String uri,
                                    ARTResource... contexts)
                             throws ModelAccessException
Description copied from class: RDFSModelImpl
/* RETRIEVE METHODS ***

Specified by:
retrieveClass in interface RDFSModel
Overrides:
retrieveClass in class RDFSModelImpl
Returns:
Throws:
ModelAccessException

parseDataRange

public ARTLiteralIterator parseDataRange(ARTResource dataRange,
                                         ARTResource... graphs)
                                  throws ModelAccessException
Description copied from interface: OWLModel
returns an iterator over the list of values allowed by this datarange

Specified by:
parseDataRange in interface OWLModel
Returns:
Throws:
ModelAccessException

isClass

public boolean isClass(ARTResource cls,
                       ARTResource... graphs)
                throws ModelAccessException
Description copied from class: RDFSModelImpl
/* BOOLEAN METHODS ***

Specified by:
isClass in interface RDFSModel
Overrides:
isClass in class RDFSModelImpl
Throws:
ModelAccessException

deleteIndividual

public void deleteIndividual(ARTResource res,
                             ARTResource... graphs)
                      throws ModelUpdateException
Description copied from interface: OWLModel
deletes an owl:Individual (optimized wrt RDFModel#deleteResource(ARTResource, ARTResource...)) as an owl:Individual cannot appear as predicate of a triple)

Specified by:
deleteIndividual in interface OWLModel
Throws:
ModelUpdateException

renameIndividual

public void renameIndividual(ARTURIResource oldIndividual,
                             java.lang.String newURI,
                             ARTResource... graphs)
                      throws ModelUpdateException
Description copied from interface: OWLModel
renames an owl:Individual (optimized wrt RDFModel#renameResource(ARTURIResource, String) as an owl:Individual cannot appear as predicate of a triple)

Specified by:
renameIndividual in interface OWLModel
Throws:
ModelUpdateException

supportsOWLThingMaterialization

public boolean supportsOWLThingMaterialization()
OWL REASONING METHODS ***

Specified by:
supportsOWLThingMaterialization in interface OWLReasoner
Returns:

supportsInverseProperties

public boolean supportsInverseProperties()
Specified by:
supportsInverseProperties in interface OWLReasoner

supportsTransitiveProperties

public boolean supportsTransitiveProperties()
Specified by:
supportsTransitiveProperties in interface OWLReasoner

supportsSymmetricProperties

public boolean supportsSymmetricProperties()
Specified by:
supportsSymmetricProperties in interface OWLReasoner

hasInversePropertyBoundConcept

protected boolean hasInversePropertyBoundConcept(ARTResource resource,
                                                 ARTURIResource property,
                                                 ARTURIResource inverseProperty,
                                                 ARTResource object,
                                                 boolean inferred,
                                                 ARTResource... graphs)
                                          throws ModelAccessException
this method is invoked by this OWLModel implementation when one needs to known exactly if a triple is available through inference on property which has an inverse. In this case, if a reasoner is not available or if it is not able to provide owl:inverseOf computation, then an algorithmic solution is adopted to provide on-the-fly computation for the property passed as an argument.

Parameters:
resource -
property -
inverseProperty -
object -
inferred -
graphs -
Returns:
Throws:
ModelAccessException

hasSymmetricPropertyBoundConcept

protected boolean hasSymmetricPropertyBoundConcept(ARTResource resource,
                                                   ARTURIResource property,
                                                   ARTResource object,
                                                   boolean inferred,
                                                   ARTResource... graphs)
                                            throws ModelAccessException
this method is invoked by this OWLModel implementation when one needs to known exactly if a triple is available through inference on property which is symmetric. In this case, if a reasoner is not available or if it is not able to provide owl:Symmetric computation, then an algorithmic solution is adopted to provide on-the-fly computation for the property passed as an argument.

Parameters:
resource -
property -
object -
inferred -
graphs -
Returns:
Throws:
ModelAccessException

hasTransitivePropertyBoundConcept

protected boolean hasTransitivePropertyBoundConcept(ARTResource resource,
                                                    ARTURIResource property,
                                                    ARTResource object,
                                                    boolean inferred,
                                                    ARTResource... graphs)
                                             throws ModelAccessException
this method is invoked by this OWLModel implementation when one needs to known exactly if a triple is available through inference on a transitive property. In this case, if a reasoner is not available or if it is not able to provide owl:inverseOf computation, then an algorithmic solution is adopted to provide on-the-fly computation for the property passed as an argument.

Parameters:
resource -
property -
object -
inferred -
graphs -
Returns:
Throws:
ModelAccessException

hasTransitivePropertyBoundConcept

protected boolean hasTransitivePropertyBoundConcept(ARTResource resource,
                                                    ARTURIResource nonTransitiveProperty,
                                                    ARTURIResource transitiveExtensionProperty,
                                                    ARTResource object,
                                                    boolean inferred,
                                                    ARTResource... graphs)
                                             throws ModelAccessException
* as for hasTransitivePropertyBoundConcept(ARTResource, ARTURIResource, ARTResource, boolean, ARTResource...) though the transitive property is the transitive extension of a non-transitive property.
If no reasoning is asked, the non-transitive property is looked in the concrete triples.
In case of reasoning (inferred==true), if a reasoner is able to compute it (it has transitive property reasoning), the transitive property is explored, while if it is not, a recursive exploration of the non-transitive property is conducted

Parameters:
resource -
nonTransitiveProperty -
transitiveExtensionProperty -
object -
inferred -
graphs -
Returns:
Throws:
ModelAccessException

hasTransitiveInversePropertyBoundConcept

protected boolean hasTransitiveInversePropertyBoundConcept(ARTResource resource,
                                                           ARTURIResource nonTransitiveProperty,
                                                           ARTURIResource nonTransitiveInverseProperty,
                                                           ARTURIResource transitiveExtensionProperty,
                                                           ARTURIResource transitiveExtensionInverseProperty,
                                                           ARTResource object,
                                                           boolean inferred,
                                                           ARTResource... graphs)
                                                    throws ModelAccessException
Parameters:
resource -
nonTransitiveProperty -
nonTransitiveInverseProperty - inverse property of property nonTransitiveProperty
transitiveExtensionProperty - transitive extension of property nonTransitiveProperty
transitiveExtensionInverseProperty - transitive extension of property nonTransitiveInverseProperty
object -
inferred -
graphs -
Returns:
Throws:
ModelAccessException

listInversePropertyBoundConcepts

protected ARTResourceIterator listInversePropertyBoundConcepts(ARTResource resource,
                                                               ARTURIResource property,
                                                               ARTURIResource inverseProperty,
                                                               boolean inferred,
                                                               ARTResource... graphs)
                                                        throws ModelAccessException
method which is invoked by this OWLModel implementation when the complete set of results from a property which has an inverse has to be obtained. In this case, if a reasoner is not available or if it is not able to provide owl:inverseOf computation, then an algorithmic solution is adopted to provide on-the-fly computation for the property passed as an argument.

Parameters:
resource -
property -
inverseProperty -
graphs -
Returns:
Throws:
ModelAccessException

listSymmetricPropertyBoundConcepts

protected ARTResourceIterator listSymmetricPropertyBoundConcepts(ARTResource resource,
                                                                 ARTURIResource property,
                                                                 boolean inferred,
                                                                 ARTResource... graphs)
                                                          throws ModelAccessException
method which is invoked by this OWLModel implementation when the complete set of results from a property which is symmetric has to be obtained. In this case, if a reasoner is not available or if it is not able to provide owl:Symmetric computation, then an algorithmic solution is adopted to provide on-the-fly computation for the property passed as an argument.

Parameters:
resource -
property -
graphs -
Returns:
Throws:
ModelAccessException

listTransitivePropertyBoundConcepts

protected ARTResourceIterator listTransitivePropertyBoundConcepts(ARTResource resource,
                                                                  ARTURIResource property,
                                                                  boolean inferred,
                                                                  ARTResource... graphs)
                                                           throws ModelAccessException
method which is invoked by this OWLModel implementation when the complete set of results from a transitive property has to be obtained. In this case, if a reasoner is not available or if it is not able to provide owl:inverseOf computation, then an algorithmic solution is adopted to provide on-the-fly computation for the property passed as an argument.

Parameters:
resource -
property -
graphs -
Returns:
Throws:
ModelAccessException

listTransitivePropertyBoundConcepts

protected ARTResourceIterator listTransitivePropertyBoundConcepts(ARTResource resource,
                                                                  ARTURIResource nonTransitiveProperty,
                                                                  ARTURIResource transitiveExtensionProperty,
                                                                  boolean inferred,
                                                                  ARTResource... graphs)
                                                           throws ModelAccessException
as for listTransitivePropertyBoundConcepts(ARTResource, ARTURIResource, ARTURIResource, boolean, ARTResource...) though the transitive property is the transitive extension of a non-transitive property.
If no reasoning is asked, the non-transitive property is looked in the concrete triples.
In case of reasoning (inferred==true), if a reasoner is able to compute it (it has transitive property reasoning), the transitive property is explored, while if it is not, a recursive exploration of the non-transitive property is conducted

Parameters:
resource -
nonTransitiveProperty -
transitiveExtensionProperty - transitive extension of property property
graphs -
Returns:
Throws:
ModelAccessException

listTransitiveInversePropertyBoundConcepts

protected ARTResourceIterator listTransitiveInversePropertyBoundConcepts(ARTResource resource,
                                                                         ARTURIResource nonTransitiveProperty,
                                                                         ARTURIResource nonTransitiveInverseProperty,
                                                                         ARTURIResource transitiveExtensionProperty,
                                                                         ARTURIResource transitiveExtensionInverseProperty,
                                                                         boolean inferred,
                                                                         ARTResource... graphs)
                                                                  throws ModelAccessException
Parameters:
resource -
nonTransitiveProperty -
transitiveExtensionProperty - transitive extension of property property
graphs -
Returns:
Throws:
ModelAccessException


Copyright © 2013 ART Group, University of Rome, Tor Vergata. All Rights Reserved.