Package openllet.core.knowledge
Interface InstancesBase
-
- All Superinterfaces:
Base,Boxes,openllet.shared.tools.Logging,MessageBase
- All Known Subinterfaces:
KnowledgeBase
- All Known Implementing Classes:
KnowledgeBaseImpl,KnowledgeBaseImplFullSync
public interface InstancesBase extends MessageBase, openllet.shared.tools.Logging, Base
Groupment of all methods related to instances.- Since:
- 2.6.4
-
-
Field Summary
-
Fields inherited from interface openllet.core.knowledge.MessageBase
_isNotAnClass, _isNotAnIndividual, _isNotAnKnowClass, _isNotAnKnowDataProperty, _isNotAnKnowIndividual, _isNotAnKnowObjectProperty, _isNotAnKnowProperty, _isNotAnProperty, _isNotAnPropertyNorAClass, _isNotAValidClassExpression, _isNotAValidClassExpressionOrDataRange
-
-
Method Summary
All Methods Static Methods Instance Methods Default Methods Modifier and Type Method Description default voidbinaryInstanceRetrieval(openllet.aterm.ATermAppl c, java.util.List<openllet.aterm.ATermAppl> candidates, java.util.Collection<openllet.aterm.ATermAppl> results)default java.util.Set<openllet.aterm.ATermAppl>getAllSames(openllet.aterm.ATermAppl name)default java.util.Set<openllet.aterm.ATermAppl>getInstances(openllet.aterm.ATermAppl c)Returns all the instances of concept c.default java.util.Set<openllet.aterm.ATermAppl>getInstances(openllet.aterm.ATermAppl c, boolean direct)Returns the instances of class c.default java.util.Set<java.util.Set<openllet.aterm.ATermAppl>>getPrimitiveTypes(openllet.aterm.ATermAppl ind, boolean direct)default java.util.Set<java.util.Set<openllet.aterm.ATermAppl>>getTypes(openllet.aterm.ATermAppl ind, boolean direct)Returns the (named) classes individual belongs to.default voidlinearInstanceRetrieval(openllet.aterm.ATermAppl c, java.util.List<openllet.aterm.ATermAppl> candidates, java.util.Collection<openllet.aterm.ATermAppl> results)static java.util.List<openllet.aterm.ATermAppl>[]partition(java.util.List<openllet.aterm.ATermAppl> candidates)default voidpartitionInstanceRetrieval(openllet.aterm.ATermAppl c, java.util.List<openllet.aterm.ATermAppl>[] partitions, java.util.Collection<openllet.aterm.ATermAppl> results)default java.util.Set<openllet.aterm.ATermAppl>retrieve(openllet.aterm.ATermAppl d, java.util.Collection<openllet.aterm.ATermAppl> individuals)default java.util.List<openllet.aterm.ATermAppl>retrieveIndividualsWithProperty(openllet.aterm.ATermAppl r)default voidtracingBasedInstanceRetrieval(openllet.aterm.ATermAppl c, java.util.List<openllet.aterm.ATermAppl> candidates, java.util.Collection<openllet.aterm.ATermAppl> results)-
Methods inherited from interface openllet.core.knowledge.Base
allClasses, classify, doExplanation, ensureConsistency, getAllClasses, getAnnotations, getAnnotationSubjects, getBuilder, getBuilderProgressMonitor, getChanges, getClasses, getDatatypeVisitor, getExpChecker, getExplanation, getExplanationSet, getFullyDefinedVisitor, getIndividuals, getInstances, getKnowledgeBase, getOptTaxonomyBuilder, getProperties, getProperty, getPropertyType, getRole, getSuperClasses, getTaxonomyBuilder, isABoxProperty, isAnnotationProperty, isClass, isClassified, isDatatype, isDatatypeProperty, isIndividual, isObjectProperty, isProperty, isRealized, isSatisfiable, isSubClassOf, prepare, realize, setBuilderProgressMonitor, setDoExplanation, setOptTaxonomyBuilder
-
-
-
-
Method Detail
-
linearInstanceRetrieval
default void linearInstanceRetrieval(openllet.aterm.ATermAppl c, java.util.List<openllet.aterm.ATermAppl> candidates, java.util.Collection<openllet.aterm.ATermAppl> results)
-
binaryInstanceRetrieval
default void binaryInstanceRetrieval(openllet.aterm.ATermAppl c, java.util.List<openllet.aterm.ATermAppl> candidates, java.util.Collection<openllet.aterm.ATermAppl> results)- Specified by:
binaryInstanceRetrievalin interfaceBase
-
partitionInstanceRetrieval
default void partitionInstanceRetrieval(openllet.aterm.ATermAppl c, java.util.List<openllet.aterm.ATermAppl>[] partitions, java.util.Collection<openllet.aterm.ATermAppl> results)
-
partition
static java.util.List<openllet.aterm.ATermAppl>[] partition(java.util.List<openllet.aterm.ATermAppl> candidates)
-
getInstances
default java.util.Set<openllet.aterm.ATermAppl> getInstances(openllet.aterm.ATermAppl c)
Returns all the instances of concept c. If TOP concept is used every individual in the knowledge base will be returned- Parameters:
c- class whose instances are returned- Returns:
- A set of ATerm objects
-
getInstances
default java.util.Set<openllet.aterm.ATermAppl> getInstances(openllet.aterm.ATermAppl c, boolean direct)Returns the instances of class c. Depending on the second parameter the resulting list will include all or only the direct getInstances(). An _individual x is a direct instance of c iff x is of type c and there is no subclass d of c such that x is of type d.*** This function will first realize the whole ontology ***
- Parameters:
c- class whose getInstances() are returneddirect- if true return only the direct getInstances(), otherwise return all the getInstances()- Returns:
- A set of ATerm objects
-
retrieve
default java.util.Set<openllet.aterm.ATermAppl> retrieve(openllet.aterm.ATermAppl d, java.util.Collection<openllet.aterm.ATermAppl> individuals)- Parameters:
d-individuals-- Returns:
- all the individuals that belong to the given class which is not necessarily a named class.
-
tracingBasedInstanceRetrieval
default void tracingBasedInstanceRetrieval(openllet.aterm.ATermAppl c, java.util.List<openllet.aterm.ATermAppl> candidates, java.util.Collection<openllet.aterm.ATermAppl> results)
-
retrieveIndividualsWithProperty
default java.util.List<openllet.aterm.ATermAppl> retrieveIndividualsWithProperty(openllet.aterm.ATermAppl r)
- Parameters:
r-- Returns:
- individuals which possibly have a property value for the given property.
-
getTypes
default java.util.Set<java.util.Set<openllet.aterm.ATermAppl>> getTypes(openllet.aterm.ATermAppl ind, boolean direct)Returns the (named) classes individual belongs to. Depending on the second parameter the result will include either all types or only the direct types.- Parameters:
ind- An _individual namedirect- If true return only the direct types, otherwise return all types- Returns:
- A set of sets, where each set in the collection represents an equivalence class. The elements of the inner class are ATermAppl objects.
-
getPrimitiveTypes
default java.util.Set<java.util.Set<openllet.aterm.ATermAppl>> getPrimitiveTypes(openllet.aterm.ATermAppl ind, boolean direct)
-
getAllSames
default java.util.Set<openllet.aterm.ATermAppl> getAllSames(openllet.aterm.ATermAppl name)
- Parameters:
name-- Returns:
- all the indviduals asserted to be equal to the given individual inluding the individual itself.
-
-