|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.mindswap.pellet.KnowledgeBase
public class KnowledgeBase
Nested Class Summary | |
---|---|
static class |
KnowledgeBase.AssertionType
|
static class |
KnowledgeBase.ChangeType
|
Field Summary | |
---|---|
static java.util.logging.Logger |
log
|
Timers |
timers
Timers used in various different parts of KB. |
Constructor Summary | |
---|---|
KnowledgeBase()
|
Method Summary | |
---|---|
void |
addAllDifferent(aterm.ATermList list)
|
boolean |
addAnnotation(aterm.ATermAppl s,
aterm.ATermAppl p,
aterm.ATermAppl o)
|
boolean |
addAnnotationProperty(aterm.ATerm p)
|
void |
addAntisymmetricProperty(aterm.ATermAppl p)
Deprecated. Use addAsymmetricProperty(ATermAppl) |
void |
addAsymmetricProperty(aterm.ATermAppl p)
|
void |
addClass(aterm.ATermAppl c)
|
void |
addComplementClass(aterm.ATermAppl c1,
aterm.ATermAppl c2)
|
void |
addDataPropertyValue(aterm.ATermAppl p,
aterm.ATermAppl s,
aterm.ATermAppl o)
Deprecated. Use addPropertyValue instead |
void |
addDatatype(aterm.ATermAppl p)
|
boolean |
addDatatypeDefinition(aterm.ATermAppl name,
aterm.ATermAppl datarange)
Adds a new datatype defined to be equivalent to the given data range expression. |
boolean |
addDatatypeProperty(aterm.ATerm p)
Add a new object property. |
void |
addDifferent(aterm.ATermAppl i1,
aterm.ATermAppl i2)
|
void |
addDisjointClass(aterm.ATermAppl c1,
aterm.ATermAppl c2)
|
void |
addDisjointClasses(aterm.ATermList classes)
|
void |
addDisjointClasses(java.util.List<aterm.ATermAppl> classes)
|
void |
addDisjointProperties(aterm.ATermList properties)
|
void |
addDisjointProperties(java.util.List<aterm.ATermAppl> properties)
|
void |
addDisjointProperty(aterm.ATermAppl p1,
aterm.ATermAppl p2)
|
void |
addDisjointProperty(aterm.ATermAppl p1,
aterm.ATermAppl p2,
DependencySet ds)
|
void |
addDomain(aterm.ATerm p,
aterm.ATermAppl c)
|
void |
addDomain(aterm.ATerm p,
aterm.ATermAppl c,
java.util.Set<aterm.ATermAppl> explain)
For internal use when domain axioms come from TBox absorption |
void |
addEquivalentClass(aterm.ATermAppl c1,
aterm.ATermAppl c2)
|
void |
addEquivalentProperty(aterm.ATermAppl p1,
aterm.ATermAppl p2)
|
void |
addFunctionalProperty(aterm.ATermAppl p)
|
Individual |
addIndividual(aterm.ATermAppl i)
|
void |
addInverseFunctionalProperty(aterm.ATerm p)
|
void |
addInverseProperty(aterm.ATermAppl p1,
aterm.ATermAppl p2)
|
void |
addIrreflexiveProperty(aterm.ATermAppl p)
|
void |
addKey(aterm.ATermAppl c,
java.util.Set<aterm.ATermAppl> properties)
|
boolean |
addNegatedPropertyValue(aterm.ATermAppl p,
aterm.ATermAppl s,
aterm.ATermAppl o)
|
boolean |
addObjectProperty(aterm.ATerm p)
Add a new object property. |
void |
addObjectPropertyValue(aterm.ATermAppl p,
aterm.ATermAppl s,
aterm.ATermAppl o)
Deprecated. Use addPropertyValue instead |
void |
addOntologyProperty(aterm.ATermAppl p)
Deprecated. |
void |
addProperty(aterm.ATermAppl p)
|
boolean |
addPropertyValue(aterm.ATermAppl p,
aterm.ATermAppl s,
aterm.ATermAppl o)
|
void |
addRange(aterm.ATerm p,
aterm.ATermAppl c)
|
void |
addRange(aterm.ATerm p,
aterm.ATermAppl c,
java.util.Set<aterm.ATermAppl> explain)
For internal use when range axioms come from TBox absorption |
void |
addReflexiveProperty(aterm.ATermAppl p)
|
boolean |
addRule(Rule rule)
Add a rule to the KB. |
void |
addSame(aterm.ATermAppl i1,
aterm.ATermAppl i2)
|
void |
addSubClass(aterm.ATermAppl sub,
aterm.ATermAppl sup)
|
void |
addSubProperty(aterm.ATerm sub,
aterm.ATermAppl sup)
|
void |
addSymmetricProperty(aterm.ATermAppl p)
|
void |
addTransitiveProperty(aterm.ATermAppl p)
|
void |
addType(aterm.ATermAppl i,
aterm.ATermAppl c)
|
void |
addType(aterm.ATermAppl i,
aterm.ATermAppl c,
DependencySet ds)
|
void |
binaryInstanceRetrieval(aterm.ATermAppl c,
java.util.List<aterm.ATermAppl> candidates,
java.util.Collection<aterm.ATermAppl> results)
|
void |
classify()
|
void |
clear()
|
KnowledgeBase |
copy()
Create a copy of this KB with a completely new ABox copy but pointing to the same RBox and TBox. |
KnowledgeBase |
copy(boolean emptyABox)
Create a copy of this KB. |
boolean |
doExplanation()
|
void |
ensureConsistency()
|
void |
ensureIncConsistency(boolean aboxDeletion)
|
ABox |
getABox()
|
java.util.Set<aterm.ATermAppl> |
getABoxAssertions(KnowledgeBase.AssertionType assertionType)
|
java.util.Set<aterm.ATermAppl> |
getAboxDataRoleAssertions()
Deprecated. Use getABoxAssertions(org.mindswap.pellet.KnowledgeBase.AssertionType)
instead |
java.util.Set<aterm.ATermAppl> |
getAboxMembershipAssertions()
Deprecated. Use getABoxAssertions(org.mindswap.pellet.KnowledgeBase.AssertionType)
instead |
java.util.Set<aterm.ATermAppl> |
getAboxObjectRoleAssertions()
Deprecated. Use getABoxAssertions(org.mindswap.pellet.KnowledgeBase.AssertionType)
instead |
java.util.Set<aterm.ATermAppl> |
getAllClasses()
Return the set of all named classes including TOP and BOTTOM. |
java.util.Set<aterm.ATermAppl> |
getAllEquivalentClasses(aterm.ATermAppl c)
Returns all the classes that are equivalent to class c, including c itself. |
java.util.Set<aterm.ATermAppl> |
getAllEquivalentProperties(aterm.ATermAppl prop)
|
java.util.Set<aterm.ATermAppl> |
getAllSames(aterm.ATermAppl name)
Return all the indviduals asserted to be equal to the given individual inluding the individual itself. |
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getAllSubProperties(aterm.ATermAppl prop)
|
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getAllSuperProperties(aterm.ATermAppl prop)
|
java.util.Set<aterm.ATermAppl> |
getAllUnsatisfiableClasses()
Returns all unsatisfiable classes in the KB including the BOTTOM concept. |
java.util.Set<aterm.ATermAppl> |
getAnnotationProperties()
|
java.util.Set<aterm.ATermAppl> |
getAnnotations(aterm.ATermAppl s,
aterm.ATermAppl p)
|
java.util.Set<aterm.ATermAppl> |
getAnnotationSubjects()
Returns the set of key values of the annotations map |
java.util.Set<aterm.ATermAppl> |
getAntisymmetricProperties()
Deprecated. Use getAntisymmetricProperties() |
java.util.Set<aterm.ATermAppl> |
getAsymmetricProperties()
|
java.util.Set<aterm.ATermAppl> |
getClasses()
Return the set of all named classes. |
java.util.Set<aterm.ATermAppl> |
getComplements(aterm.ATermAppl c)
|
java.util.Set<aterm.ATermAppl> |
getDataProperties()
Return the set of all object properties. |
java.util.List<aterm.ATermAppl> |
getDataPropertyValues(aterm.ATermAppl r,
aterm.ATermAppl x)
Return all literal values for a given dataproperty and subject value. |
java.util.List<aterm.ATermAppl> |
getDataPropertyValues(aterm.ATermAppl r,
aterm.ATermAppl x,
aterm.ATermAppl datatype)
Return all literal values for a given dataproperty that belongs to the specified datatype. |
java.util.List<aterm.ATermAppl> |
getDataPropertyValues(aterm.ATermAppl r,
aterm.ATermAppl x,
java.lang.String lang)
Return all literal values for a given dataproperty that has the specified language identifier. |
DatatypeReasoner |
getDatatypeReasoner()
|
java.util.Set<aterm.ATermAppl> |
getDeletedAssertions()
|
DependencyIndex |
getDependencyIndex()
Get the dependency index for syntactic assertions in this kb |
java.util.Set<aterm.ATermAppl> |
getDifferents(aterm.ATermAppl name)
|
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getDisjointClasses(aterm.ATermAppl c)
|
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getDisjointClasses(aterm.ATermAppl c,
boolean direct)
|
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getDisjointProperties(aterm.ATermAppl p)
|
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getDisjointProperties(aterm.ATermAppl p,
boolean direct)
|
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getDisjoints(aterm.ATermAppl c)
|
boolean |
getDoDependencyAxioms()
Deprecated. Use getExplanation instead |
java.util.Set<aterm.ATermAppl> |
getDomains(aterm.ATermAppl name)
Return the domain restrictions on the property. |
java.util.Set<aterm.ATermAppl> |
getEquivalentClasses(aterm.ATermAppl c)
Returns all the classes that are equivalent to class c, excluding c itself. |
java.util.Set<aterm.ATermAppl> |
getEquivalentProperties(aterm.ATermAppl prop)
Return all the properties that are equivalent to p. |
java.lang.String |
getExplanation()
|
java.util.Set<aterm.ATermAppl> |
getExplanationSet()
|
Expressivity |
getExpressivity()
|
ExpressivityChecker |
getExpressivityChecker()
|
java.util.Set<aterm.ATermAppl> |
getFunctionalProperties()
|
java.util.Set<aterm.ATermAppl> |
getIndividuals()
Return the set of all individuals. |
java.util.Set<aterm.ATermAppl> |
getIndividualsWithAnnotation(aterm.ATermAppl p,
aterm.ATermAppl o)
|
java.util.List<aterm.ATermAppl> |
getIndividualsWithDataProperty(aterm.ATermAppl r,
aterm.ATermAppl litValue)
List all subjects with the given literal value for the specified data property. |
java.util.List<aterm.ATermAppl> |
getIndividualsWithObjectProperty(aterm.ATermAppl r,
aterm.ATermAppl o)
List all subjects with the given value for the specified object property. |
java.util.List<aterm.ATermAppl> |
getIndividualsWithProperty(aterm.ATermAppl r,
aterm.ATermAppl x)
List all subjects with a given property and property value. |
java.lang.String |
getInfo()
|
java.util.Set<aterm.ATermAppl> |
getInstances(aterm.ATermAppl c)
Returns all the instances of concept c. |
java.util.Set<aterm.ATermAppl> |
getInstances(aterm.ATermAppl c,
boolean direct)
Returns the instances of class c. |
aterm.ATermAppl |
getInverse(aterm.ATerm name)
Returns the inverse of given property. |
java.util.Set<aterm.ATermAppl> |
getInverseFunctionalProperties()
|
java.util.Set<aterm.ATermAppl> |
getInverses(aterm.ATerm name)
Return the named inverse property and all its equivalent properties. |
java.util.Set<aterm.ATermAppl> |
getIrreflexiveProperties()
|
java.util.Map<Rule,Rule> |
getNormalizedRules()
Return the asserted rules with their normalized form. |
java.util.Set<aterm.ATermAppl> |
getObjectProperties()
Return the set of all object properties. |
java.util.List<aterm.ATermAppl> |
getObjectPropertyValues(aterm.ATermAppl r,
aterm.ATermAppl x)
Return all property values for a given object property and subject value. |
java.util.Set<aterm.ATermAppl> |
getProperties()
Return the set of all properties. |
java.util.List<aterm.ATermAppl> |
getProperties(aterm.ATermAppl s,
aterm.ATermAppl o)
List all properties asserted between a subject and object. |
Role |
getProperty(aterm.ATerm r)
|
PropertyType |
getPropertyType(aterm.ATerm r)
|
java.util.Map<aterm.ATermAppl,java.util.List<aterm.ATermAppl>> |
getPropertyValues(aterm.ATermAppl pred)
|
java.util.List<aterm.ATermAppl> |
getPropertyValues(aterm.ATermAppl r,
aterm.ATermAppl x)
Return all property values for a given property and subject value. |
java.util.Set<aterm.ATermAppl> |
getRanges(aterm.ATerm name)
Return the domain restrictions on the property. |
RBox |
getRBox()
|
java.util.Set<aterm.ATermAppl> |
getReflexiveProperties()
|
Role |
getRole(aterm.ATerm term)
|
Taxonomy<aterm.ATermAppl> |
getRoleTaxonomy(aterm.ATermAppl r)
|
Taxonomy<aterm.ATermAppl> |
getRoleTaxonomy(boolean objectTaxonomy)
|
java.util.Set<Rule> |
getRules()
Return all the asserted rules. |
java.util.Set<aterm.ATermAppl> |
getSames(aterm.ATermAppl name)
Return all the individuals asserted to be equal to the given individual but not the the individual itself. |
SizeEstimate |
getSizeEstimate()
|
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getSubClasses(aterm.ATermAppl c)
Returns all the (named) subclasses of class c. |
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getSubClasses(aterm.ATermAppl c,
boolean direct)
Returns the (named) subclasses of class c. |
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getSubProperties(aterm.ATermAppl prop)
Return all the sub properties of p. |
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getSubProperties(aterm.ATermAppl prop,
boolean direct)
Return the sub properties of p. |
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getSuperClasses(aterm.ATermAppl c)
Returns all the superclasses (implicitly or explicitly defined) of class c. |
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getSuperClasses(aterm.ATermAppl c,
boolean direct)
Returns the (named) superclasses of class c. |
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getSuperProperties(aterm.ATermAppl prop)
Return all the super properties of p. |
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getSuperProperties(aterm.ATermAppl prop,
boolean direct)
Return the super properties of p. |
java.util.Set<aterm.ATermAppl> |
getSymmetricProperties()
|
java.util.Set<aterm.ATermAppl> |
getSyntacticAssertions()
Get syntactic assertions in the kb |
Taxonomy<aterm.ATermAppl> |
getTaxonomy()
Get the classification results. |
TaxonomyBuilder |
getTaxonomyBuilder()
|
TBox |
getTBox()
|
java.util.Map<aterm.ATermAppl,java.util.Set<aterm.ATermAppl>> |
getToldDisjoints()
|
Taxonomy<aterm.ATermAppl> |
getToldTaxonomy()
|
java.util.Set<aterm.ATermAppl> |
getTransitiveProperties()
|
aterm.ATermAppl |
getType(aterm.ATermAppl ind)
|
aterm.ATermAppl |
getType(aterm.ATermAppl ind,
boolean direct)
|
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getTypes(aterm.ATermAppl ind)
Get all the (named) classes individual belongs to. |
java.util.Set<java.util.Set<aterm.ATermAppl>> |
getTypes(aterm.ATermAppl ind,
boolean direct)
Returns the (named) classes individual belongs to. |
java.util.Set<aterm.ATermAppl> |
getUnsatisfiableClasses()
Returns all unsatisfiable classes in the KB excluding the BOTTOM concept. |
boolean |
hasDomain(aterm.ATermAppl p,
aterm.ATermAppl c)
|
boolean |
hasInstance(aterm.ATerm d)
Returns true if there is at least one named individual that belongs to the given class |
Bool |
hasKnownPropertyValue(aterm.ATermAppl s,
aterm.ATermAppl p,
aterm.ATermAppl o)
Answers the hasPropertyValue question without doing any satisfiability check. |
boolean |
hasPropertyValue(aterm.ATermAppl s,
aterm.ATermAppl p,
aterm.ATermAppl o)
|
boolean |
hasRange(aterm.ATermAppl p,
aterm.ATermAppl c)
|
boolean |
isABoxChanged()
|
boolean |
isABoxProperty(aterm.ATerm p)
|
boolean |
isAnnotation(aterm.ATermAppl s,
aterm.ATermAppl p,
aterm.ATermAppl o)
|
boolean |
isAnnotationProperty(aterm.ATerm p)
|
boolean |
isAntisymmetricProperty(aterm.ATermAppl p)
Deprecated. Use isAsymmetricProperty(ATermAppl) |
boolean |
isAsymmetricProperty(aterm.ATermAppl p)
|
boolean |
isChanged()
|
boolean |
isChanged(KnowledgeBase.ChangeType change)
|
boolean |
isClass(aterm.ATerm c)
|
boolean |
isClassified()
Returns true if the classification check has been done and nothing in the KB has changed after that. |
boolean |
isComplement(aterm.ATermAppl c1,
aterm.ATermAppl c2)
|
boolean |
isConsistencyDone()
Returns true if the consistency check has been done and nothing in th KB has changed after that. |
boolean |
isConsistent()
|
boolean |
isDatatype(aterm.ATermAppl c)
|
boolean |
isDatatypeProperty(aterm.ATerm p)
|
boolean |
isDifferentFrom(aterm.ATermAppl t1,
aterm.ATermAppl t2)
|
boolean |
isDisjoint(aterm.ATermAppl c1,
aterm.ATermAppl c2)
|
boolean |
isDisjointClass(aterm.ATermAppl c1,
aterm.ATermAppl c2)
|
boolean |
isDisjointProperty(aterm.ATermAppl r1,
aterm.ATermAppl r2)
|
boolean |
isEquivalentClass(aterm.ATermAppl c1,
aterm.ATermAppl c2)
Check if class c1 is equivalent to class c2. |
boolean |
isEquivalentProperty(aterm.ATermAppl p1,
aterm.ATermAppl p2)
|
boolean |
isExplainOnlyInconsistency()
Returns current value of explainOnlyInconsistency option. |
boolean |
isFunctionalProperty(aterm.ATermAppl p)
|
boolean |
isIndividual(aterm.ATerm ind)
|
boolean |
isInverse(aterm.ATermAppl r1,
aterm.ATermAppl r2)
|
boolean |
isInverseFunctionalProperty(aterm.ATermAppl p)
|
boolean |
isIrreflexiveProperty(aterm.ATermAppl p)
|
Bool |
isKnownType(aterm.ATermAppl x,
aterm.ATermAppl c)
Answers the isType question without doing any satisfiability check. |
boolean |
isObjectProperty(aterm.ATerm p)
|
boolean |
isOntologyProperty(aterm.ATerm p)
Deprecated. |
boolean |
isProperty(aterm.ATerm p)
|
boolean |
isRBoxChanged()
|
boolean |
isRealized()
|
boolean |
isReflexiveProperty(aterm.ATermAppl p)
|
boolean |
isSameAs(aterm.ATermAppl t1,
aterm.ATermAppl t2)
|
boolean |
isSatisfiable(aterm.ATermAppl c)
|
boolean |
isSubClassOf(aterm.ATermAppl c1,
aterm.ATermAppl c2)
Check if class c1 is subclass of class c2. |
boolean |
isSubPropertyOf(aterm.ATermAppl sub,
aterm.ATermAppl sup)
|
boolean |
isSymmetricProperty(aterm.ATermAppl p)
|
boolean |
isTBoxChanged()
|
boolean |
isTransitiveProperty(aterm.ATermAppl r)
|
boolean |
isType(aterm.ATermAppl x,
aterm.ATermAppl c)
|
void |
linearInstanceRetrieval(aterm.ATermAppl c,
java.util.List<aterm.ATermAppl> candidates,
java.util.Collection<aterm.ATermAppl> results)
|
void |
loadKRSS(java.io.Reader reader)
|
void |
prepare()
|
void |
printClassTree()
Print the class hierarchy on the standard output. |
void |
printClassTree(java.io.PrintWriter out)
|
void |
realize()
|
boolean |
removeAxiom(aterm.ATermAppl axiom)
Removes (if possible) the given TBox axiom from the KB and return true if removal was successful. |
boolean |
removeDomain(aterm.ATerm p,
aterm.ATermAppl c)
Removes (if possible) the given property domain axiom from the KB and return true if removal was successful. |
boolean |
removePropertyValue(aterm.ATermAppl p,
aterm.ATermAppl i1,
aterm.ATermAppl i2)
|
boolean |
removeRange(aterm.ATerm p,
aterm.ATermAppl c)
Removes (if possible) the given property range axiom from the KB and return true if removal was successful. |
boolean |
removeType(aterm.ATermAppl ind,
aterm.ATermAppl c)
|
java.util.Set<aterm.ATermAppl> |
retrieve(aterm.ATermAppl d,
java.util.Collection<aterm.ATermAppl> individuals)
Return all the individuals that belong to the given class which is not necessarily a named class. |
java.util.List<aterm.ATermAppl> |
retrieveIndividualsWithProperty(aterm.ATermAppl r)
Retrieve individuals which possibly have a property value for the given property. |
void |
setDoDependencyAxioms(boolean doDepAxioms)
Deprecated. Use setDoExplanation instead |
void |
setDoExplanation(boolean doExplanation)
|
void |
setExplainOnlyInconsistency(boolean explainOnlyInconsistency)
Controls what kind of explanations can be generated using this KB. |
void |
setRBox(RBox rbox)
|
void |
setTaxonomyBuilderProgressMonitor(ProgressMonitor progressMonitor)
|
void |
setTBox(TBox tbox)
|
void |
setTimeout(long timeout)
Set a timeout for the main timer. |
void |
tracingBasedInstanceRetrieval(aterm.ATermAppl c,
java.util.List<aterm.ATermAppl> candidates,
java.util.Collection<aterm.ATermAppl> results)
|
void |
updateExpressivity(aterm.ATermAppl i,
aterm.ATermAppl c)
This method is used for incremental reasoning. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.util.logging.Logger log
public Timers timers
Constructor Detail |
---|
public KnowledgeBase()
Method Detail |
---|
public Expressivity getExpressivity()
public ExpressivityChecker getExpressivityChecker()
public void clear()
public KnowledgeBase copy()
public KnowledgeBase copy(boolean emptyABox)
emptyABox
either a completely new copy of ABox will be
created or the new KB will have an empty ABox. If emptyABox
parameter is true but the original KB contains nominals in its RBox or
TBox the new KB will have the definition of those individuals (but not )
In either case, the new KB will point to the same RBox and TBox so
changing one KB's RBox or TBox will affect other.
emptyABox
- If true
ABox is not copied to the new KB
public void loadKRSS(java.io.Reader reader) throws java.io.IOException
java.io.IOException
public void addClass(aterm.ATermAppl c)
public void addSubClass(aterm.ATermAppl sub, aterm.ATermAppl sup)
public void addEquivalentClass(aterm.ATermAppl c1, aterm.ATermAppl c2)
public void addKey(aterm.ATermAppl c, java.util.Set<aterm.ATermAppl> properties)
public void addDisjointClasses(aterm.ATermList classes)
public void addDisjointClasses(java.util.List<aterm.ATermAppl> classes)
public void addDisjointClass(aterm.ATermAppl c1, aterm.ATermAppl c2)
public void addComplementClass(aterm.ATermAppl c1, aterm.ATermAppl c2)
public void addDataPropertyValue(aterm.ATermAppl p, aterm.ATermAppl s, aterm.ATermAppl o)
p
- Datatype Propertyind
- Individual value being added toliteralValue
- A literal ATerm which should be constructed with one of
ATermUtils.makeXXXLiteral functionspublic Individual addIndividual(aterm.ATermAppl i)
public void addType(aterm.ATermAppl i, aterm.ATermAppl c)
public void addType(aterm.ATermAppl i, aterm.ATermAppl c, DependencySet ds)
public void addSame(aterm.ATermAppl i1, aterm.ATermAppl i2)
public void addAllDifferent(aterm.ATermList list)
public void addDifferent(aterm.ATermAppl i1, aterm.ATermAppl i2)
public void addObjectPropertyValue(aterm.ATermAppl p, aterm.ATermAppl s, aterm.ATermAppl o)
public boolean addPropertyValue(aterm.ATermAppl p, aterm.ATermAppl s, aterm.ATermAppl o)
public boolean addNegatedPropertyValue(aterm.ATermAppl p, aterm.ATermAppl s, aterm.ATermAppl o)
public void addProperty(aterm.ATermAppl p)
public boolean addObjectProperty(aterm.ATerm p)
p
- Name of the property
public boolean addDatatypeProperty(aterm.ATerm p)
p
-
@Deprecated public void addOntologyProperty(aterm.ATermAppl p)
public boolean addAnnotationProperty(aterm.ATerm p)
public boolean addAnnotation(aterm.ATermAppl s, aterm.ATermAppl p, aterm.ATermAppl o)
public java.util.Set<aterm.ATermAppl> getAnnotations(aterm.ATermAppl s, aterm.ATermAppl p)
public java.util.Set<aterm.ATermAppl> getIndividualsWithAnnotation(aterm.ATermAppl p, aterm.ATermAppl o)
public boolean isAnnotation(aterm.ATermAppl s, aterm.ATermAppl p, aterm.ATermAppl o)
public void addSubProperty(aterm.ATerm sub, aterm.ATermAppl sup)
public void addEquivalentProperty(aterm.ATermAppl p1, aterm.ATermAppl p2)
public void addDisjointProperties(aterm.ATermList properties)
public void addDisjointProperties(java.util.List<aterm.ATermAppl> properties)
public void addDisjointProperty(aterm.ATermAppl p1, aterm.ATermAppl p2)
public void addDisjointProperty(aterm.ATermAppl p1, aterm.ATermAppl p2, DependencySet ds)
public void addInverseProperty(aterm.ATermAppl p1, aterm.ATermAppl p2)
public void addTransitiveProperty(aterm.ATermAppl p)
public void addSymmetricProperty(aterm.ATermAppl p)
public void addAntisymmetricProperty(aterm.ATermAppl p)
addAsymmetricProperty(ATermAppl)
public void addAsymmetricProperty(aterm.ATermAppl p)
public void addReflexiveProperty(aterm.ATermAppl p)
public void addIrreflexiveProperty(aterm.ATermAppl p)
public void addFunctionalProperty(aterm.ATermAppl p)
public void addInverseFunctionalProperty(aterm.ATerm p)
public void addDomain(aterm.ATerm p, aterm.ATermAppl c)
public void addDomain(aterm.ATerm p, aterm.ATermAppl c, java.util.Set<aterm.ATermAppl> explain)
public void addRange(aterm.ATerm p, aterm.ATermAppl c)
public void addRange(aterm.ATerm p, aterm.ATermAppl c, java.util.Set<aterm.ATermAppl> explain)
public void addDatatype(aterm.ATermAppl p)
public boolean addDatatypeDefinition(aterm.ATermAppl name, aterm.ATermAppl datarange)
name
- name of the datatypedatarange
- a data range expression
public boolean removeDomain(aterm.ATerm p, aterm.ATermAppl c)
true
if removal was successful. See also
addDomain(ATerm, ATermAppl)
.
p
- Property in domain axiomc
- Class in domain axiom
true
if axiom is removed, false
if
removal failedpublic boolean removePropertyValue(aterm.ATermAppl p, aterm.ATermAppl i1, aterm.ATermAppl i2)
public boolean removeRange(aterm.ATerm p, aterm.ATermAppl c)
true
if removal was successful. See also
addRange(ATerm, ATermAppl)
.
p
- Property in range axiomc
- Class or datatype in range axiom
true
if axiom is removed, false
if
removal failedpublic boolean removeType(aterm.ATermAppl ind, aterm.ATermAppl c)
public boolean removeAxiom(aterm.ATermAppl axiom)
true
if removal was successful.
axiom
- TBox axiom to remove
true
if axiom is removed, false
if
removal failedpublic void prepare()
public void updateExpressivity(aterm.ATermAppl i, aterm.ATermAppl c)
public java.lang.String getInfo()
public boolean isConsistencyDone()
public boolean isClassified()
public boolean isRealized()
public boolean isChanged()
public boolean isChanged(KnowledgeBase.ChangeType change)
public boolean isTBoxChanged()
public boolean isRBoxChanged()
public boolean isABoxChanged()
public java.util.Set<aterm.ATermAppl> getUnsatisfiableClasses()
public java.util.Set<aterm.ATermAppl> getAllUnsatisfiableClasses()
public boolean isConsistent()
public Taxonomy<aterm.ATermAppl> getToldTaxonomy()
public java.util.Map<aterm.ATermAppl,java.util.Set<aterm.ATermAppl>> getToldDisjoints()
public void ensureConsistency()
public void classify()
public void realize()
public java.util.Set<aterm.ATermAppl> getClasses()
public java.util.Set<aterm.ATermAppl> getAllClasses()
public java.util.Set<aterm.ATermAppl> getProperties()
public java.util.Set<aterm.ATermAppl> getObjectProperties()
public java.util.Set<aterm.ATermAppl> getAnnotationProperties()
public java.util.Set<aterm.ATermAppl> getTransitiveProperties()
public java.util.Set<aterm.ATermAppl> getSymmetricProperties()
public java.util.Set<aterm.ATermAppl> getAntisymmetricProperties()
getAntisymmetricProperties()
public java.util.Set<aterm.ATermAppl> getAsymmetricProperties()
public java.util.Set<aterm.ATermAppl> getReflexiveProperties()
public java.util.Set<aterm.ATermAppl> getIrreflexiveProperties()
public java.util.Set<aterm.ATermAppl> getFunctionalProperties()
public java.util.Set<aterm.ATermAppl> getInverseFunctionalProperties()
public java.util.Set<aterm.ATermAppl> getDataProperties()
public java.util.Set<aterm.ATermAppl> getIndividuals()
public java.util.Set<aterm.ATermAppl> getAnnotationSubjects()
public Role getProperty(aterm.ATerm r)
public PropertyType getPropertyType(aterm.ATerm r)
public boolean isClass(aterm.ATerm c)
public boolean isProperty(aterm.ATerm p)
public boolean isDatatypeProperty(aterm.ATerm p)
public boolean isObjectProperty(aterm.ATerm p)
public boolean isABoxProperty(aterm.ATerm p)
public boolean isAnnotationProperty(aterm.ATerm p)
@Deprecated public boolean isOntologyProperty(aterm.ATerm p)
public boolean isIndividual(aterm.ATerm ind)
public boolean isTransitiveProperty(aterm.ATermAppl r)
public boolean isSymmetricProperty(aterm.ATermAppl p)
public boolean isFunctionalProperty(aterm.ATermAppl p)
public boolean isInverseFunctionalProperty(aterm.ATermAppl p)
public boolean isReflexiveProperty(aterm.ATermAppl p)
public boolean isIrreflexiveProperty(aterm.ATermAppl p)
public boolean isAntisymmetricProperty(aterm.ATermAppl p)
isAsymmetricProperty(ATermAppl)
public boolean isAsymmetricProperty(aterm.ATermAppl p)
public boolean isSubPropertyOf(aterm.ATermAppl sub, aterm.ATermAppl sup)
public boolean isEquivalentProperty(aterm.ATermAppl p1, aterm.ATermAppl p2)
public boolean isInverse(aterm.ATermAppl r1, aterm.ATermAppl r2)
public boolean hasDomain(aterm.ATermAppl p, aterm.ATermAppl c)
public boolean hasRange(aterm.ATermAppl p, aterm.ATermAppl c)
public boolean isDatatype(aterm.ATermAppl c)
public boolean isSatisfiable(aterm.ATermAppl c)
public boolean hasInstance(aterm.ATerm d)
c
-
public boolean isSubClassOf(aterm.ATermAppl c1, aterm.ATermAppl c2)
c1
- c2
-
public boolean isEquivalentClass(aterm.ATermAppl c1, aterm.ATermAppl c2)
c1
- c2
-
public boolean isDisjoint(aterm.ATermAppl c1, aterm.ATermAppl c2)
public boolean isDisjointClass(aterm.ATermAppl c1, aterm.ATermAppl c2)
public boolean isDisjointProperty(aterm.ATermAppl r1, aterm.ATermAppl r2)
public boolean isComplement(aterm.ATermAppl c1, aterm.ATermAppl c2)
public Bool isKnownType(aterm.ATermAppl x, aterm.ATermAppl c)
Bool.TRUE
, Bool.FALSE
, or
Bool.UNKNOWN
. If Bool.UNKNOWN
is returned
isType
function needs to be called to get the answer.
x
- c
-
public boolean isType(aterm.ATermAppl x, aterm.ATermAppl c)
public boolean isSameAs(aterm.ATermAppl t1, aterm.ATermAppl t2)
public boolean isDifferentFrom(aterm.ATermAppl t1, aterm.ATermAppl t2)
public java.util.Set<aterm.ATermAppl> getDifferents(aterm.ATermAppl name)
public boolean hasPropertyValue(aterm.ATermAppl s, aterm.ATermAppl p, aterm.ATermAppl o)
public Bool hasKnownPropertyValue(aterm.ATermAppl s, aterm.ATermAppl p, aterm.ATermAppl o)
Boolean.TRUE
,
Boolean.FALSE
, or null
(unknown). If the
null value is returned hasPropertyValue
function needs to
be called to get the answer.
s
- Subjectp
- Predicateo
- Object (null
can be used as wildcard)
public ABox getABox()
public RBox getRBox()
public TBox getTBox()
public DatatypeReasoner getDatatypeReasoner()
public java.util.Set<java.util.Set<aterm.ATermAppl>> getSuperClasses(aterm.ATermAppl c, boolean direct)
*** This function will first classify the whole ontology ***
c
- class whose superclasses are returned
public java.util.Set<java.util.Set<aterm.ATermAppl>> getSubClasses(aterm.ATermAppl c)
*** This function will first classify the whole ontology ***
c
- class whose subclasses are returned
public java.util.Set<java.util.Set<aterm.ATermAppl>> getDisjoints(aterm.ATermAppl c)
public java.util.Set<java.util.Set<aterm.ATermAppl>> getDisjointClasses(aterm.ATermAppl c)
public java.util.Set<java.util.Set<aterm.ATermAppl>> getDisjointClasses(aterm.ATermAppl c, boolean direct)
public java.util.Set<java.util.Set<aterm.ATermAppl>> getDisjointProperties(aterm.ATermAppl p)
public java.util.Set<java.util.Set<aterm.ATermAppl>> getDisjointProperties(aterm.ATermAppl p, boolean direct)
public java.util.Set<aterm.ATermAppl> getComplements(aterm.ATermAppl c)
public java.util.Set<java.util.Set<aterm.ATermAppl>> getTypes(aterm.ATermAppl ind, boolean direct)
ind
- An individual namedirect
- If true return only the direct types, otherwise return all
types
public java.util.Set<java.util.Set<aterm.ATermAppl>> getTypes(aterm.ATermAppl ind)
*** This function will first realize the whole ontology ***
ind
- An individual name
public aterm.ATermAppl getType(aterm.ATermAppl ind)
public aterm.ATermAppl getType(aterm.ATermAppl ind, boolean direct)
public java.util.Set<aterm.ATermAppl> getInstances(aterm.ATermAppl c)
c
- class whose instances are returned
public java.util.Set<aterm.ATermAppl> getInstances(aterm.ATermAppl c, boolean direct)
*** This function will first realize the whole ontology ***
c
- class whose instances are returneddirect
- if true return only the direct instances, otherwise return all
the instances
public java.util.Set<aterm.ATermAppl> getEquivalentClasses(aterm.ATermAppl c)
*** This function will first classify the whole ontology ***
c
- class whose equivalent classes are found
public java.util.Set<aterm.ATermAppl> getAllEquivalentClasses(aterm.ATermAppl c)
*** This function will first classify the whole ontology ***
c
- class whose equivalent classes are found
public java.util.Set<java.util.Set<aterm.ATermAppl>> getSuperClasses(aterm.ATermAppl c)
*** This function will first classify the whole ontology ***
c
- class whose superclasses are returned
public java.util.Set<java.util.Set<aterm.ATermAppl>> getSubClasses(aterm.ATermAppl c, boolean direct)
*** This function will first classify the whole ontology ***
c
- class whose subclasses are returneddirect
- If true return only the direct subclasses, otherwise return
all the subclasses
public java.util.Set<java.util.Set<aterm.ATermAppl>> getAllSuperProperties(aterm.ATermAppl prop)
public java.util.Set<java.util.Set<aterm.ATermAppl>> getSuperProperties(aterm.ATermAppl prop)
prop
-
public java.util.Set<java.util.Set<aterm.ATermAppl>> getSuperProperties(aterm.ATermAppl prop, boolean direct)
prop
- direct
- If true return only the direct super properties, otherwise
return all the super properties
public java.util.Set<java.util.Set<aterm.ATermAppl>> getAllSubProperties(aterm.ATermAppl prop)
public java.util.Set<java.util.Set<aterm.ATermAppl>> getSubProperties(aterm.ATermAppl prop)
prop
-
public java.util.Set<java.util.Set<aterm.ATermAppl>> getSubProperties(aterm.ATermAppl prop, boolean direct)
prop
- direct
- If true return only the direct subproperties, otherwise return
all the subproperties
public java.util.Set<aterm.ATermAppl> getEquivalentProperties(aterm.ATermAppl prop)
prop
-
public java.util.Set<aterm.ATermAppl> getAllEquivalentProperties(aterm.ATermAppl prop)
public java.util.Set<aterm.ATermAppl> getInverses(aterm.ATerm name)
prop
-
public aterm.ATermAppl getInverse(aterm.ATerm name)
name
- Property whose inverse being sought
public java.util.Set<aterm.ATermAppl> getDomains(aterm.ATermAppl name)
hasDomain(ATermAppl, ATermAppl)
to get complete answers.
prop
-
public java.util.Set<aterm.ATermAppl> getRanges(aterm.ATerm name)
hasRange(ATermAppl, ATermAppl)
to get complete answers.
prop
-
public java.util.Set<aterm.ATermAppl> getAllSames(aterm.ATermAppl name)
name
-
public java.util.Set<aterm.ATermAppl> getSames(aterm.ATermAppl name)
name
-
public java.util.List<aterm.ATermAppl> getDataPropertyValues(aterm.ATermAppl r, aterm.ATermAppl x, aterm.ATermAppl datatype)
r
- x
- lang
-
public java.util.List<aterm.ATermAppl> getDataPropertyValues(aterm.ATermAppl r, aterm.ATermAppl x, java.lang.String lang)
r
- x
- lang
-
public java.util.List<aterm.ATermAppl> getDataPropertyValues(aterm.ATermAppl r, aterm.ATermAppl x)
r
- x
-
public java.util.List<aterm.ATermAppl> getObjectPropertyValues(aterm.ATermAppl r, aterm.ATermAppl x)
r
- x
-
public java.util.List<aterm.ATermAppl> getPropertyValues(aterm.ATermAppl r, aterm.ATermAppl x)
r
- x
-
public java.util.List<aterm.ATermAppl> getIndividualsWithProperty(aterm.ATermAppl r, aterm.ATermAppl x)
r
- x
- If property is an object property an ATermAppl object that is
the URI of the individual, if the property is a data property
an ATerm object that contains the literal value (See {#link
#getIndividualsWithDataProperty(ATermAppl, ATermAppl)} for
details)
public java.util.List<aterm.ATermAppl> getIndividualsWithDataProperty(aterm.ATermAppl r, aterm.ATermAppl litValue)
r
- An ATerm object that contains the literal value in the form
literal(lexicalValue, langIdentifier, datatypeURI). Should be
created with ATermUtils.makeXXXLiteral() functions.x
-
public java.util.List<aterm.ATermAppl> getIndividualsWithObjectProperty(aterm.ATermAppl r, aterm.ATermAppl o)
r
- o
- An ATerm object that is the URI of an individual
public java.util.List<aterm.ATermAppl> getProperties(aterm.ATermAppl s, aterm.ATermAppl o)
public java.util.Map<aterm.ATermAppl,java.util.List<aterm.ATermAppl>> getPropertyValues(aterm.ATermAppl pred)
public java.util.Set<aterm.ATermAppl> retrieve(aterm.ATermAppl d, java.util.Collection<aterm.ATermAppl> individuals)
d
-
public java.util.List<aterm.ATermAppl> retrieveIndividualsWithProperty(aterm.ATermAppl r)
public void tracingBasedInstanceRetrieval(aterm.ATermAppl c, java.util.List<aterm.ATermAppl> candidates, java.util.Collection<aterm.ATermAppl> results)
public void linearInstanceRetrieval(aterm.ATermAppl c, java.util.List<aterm.ATermAppl> candidates, java.util.Collection<aterm.ATermAppl> results)
public void binaryInstanceRetrieval(aterm.ATermAppl c, java.util.List<aterm.ATermAppl> candidates, java.util.Collection<aterm.ATermAppl> results)
public void printClassTree()
public void printClassTree(java.io.PrintWriter out)
public boolean doExplanation()
public void setDoExplanation(boolean doExplanation)
doExplanation
- The doExplanation to set.public java.lang.String getExplanation()
public void setDoDependencyAxioms(boolean doDepAxioms)
public boolean getDoDependencyAxioms()
public java.util.Set<aterm.ATermAppl> getExplanationSet()
public void setRBox(RBox rbox)
rbox
- The rbox to set.public void setTBox(TBox tbox)
tbox
- The tbox to set.public void setTimeout(long timeout)
timeout
- public Role getRole(aterm.ATerm term)
term
-
public Taxonomy<aterm.ATermAppl> getTaxonomy()
public TaxonomyBuilder getTaxonomyBuilder()
public void setTaxonomyBuilderProgressMonitor(ProgressMonitor progressMonitor)
public Taxonomy<aterm.ATermAppl> getRoleTaxonomy(boolean objectTaxonomy)
public Taxonomy<aterm.ATermAppl> getRoleTaxonomy(aterm.ATermAppl r)
public SizeEstimate getSizeEstimate()
public boolean addRule(Rule rule)
public java.util.Set<Rule> getRules()
public java.util.Map<Rule,Rule> getNormalizedRules()
public void ensureIncConsistency(boolean aboxDeletion)
public DependencyIndex getDependencyIndex()
public java.util.Set<aterm.ATermAppl> getSyntacticAssertions()
public java.util.Set<aterm.ATermAppl> getABoxAssertions(KnowledgeBase.AssertionType assertionType)
public java.util.Set<aterm.ATermAppl> getAboxMembershipAssertions()
getABoxAssertions(org.mindswap.pellet.KnowledgeBase.AssertionType)
instead
public java.util.Set<aterm.ATermAppl> getAboxObjectRoleAssertions()
getABoxAssertions(org.mindswap.pellet.KnowledgeBase.AssertionType)
instead
public java.util.Set<aterm.ATermAppl> getAboxDataRoleAssertions()
getABoxAssertions(org.mindswap.pellet.KnowledgeBase.AssertionType)
instead
public java.util.Set<aterm.ATermAppl> getDeletedAssertions()
public boolean isExplainOnlyInconsistency()
setExplainOnlyInconsistency(boolean)
public void setExplainOnlyInconsistency(boolean explainOnlyInconsistency)
explainOnlyInconsistency
- new value for explainOnlyInconsistency option
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |