|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.lehigh.swat.hawk.storage.simplememory.Document
edu.lehigh.swat.hawk.storage.simplememory.Ontology
public class Ontology
A simple implementation of core.ontology in memory.
Field Summary |
---|
Fields inherited from class edu.lehigh.swat.hawk.storage.simplememory.Document |
---|
assertions, comments, distinctSets, docId, imports, individuals, label, nameSpaces, sameSets, size, xmlBase |
Fields inherited from interface edu.lehigh.swat.hawk.core.Ontology |
---|
ALLVALUERESTRICTION, ATOMICNODE, CARDINALITYRESTRICTION, COMPLEMENTOF, DISJOINTWITH, EQUIVALENTCLASS, EQUIVALENTPROPERTY, HASVALUERESTRICTION, INTERSECTIONOF, INVERSEOF, ONEOF, SOMEVALUERESTRICTION, SUBCLASSOF, SUBPROPERTYOF, UNIONOF |
Constructor Summary | |
---|---|
Ontology()
Constructor |
Method Summary | |
---|---|
void |
addAllAxiomNodeRestrictions(java.util.Vector<AxiomNode> res)
|
void |
addAssertedClass(ObjectId cid)
Add an asserted class. |
void |
addAssertedProperty(ObjectId pid)
Add an asserted property. |
void |
addAxiom(Axiom a)
Axiom Design Methods |
void |
addAxiomByObject(ObjectId obj,
Axiom a)
|
void |
addAxiomBySubject(ObjectId sub,
Axiom a)
|
void |
addAxiomByType(java.lang.Integer type,
Axiom a)
|
void |
addAxiomNodeRestriction(AxiomNode res)
|
void |
addCompatiblePriorOnts(DocId id)
Add a priorVersion ontology which is backwardCompatibleWith. |
void |
addImportedClass(ObjectId cid,
OntClass c)
Add an imported class. |
void |
addImportedProperty(ObjectId pid,
OntProperty p)
Add an imported property. |
void |
addOntClass(OntClass c)
add a class to this ontology |
void |
addPriorOnts(DocId id)
Add a priorVersion ontology may be incompatibleWith. |
void |
addProperty(OntProperty p)
add a property to this ontology |
void |
addRestriction(PropertyRestriction p)
add a property to this ontology |
boolean |
assertedClass(ObjectId cid)
To tell if the ontology asserted specified class. |
boolean |
assertedProperty(ObjectId pid)
To tell if the ontology asserted specified property. |
OntClass |
createClass()
Create a Class object and set its ontology. |
OntProperty |
createProperty()
Create a Property object and set its ontology. |
PropertyRestriction |
createRestriction()
Create a PropertyRestriction object and set its ontology. |
void |
deleteCompatiblePriorOnts(DocId id)
Delete a priorVersion ontology which is backwardCompatibleWith. |
void |
deleteOntClass(ObjectId id)
delete the specified class |
void |
deletePriorOnts(DocId id)
Delete a priorVersion ontology may be incompatibleWith. |
void |
deleteProperty(ObjectId id)
delete a specified property |
void |
deleteRestriction(ObjectId id)
delete a specified property |
java.util.List<Axiom> |
getAllAxioms()
|
java.util.Hashtable<ObjectId,java.util.Vector<Axiom>> |
getAllAxiomsByObject()
|
java.util.Hashtable<ObjectId,java.util.Vector<Axiom>> |
getAllAxiomsBySubject()
|
java.util.Hashtable<java.lang.Integer,java.util.Vector<Axiom>> |
getAllAxiomsByType()
|
OntClass[] |
getAllClasses()
get all the classes in this ontology |
OntClass[] |
getAllPlusImportedClasses()
Get All the classes plus the imported Classes. |
OntProperty[] |
getAllPlusImportedProperties()
Get All the classes plus the imported properties. |
OntProperty[] |
getAllProperties()
get all the properties in this ontology |
PropertyRestriction[] |
getAllRestrictions()
get all the properties in this ontology |
java.util.List<Axiom> |
getAxiomByObject(ObjectId object)
|
java.util.List<Axiom> |
getAxiomBySubject(ObjectId subject)
|
java.util.List<Axiom> |
getAxiomByType(java.lang.Integer type)
|
java.util.Vector<AxiomNode> |
getAxiomNodeRestrictions()
|
int |
getClassIndex(ObjectId cid)
get the index number for a class |
java.util.Iterator |
getClassIterator()
Get the Iterator of all the classes. |
DocId[] |
getCompatiblePriorOnts()
Get the priorVersion ontologies which are backwardCompatibleWith |
OntClass |
getOntClass(ObjectId id)
get the specified class |
OntObject |
getOntObject(ObjectId id)
get the object (class/property) given the ID |
DocId[] |
getPriorOnts()
Get the priorVersion ontologies may be incompatibleWith |
OntProperty |
getProperty(ObjectId id)
get the specified property |
int |
getPropertyIndex(ObjectId pid)
get the index number for a property |
java.util.Iterator |
getPropertyIterator()
Get the Iterator of all the properties. |
PropertyRestriction |
getRestriction(ObjectId id)
get the specified property |
java.lang.String |
getVersion()
get the version of this ontology |
boolean |
hasClass(java.lang.String name)
To see if ontology has the class. |
boolean |
hasProperty(java.lang.String name)
To see if ontology has the property. |
boolean |
importedClass(ObjectId cid)
To tell if the ontology imorted specified class. |
boolean |
importedProperty(ObjectId pid)
To tell if the ontology imported specified property. |
void |
setVersion(java.lang.String ver)
Set the version of this ontology. |
Methods inherited from class edu.lehigh.swat.hawk.storage.simplememory.Document |
---|
addAssertion, addDescription, addDistinctIndividualsSet, addImports, addIndividual, addSameIndividualsSet, createIndividual, deleteAllIndividual, deleteAssertion, deleteDescriprion, deleteDistinctIndividualsSet, deleteImports, deleteIndividual, deleteSameIndividualsSet, equals, flush, getAllAssertions, getAllDescriptions, getAllIndividuals, getAssertionIterator, getDescendants, getDescription, getDistinctIndividualsSets, getID, getImports, getIndividual, getIndividualIterator, getLabel, getNameSpaces, getSameIndividualsSets, getSize, getXMLBase, setDescendants, setID, setLabel, setNameSpaces, setSize, setXMLBase |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Ontology()
Method Detail |
---|
public void addAxiom(Axiom a)
Ontology
addAxiom
in interface Ontology
public java.util.List<Axiom> getAllAxioms()
getAllAxioms
in interface Ontology
public java.util.Hashtable<ObjectId,java.util.Vector<Axiom>> getAllAxiomsBySubject()
getAllAxiomsBySubject
in interface Ontology
public java.util.Hashtable<java.lang.Integer,java.util.Vector<Axiom>> getAllAxiomsByType()
getAllAxiomsByType
in interface Ontology
public java.util.Hashtable<ObjectId,java.util.Vector<Axiom>> getAllAxiomsByObject()
getAllAxiomsByObject
in interface Ontology
public void addAxiomBySubject(ObjectId sub, Axiom a)
addAxiomBySubject
in interface Ontology
public void addAxiomByObject(ObjectId obj, Axiom a)
addAxiomByObject
in interface Ontology
public void addAxiomByType(java.lang.Integer type, Axiom a)
addAxiomByType
in interface Ontology
public java.util.List<Axiom> getAxiomBySubject(ObjectId subject)
getAxiomBySubject
in interface Ontology
public java.util.List<Axiom> getAxiomByObject(ObjectId object)
getAxiomByObject
in interface Ontology
public java.util.List<Axiom> getAxiomByType(java.lang.Integer type)
getAxiomByType
in interface Ontology
public java.util.Vector<AxiomNode> getAxiomNodeRestrictions()
getAxiomNodeRestrictions
in interface Ontology
public void addAxiomNodeRestriction(AxiomNode res)
addAxiomNodeRestriction
in interface Ontology
public void addAllAxiomNodeRestrictions(java.util.Vector<AxiomNode> res)
addAllAxiomNodeRestrictions
in interface Ontology
public void addOntClass(OntClass c)
addOntClass
in interface Ontology
public int getClassIndex(ObjectId cid)
public OntObject getOntObject(ObjectId id)
getOntObject
in interface Ontology
public OntClass getOntClass(ObjectId id)
getOntClass
in interface Ontology
public void deleteOntClass(ObjectId id)
deleteOntClass
in interface Ontology
public OntClass[] getAllClasses()
getAllClasses
in interface Ontology
public java.util.Iterator getClassIterator()
getClassIterator
in interface Ontology
public void addProperty(OntProperty p)
addProperty
in interface Ontology
public int getPropertyIndex(ObjectId pid)
public OntProperty getProperty(ObjectId id)
getProperty
in interface Ontology
public void deleteProperty(ObjectId id)
deleteProperty
in interface Ontology
public OntProperty[] getAllProperties()
getAllProperties
in interface Ontology
public java.util.Iterator getPropertyIterator()
getPropertyIterator
in interface Ontology
public void addRestriction(PropertyRestriction p)
addRestriction
in interface Ontology
public PropertyRestriction getRestriction(ObjectId id)
getRestriction
in interface Ontology
public void deleteRestriction(ObjectId id)
deleteRestriction
in interface Ontology
public PropertyRestriction[] getAllRestrictions()
getAllRestrictions
in interface Ontology
public DocId[] getCompatiblePriorOnts()
getCompatiblePriorOnts
in interface Ontology
public void addCompatiblePriorOnts(DocId id)
addCompatiblePriorOnts
in interface Ontology
public void deleteCompatiblePriorOnts(DocId id)
deleteCompatiblePriorOnts
in interface Ontology
public DocId[] getPriorOnts()
getPriorOnts
in interface Ontology
public void addPriorOnts(DocId id)
addPriorOnts
in interface Ontology
public void deletePriorOnts(DocId id)
deletePriorOnts
in interface Ontology
public java.lang.String getVersion()
getVersion
in interface Ontology
public void setVersion(java.lang.String ver)
setVersion
in interface Ontology
public OntClass createClass()
createClass
in interface Ontology
public OntProperty createProperty()
createProperty
in interface Ontology
public PropertyRestriction createRestriction()
createRestriction
in interface Ontology
public boolean hasClass(java.lang.String name)
hasClass
in interface Ontology
public boolean hasProperty(java.lang.String name)
hasProperty
in interface Ontology
public void addImportedClass(ObjectId cid, OntClass c)
addImportedClass
in interface Ontology
public void addImportedProperty(ObjectId pid, OntProperty p)
addImportedProperty
in interface Ontology
public OntClass[] getAllPlusImportedClasses()
getAllPlusImportedClasses
in interface Ontology
public OntProperty[] getAllPlusImportedProperties()
getAllPlusImportedProperties
in interface Ontology
public boolean importedClass(ObjectId cid)
importedClass
in interface Ontology
public boolean importedProperty(ObjectId pid)
importedProperty
in interface Ontology
public boolean assertedClass(ObjectId cid)
assertedClass
in interface Ontology
public boolean assertedProperty(ObjectId pid)
assertedProperty
in interface Ontology
public void addAssertedClass(ObjectId cid)
addAssertedClass
in interface Ontology
public void addAssertedProperty(ObjectId pid)
addAssertedProperty
in interface Ontology
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |