|
Protégé-OWL 3.4 beta | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface OWLModel
A KnowledgeBase with a number of convenience methods to handle anonymous classes.
| Field Summary |
|---|
| Fields inherited from interface edu.stanford.smi.protege.model.KnowledgeBase |
|---|
MAXIMUM_CARDINALITY_UNBOUNDED, UNLIMITED_MATCHES |
| Method Summary | |
|---|---|
void |
addClassListener(ClassListener listener)
Adds a ClassListener to receive events about any class in this OWLModel. |
void |
addModelListener(ModelListener listener)
Adds a ModelListener to receive notifications when resources have been created, renamed or deleted. |
void |
addPropertyListener(PropertyListener listener)
Adds a PropertyListener to receive events about any property in this OWLModel. |
void |
addPropertyValueListener(PropertyValueListener listener)
Adds a PropertyValueListener to receive events about any property value change in this OWLModel. |
void |
addResourceListener(ResourceListener listener)
Adds a ResourceListener to receive events about any RDFResource in this OWLModel. |
RDFObject |
asRDFObject(Object object)
Gets an RDFObject for a given value. |
RDFSLiteral |
asRDFSLiteral(Object value)
Gets an RDFSLiteral for a given value. |
List |
asRDFSLiterals(Collection values)
|
OWLDatatypeProperty |
createAnnotationOWLDatatypeProperty(String name)
|
OWLObjectProperty |
createAnnotationOWLObjectProperty(String name)
|
RDFProperty |
createAnnotationProperty(String name)
Creates a simple owl:AnnotationProperty. |
String |
createNewResourceName(String partialLocalName)
Creates a unique name from a given local name prefix. |
OWLAllDifferent |
createOWLAllDifferent()
|
OWLAllValuesFrom |
createOWLAllValuesFrom()
|
OWLAllValuesFrom |
createOWLAllValuesFrom(RDFProperty property,
RDFResource filler)
|
OWLAllValuesFrom |
createOWLAllValuesFrom(RDFProperty property,
RDFSLiteral[] oneOfValues)
|
OWLCardinality |
createOWLCardinality()
|
OWLCardinality |
createOWLCardinality(RDFProperty property,
int value)
|
OWLCardinality |
createOWLCardinality(RDFProperty property,
int value,
RDFSClass qualifier)
|
OWLComplementClass |
createOWLComplementClass()
|
OWLComplementClass |
createOWLComplementClass(RDFSClass complement)
|
OWLDataRange |
createOWLDataRange()
Creates an empty owl:DataRange. |
OWLDataRange |
createOWLDataRange(RDFSLiteral[] values)
Creates a new owl:DataRange consisting of a given set of values. |
OWLDatatypeProperty |
createOWLDatatypeProperty(String name)
Creates a new OWLDatatypeProperty (with default settings, e.g. |
OWLDatatypeProperty |
createOWLDatatypeProperty(String name,
OWLNamedClass metaclass)
Creates a new OWLDatatypeProperty with a given rdf:type as metaclass. |
OWLDatatypeProperty |
createOWLDatatypeProperty(String name,
RDFSDatatype datatype)
Creates a new OWLDatatypeProperty with a given RDFSDatatype as range. |
OWLDatatypeProperty |
createOWLDatatypeProperty(String name,
RDFSLiteral[] dataRangeLiterals)
|
OWLEnumeratedClass |
createOWLEnumeratedClass()
|
OWLEnumeratedClass |
createOWLEnumeratedClass(Collection instances)
|
OWLHasValue |
createOWLHasValue()
|
OWLHasValue |
createOWLHasValue(RDFProperty property,
Object value)
Creates a new OWLHasValue for a given Slot. |
OWLIntersectionClass |
createOWLIntersectionClass()
|
OWLIntersectionClass |
createOWLIntersectionClass(Collection clses)
|
OWLMaxCardinality |
createOWLMaxCardinality()
|
OWLMaxCardinality |
createOWLMaxCardinality(RDFProperty property,
int value)
|
OWLMaxCardinality |
createOWLMaxCardinality(RDFProperty property,
int value,
RDFSClass qualifier)
|
OWLMinCardinality |
createOWLMinCardinality()
|
OWLMinCardinality |
createOWLMinCardinality(RDFProperty property,
int value)
|
OWLMinCardinality |
createOWLMinCardinality(RDFProperty property,
int value,
RDFSClass qualifier)
|
OWLNamedClass |
createOWLNamedClass(String name)
|
OWLNamedClass |
createOWLNamedClass(String name,
boolean loadDefaults)
|
OWLNamedClass |
createOWLNamedClass(String name,
OWLNamedClass metaclass)
Creates a new named OWL class with a given metaclass, which must be a subclass of owl:Class. |
OWLNamedClass |
createOWLNamedSubclass(String name,
OWLNamedClass superclass)
|
OWLObjectProperty |
createOWLObjectProperty(String name)
Creates a new OWLObjectProperty. |
OWLObjectProperty |
createOWLObjectProperty(String name,
Collection allowedClasses)
|
OWLObjectProperty |
createOWLObjectProperty(String name,
OWLNamedClass metaclass)
|
OWLOntology |
createOWLOntology(String prefix)
Creates a new OWLOntology for a given prefix. |
OWLOntology |
createOWLOntology(String name,
String uri)
Deprecated. use the other createOWLOntology method instead |
OWLSomeValuesFrom |
createOWLSomeValuesFrom()
|
OWLSomeValuesFrom |
createOWLSomeValuesFrom(RDFProperty property,
RDFResource filler)
|
OWLSomeValuesFrom |
createOWLSomeValuesFrom(RDFProperty property,
RDFSLiteral[] oneOfValues)
|
OWLUnionClass |
createOWLUnionClass()
|
OWLUnionClass |
createOWLUnionClass(Collection operandClasses)
|
RDFExternalResource |
createRDFExternalResource(String uri)
Deprecated. use createRDFUntypedResource instead |
RDFList |
createRDFList()
Creates a new empty rdf:List |
RDFList |
createRDFList(Iterator values)
Creates a new rdf:List. |
RDFProperty |
createRDFProperty(String name)
|
RDFSClass |
createRDFSClassFromExpression(String parsableExpression)
Gets or creates an RDFSClass based on a parsable expression. |
RDFSDatatype |
createRDFSDatatype(String name)
|
RDFSLiteral |
createRDFSLiteral(Object value)
Creates a new RDFSLiteral with a default datatype derived from the value. |
RDFSLiteral |
createRDFSLiteral(String lexicalValue,
RDFSDatatype datatype)
Creates a new RDFSLiteral with a given datatype. |
RDFSLiteral |
createRDFSLiteral(String value,
String language)
Creates a new string-typed literal with a given language. |
Object |
createRDFSLiteralOrString(String value,
String language)
Creates a new string-typed literal with a given language. |
RDFSNamedClass |
createRDFSNamedClass(String name)
|
RDFSNamedClass |
createRDFSNamedClass(String name,
boolean loadDefaults)
|
RDFSNamedClass |
createRDFSNamedClass(String name,
Collection parents,
RDFSClass rdfType)
Creates an RDFSNamedClass (or perhaps an OWLNamedClass) with given name, superclasses and rdf:type. |
RDFSNamedClass |
createRDFSNamedSubclass(String name,
RDFSNamedClass superclass)
Creates a new named OWL class which has exactly a given superclass. |
RDFUntypedResource |
createRDFUntypedResource(String uri)
Creates an untyped rdf:Resource for a given URI. |
RDFSNamedClass |
createSubclass(String name,
Collection superclasses)
Creates a subclass of a number of superclasses. |
RDFSNamedClass |
createSubclass(String name,
RDFSNamedClass superclass)
Creates a subclass of a superclass. |
RDFProperty |
createSubproperty(String name,
RDFProperty superproperty)
Creates a new property as a subproperty of an existing property. |
Triple |
createTriple(RDFResource subject,
RDFProperty predicate,
Object object)
Creates a new Triple. |
QueryResults |
executeSPARQLQuery(String partialQueryText)
Executes a SPARQL query on this OWLModel. |
Set |
getAllImports()
Gets all (transitive) imports in this OWLModel. |
edu.stanford.smi.protege.model.Cls |
getAnonymousRootCls()
Deprecated. internal Protege detail |
Collection |
getChangedInferredClasses()
Gets all named classes where the classification status is OWLNames.CLASSIFICATION_STATUS_CONSISTENT_AND_CHANGED, i.e. |
RDFSNamedClass |
getCommonSuperclass(Collection<RDFSNamedClass> classes)
Chooses a most specific common named superclass of a given collection of named classes. |
Set<RDFSNamedClass> |
getCommonSuperclasses(Collection<RDFSNamedClass> classes)
Gets the most specific common named superclasses of a given collection of named classes. |
String |
getDefaultLanguage()
Gets the default language specified by the user through an annotation property at owl:Ontology. |
OWLOntology |
getDefaultOWLOntology()
|
boolean |
getDispatchEventsEnabled()
|
Collection |
getDomainlessProperties()
Gets all properties that have owl:Thing as their domain. |
Set |
getFloatDatatypes()
Gets all float XML Schema datatypes, including xsd:float etc. |
boolean |
getGenerateEventsEnabled()
|
edu.stanford.smi.protege.model.framestore.FrameStore |
getHeadFrameStore()
Provides low level access to some internal Protege detail - normally not needed. |
Collection |
getInconsistentClasses()
Gets all classes which have been marked as inconsistent. |
Set |
getIntegerDatatypes()
Gets all integer XML Schema datatypes, including xsd:int etc. |
com.hp.hpl.jena.rdf.model.Model |
getJenaModel()
Gets a (read-only) Jena Model serving as a live view upon the Protege TripleStores. |
String |
getLocalNameForResourceName(String frameName)
|
String |
getLocalNameForURI(String uri)
Gets the local part of an URI, e.g. |
Collection |
getMatchingResources(RDFProperty property,
String matchString,
int maxMatches)
Gets all RDFResources that have a matching value for a given property. |
String |
getNamespaceForResourceName(String resourceName)
|
String |
getNamespaceForURI(String uri)
Gets the namespace part of a given URI. |
NamespaceManager |
getNamespaceManager()
Gets the NamespaceManager used by this knowledge base. |
String |
getNextAnonymousResourceName()
Gets the next name that can be used to create an "anonymous" instance. |
com.hp.hpl.jena.ontology.OntModel |
getOntModel()
|
RDFSNamedClass |
getOWLAllDifferentClass()
|
Collection |
getOWLAllDifferents()
Gets a collection of all OWLAllDifferents in the knowlegde base. |
Collection |
getOWLAnnotationProperties()
Gets all annotation properties. |
RDFSNamedClass |
getOWLAnnotationPropertyClass()
|
OWLClassDisplay |
getOWLClassDisplay()
Gets the currently used renderer for classes into display strings. |
OWLClassParser |
getOWLClassParser()
Gets the OWLClassParser for the current class expression syntax. |
RDFSNamedClass |
getOWLDataRangeClass()
Gets the class owl:DataRange, which is used to represent enumerations of datatype values. |
OWLDatatypeProperty |
getOWLDatatypeProperty(String name)
|
OWLNamedClass |
getOWLDatatypePropertyClass()
Gets the standard metaclass of all datatype slots/properties. |
RDFSNamedClass |
getOWLDeprecatedClassClass()
|
RDFProperty |
getOWLDifferentFromProperty()
|
RDFProperty |
getOWLDisjointWithProperty()
|
RDFProperty |
getOWLEquivalentClassProperty()
|
RDFProperty |
getOWLEquivalentPropertyProperty()
|
OWLFrameStore |
getOWLFrameStore()
Provides low level access to some internal Protege detail - normally not needed. |
RDFSNamedClass |
getOWLFunctionalPropertyClass()
|
OWLIndividual |
getOWLIndividual(String name)
|
Collection |
getOWLIndividuals()
Gets those Instances in the ontology that are instances of a OWLNamedClass. |
Collection |
getOWLIndividuals(boolean onlyVisibleClasses)
Gets those Instances in the ontology that are instances of a OWLNamedClass. |
RDFProperty |
getOWLIntersectionOfProperty()
|
RDFSNamedClass |
getOWLInverseFunctionalPropertyClass()
|
RDFProperty |
getOWLInverseOfProperty()
|
OWLJavaFactory |
getOWLJavaFactory()
Gets the OWLJavaFactory that is used to create the Java objects for ontology resources. |
OWLNamedClass |
getOWLNamedClass(String name)
A convenience method which includes the typecast after getCls(). |
OWLNamedClass |
getOWLNamedClassClass()
Gets the standard metaclass of all named classes. |
OWLNamedClass |
getOWLNothing()
Gets the system class owl:Nothing, which represents the empty set
for reasoners. |
OWLObjectProperty |
getOWLObjectProperty(String name)
|
OWLNamedClass |
getOWLObjectPropertyClass()
Gets the standard metaclass of all object slots/properties. |
RDFProperty |
getOWLOneOfProperty()
Gets the owl:oneOf property. |
Collection |
getOWLOntologies()
Gets all OWLOntologies in the current model. |
OWLOntology |
getOWLOntologyByURI(String uri)
Deprecated. use #getOWLOntologyByURI(URI uri) DO NOT PASS IN THE URI OF AN UNRESOLVED IMPORT AS THIS WILL CAUSE A Class Cast Exception |
RDFResource |
getOWLOntologyByURI(URI uri)
Gets the OWLOntology with a given URI. |
OWLNamedClass |
getOWLOntologyClass()
|
Collection |
getOWLOntologyProperties()
Gets the owl:OntologyProperties defined in OWL. |
OWLProject |
getOWLProject()
Gets the associated OWLProject, which can be used to store project-specific settings. |
OWLProperty |
getOWLProperty(String name)
A convenience method including typecast. |
RDFSNamedClass[] |
getOWLRestrictionMetaclasses()
Gets the metaclasses of the available OWLRestriction kinds. |
Collection |
getOWLRestrictionsOnProperty(RDFProperty property)
Gets a Collection of all Restrictions that are defined on a given property. |
RDFProperty |
getOWLSameAsProperty()
|
RDFSNamedClass |
getOWLSomeValuesFromRestrictionClass()
Gets the meta class that represents some values from restrictions. |
Collection |
getOWLSystemResources()
Gets a Collection of all system resources installed by the OWL Plugin. |
OWLNamedClass |
getOWLThingClass()
Gets the root class of the OWL class hierarchy (owl:Thing). |
RDFProperty |
getOWLUnionOfProperty()
|
RDFProperty |
getOWLValuesFromProperty()
Gets the owl:valuesFrom property (used for qualified cardinality restrictions. |
edu.stanford.smi.protege.model.ValueType |
getOWLValueType(String uri)
Gets the Protege ValueType that represents a given URI string. |
RDFProperty |
getOWLVersionInfoProperty()
|
String |
getPrefixForResourceName(String resourceName)
|
PropertyValueValidator |
getPropertyValueValidator()
Gets the currently used PropertyValueValidator. |
RDFProperty |
getProtegeAllowedParentProperty()
Gets the property protege:allowedParent (if it exists) |
RDFProperty |
getProtegeClassificationStatusProperty()
Gets the property that is used internally to store the classification status of a class. |
RDFProperty |
getProtegeInferredSubclassesProperty()
|
RDFProperty |
getProtegeInferredSuperclassesProperty()
|
OWLDatatypeProperty |
getProtegeReadOnlyProperty()
|
RDFProperty |
getProtegeSubclassesDisjointProperty()
|
RDFExternalResource |
getRDFExternalResource(String uri)
Deprecated. use getRDFUntypedResource instead |
RDFSClass |
getRDFExternalResourceClass()
Deprecated. use getRDFUntypedResourcesClass |
RDFProperty |
getRDFFirstProperty()
Gets the rdf:first property. |
RDFIndividual |
getRDFIndividual(String name)
|
Collection |
getRDFIndividuals()
Gets those Instances in the ontology that are instances of an RDFSNamedClass. |
Collection |
getRDFIndividuals(boolean onlyVisibleClasses)
Gets those Instances in the ontology that are instances of an RDFSNamedClass. |
RDFSNamedClass |
getRDFListClass()
Gets the rdf:List class. |
RDFList |
getRDFNil()
Gets the placeholder for empty rdf:Lists. |
Collection |
getRDFProperties()
Gets a collection of all RDFProperties (or subclasses thereof). |
RDFProperty |
getRDFProperty(String name)
A convenience method to access a slot as RDFProperty. |
RDFSNamedClass |
getRDFPropertyClass()
Gets the rdf:Property metaclass. |
RDFResource |
getRDFResource(String name)
Gets an RDFResource by its name. |
RDFResource |
getRDFResourceAs(String name,
Class javaInterface)
Combines the calls getRDFResource(name).as(javaInterface). |
RDFResource |
getRDFResourceByBrowserText(String text)
Gets the first resource that has a given browser text. |
RDFResource |
getRDFResourceByNameOrBrowserText(String text)
Gets the first instance that has a given name or browser text. |
int |
getRDFResourceCount()
Gets the number of all RDFResources in this model. |
Collection |
getRDFResources()
Gets a list of all RDFResources in this model. |
Collection |
getRDFResourcesWithPropertyValue(RDFProperty property,
Object value)
Gets all RDFResources that have a given value for a given property. |
RDFProperty |
getRDFRestProperty()
Gets the rdf:rest property, which is used to describe the rest of an rdf:List. |
int |
getRDFSClassCount()
Gets the number of rdfs:Classes (or owl:Classes) in this model, including anonymous classes and system classes. |
Collection |
getRDFSClasses()
Gets all rdfs:Classes (or owl:Classes) in this model, including anonymous classes and system classes. |
OWLDatatypeProperty |
getRDFSCommentProperty()
|
RDFSDatatype |
getRDFSDatatypeByName(String name)
Gets an XML Schema Datatype using the prefix notation (e.g. |
RDFSDatatype |
getRDFSDatatypeByURI(String uri)
Gets an XML Schema Datatype by its URI (e.g. |
RDFSDatatypeFactory |
getRDFSDatatypeFactory()
|
RDFSDatatype |
getRDFSDatatypeOfValue(Object valueOrRDFSLiteral)
Gets the RDFSDatatype of a given primitive value, which can be either a standard value (e.g. |
Collection |
getRDFSDatatypes()
Gets a Collection of the (named) RDF/XML Schema datatypes. |
RDFProperty |
getRDFSDomainProperty()
Gets the rdfs:domain property. |
RDFProperty |
getRDFSIsDefinedByProperty()
|
RDFProperty |
getRDFSLabelProperty()
|
RDFSNamedClass |
getRDFSNamedClass(String name)
& |