public class OWLGraphWrapperEdgesExtended extends OWLGraphWrapperEdges
OWLGraphWrapper and parent classes.OWLGraphWrapperEdges.ConfiginferredEdgeBySource, profilersourceOntology, supportOntologySet| Modifier | Constructor and Description |
|---|---|
|
OWLGraphWrapperEdgesExtended(org.semanticweb.owlapi.model.OWLOntology ontology)
Default constructor.
|
protected |
OWLGraphWrapperEdgesExtended(String iri) |
| Modifier and Type | Method and Description |
|---|---|
void |
clearCachedEdges()
Clear the current edge cache.
|
OWLGraphEdge |
combineEdgePairWithGCI(org.semanticweb.owlapi.model.OWLObject s,
OWLGraphEdge ne,
OWLGraphEdge extEdge,
int nextDist)
Same as
OWLGraphWrapperEdges.combineEdgePair(OWLObject, OWLGraphEdge,
OWLGraphEdge, int) except that the GCI filler an GCI relation of the edges
are taken into account. |
OWLGraphEdge |
combineEdgePairWithSuperPropsAndGCI(OWLGraphEdge firstEdge,
OWLGraphEdge secondEdge)
Combines
firstEdge and secondEdge to create a new edge
from the source of firstEdge to the target of secondEdge,
with properties combined in a regular way, and over super properties. |
org.semanticweb.owlapi.model.OWLObject |
edgeToSourceExpression(OWLGraphEdge e)
Translates the source of an
OWLGraphEdge into an OWLClassExpression
(but, as the method OWLGraphEdge.getSource() returns an OWLObject,
this method also returns an OWLObject). |
Set<org.semanticweb.owlapi.model.OWLClass> |
getAllOWLClasses()
Get all
OWLClasses from all ontologies,
that are neither top entity (owl:thing), nor bottom entity (owl:nothing),
nor deprecated (OWLGraphWrapperExtended.isObsolete(OWLObject)
returns false). |
Set<org.semanticweb.owlapi.model.OWLClass> |
getAllOWLClassesFromSource()
Get only the
OWLClasses from the OWLOntology returned
by OWLGraphWrapperBasic.getSourceOntology(), that are neither top entity (owl:thing),
nor bottom entity (owl:nothing), nor deprecated (OWLGraphWrapperExtended.isObsolete(OWLObject) returns false). |
Set<org.semanticweb.owlapi.model.OWLClass> |
getAncestorsThroughIsA(org.semanticweb.owlapi.model.OWLObject x)
Retrieve
OWLClass ancestors of x only using "is_a" relations
(SubClassOf). |
Set<org.semanticweb.owlapi.model.OWLClass> |
getDescendantsThroughIsA(org.semanticweb.owlapi.model.OWLObject x)
Retrieve
OWLClass descendants of x only using "is_a" relations
(SubClassOf). |
Set<OWLGraphEdge> |
getGCIIncomingEdges(org.semanticweb.owlapi.model.OWLClass t)
Retrieve OBO GCI relations incoming to
t as a Set of OWLGraphEdges. |
Set<OWLGraphEdge> |
getGCIOutgoingEdges(org.semanticweb.owlapi.model.OWLClass s)
Retrieve OBO GCI relations outgoing from
s as a Set of OWLGraphEdges. |
Set<OWLGraphEdge> |
getGCIOutgoingEdges(org.semanticweb.owlapi.model.OWLClass s,
Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProps)
Same as
getGCIOutgoingEdges(OWLClass), but with a Set of
OWLPropertyExpression allowing to filter the relations retrieved. |
Set<OWLGraphEdge> |
getIncomingEdgesWithGCI(org.semanticweb.owlapi.model.OWLObject t)
Similar to
OWLGraphWrapperEdges.getIncomingEdges(OWLObject), but the returned
Set also includes OBO GCI incoming edges (see
getGCIIncomingEdges(OWLClass)). |
Set<org.semanticweb.owlapi.model.OWLNamedObject> |
getNamedAncestorsWithGCI(org.semanticweb.owlapi.model.OWLObject sourceObject)
Similar to
OWLGraphWrapperEdges.getNamedAncestors(OWLObject) but also
considering GCI relations. |
Set<org.semanticweb.owlapi.model.OWLNamedObject> |
getNamedAncestorsWithGCI(org.semanticweb.owlapi.model.OWLObject sourceObject,
Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProps)
Similar to
getNamedAncestorsWithGCI(OWLObject, Set) but allowing to filter
the relations considered. |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOntologyLeaves()
Return the
OWLClasses leaves of any ontology
(OWLClasses with no incoming edges as returned by
{OWLGraphWrapperEdges#getIncomingEdgesWithGCI(OWLObject)}), and not deprecated
(OWLGraphWrapperExtended.isObsolete(OWLObject) returns false;
edges incoming from an obsolete class are not considered) |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOntologyRoots()
Return the
OWLClasses root of any ontology
(OWLClasses with no outgoing edges as returned by
{OWLGraphWrapperEdges#getOutgoingEdgesWithGCI(OWLObject)}), and not deprecated
(OWLGraphWrapperExtended.isObsolete(OWLObject) returns false)). |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOntologyRoots(Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProperties)
Return the
OWLClasses root of any ontology over the specified
OWLPropertyExpressions (OWLClasses with no outgoing edges
of the specified type, as returned by
{OWLGraphWrapperEdges#getOutgoingEdgesWithGCI(OWLObject, Set)}), and not deprecated
(OWLGraphWrapperExtended.isObsolete(OWLObject) returns false);
edges going to obsolete classes are not taken into account). |
Set<OWLGraphEdge> |
getOutgoingEdgesClosureWithGCI(org.semanticweb.owlapi.model.OWLObject s)
Similar to
OWLGraphWrapperEdges.getOutgoingEdgesClosure(OWLObject), but also considering
OBO GCI relations. |
Set<OWLGraphEdge> |
getOutgoingEdgesNamedClosureOverSupProps(org.semanticweb.owlapi.model.OWLObject s)
Same method as
OWLGraphWrapperEdges.getOutgoingEdgesClosure(OWLObject),
except that only the OWLGraphEdges going to a named target are returned,
and that the list of connecting edge properties are not only combined using the
composition rules as usual, but also over super properties (see for instance
#combineEdgePairWithSuperPropsAndGCI(OWLGraphEdge, OWLGraphEdge). |
Set<OWLGraphEdge> |
getOutgoingEdgesNamedClosureOverSupPropsWithGCI(org.semanticweb.owlapi.model.OWLObject s)
Similar to
getOutgoingEdgesNamedClosureOverSupProps(OWLObject) but with
the OBO GCI relations also taken into account. |
Set<OWLGraphEdge> |
getOutgoingEdgesWithGCI(org.semanticweb.owlapi.model.OWLObject s)
Similar to
OWLGraphWrapperEdges.getOutgoingEdges(OWLObject), but the returned
Set also includes OBO GCI outgoing edges (see
getGCIOutgoingEdges(OWLClass)). |
Set<OWLGraphEdge> |
getOutgoingEdgesWithGCI(org.semanticweb.owlapi.model.OWLObject s,
Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProperties)
Similar to
OWLGraphWrapperEdges.getOutgoingEdges(OWLObject, Set), but the returned
Set also includes OBO GCI outgoing edges (see
getGCIOutgoingEdges(OWLClass)). |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOWLClassAncestors(org.semanticweb.owlapi.model.OWLClass sourceClass)
Return the
OWLClasses ancestor of sourceClass. |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOWLClassAncestorsWithGCI(org.semanticweb.owlapi.model.OWLObject sourceObject)
Similar to
getNamedAncestorsWithGCI(OWLObject) but returning only
OWLClasses. |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOWLClassDescendants(org.semanticweb.owlapi.model.OWLClass parentClass)
Return the
OWLClasses descendant of parentClass. |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOWLClassDescendantsWithGCI(org.semanticweb.owlapi.model.OWLClass parentClass)
Similar to
getOWLClassDescendants(OWLClass) but also considering GCI relations. |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOWLClassDescendantsWithGCI(org.semanticweb.owlapi.model.OWLClass parentClass,
Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProps)
Similar to
#getOWLClassDescendantsWithGCI(OWLObject) but allowing to filter
the relations considered. |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOWLClassDirectAncestors(org.semanticweb.owlapi.model.OWLClass subClass)
Return the
OWLClasses that are direct parent of subClass. |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOWLClassDirectDescendants(org.semanticweb.owlapi.model.OWLClass parentClass)
Return the
OWLClasses directly descendant of parentClass. |
Set<org.semanticweb.owlapi.model.OWLClass> |
getOWLClassDirectDescendantsWithGCI(org.semanticweb.owlapi.model.OWLClass parentClass)
Similar to
getOWLClassDirectDescendants(OWLClass) but also considering GCI relations. |
LinkedHashSet<OWLGraphEdge> |
getOWLGraphEdgeSubRelsReflexive(OWLGraphEdge edge)
Get the sub-relations of
edge. |
Set<org.semanticweb.owlapi.model.OWLAnnotationProperty> |
getSubAnnotationPropertiesOf(org.semanticweb.owlapi.model.OWLAnnotationProperty prop)
Returns the direct child properties of
prop in all ontologies. |
LinkedHashSet<org.semanticweb.owlapi.model.OWLAnnotationProperty> |
getSubAnnotationPropertyClosureOf(org.semanticweb.owlapi.model.OWLAnnotationProperty prop)
Returns all child properties of
prop in all ontologies,
ordered from the more general (closer from prop) to the more precise. |
LinkedHashSet<org.semanticweb.owlapi.model.OWLAnnotationProperty> |
getSubAnnotationPropertyReflexiveClosureOf(org.semanticweb.owlapi.model.OWLAnnotationProperty prop)
Returns all sub-properties of
prop in all ontologies,
and prop itself as the first element (reflexive). |
Set<org.semanticweb.owlapi.model.OWLObjectPropertyExpression> |
getSubPropertiesOf(org.semanticweb.owlapi.model.OWLObjectPropertyExpression prop)
Returns the direct child properties of
prop in all ontologies. |
LinkedHashSet<org.semanticweb.owlapi.model.OWLObjectPropertyExpression> |
getSubPropertyClosureOf(org.semanticweb.owlapi.model.OWLObjectPropertyExpression prop)
Returns all child properties of
prop in all ontologies,
ordered from the more general (closer from prop) to the more precise
(e.g., for the "overlaps" property, return "part_of" then "in_deep_part_of"). |
LinkedHashSet<org.semanticweb.owlapi.model.OWLObjectPropertyExpression> |
getSubPropertyReflexiveClosureOf(org.semanticweb.owlapi.model.OWLObjectPropertyExpression prop)
Returns all sub-properties of
prop in all ontologies,
and prop itself as the first element (reflexive). |
LinkedHashSet<org.semanticweb.owlapi.model.OWLObjectPropertyExpression> |
getSuperPropertyReflexiveClosureOf(org.semanticweb.owlapi.model.OWLObjectPropertyExpression prop)
Returns all parent properties of
prop in all ontologies,
and prop itself as the first element (reflexive). |
boolean |
hasFirstEdgeMoreGeneralGCIParams(OWLGraphEdge firstEdge,
OWLGraphEdge otherEdge)
Determines whether the GCI parameters of the GCI relation
firstEdge
are more general than the GCI parameters of the GCI relation otherEdge. |
boolean |
isOWLObjectInSubsets(org.semanticweb.owlapi.model.OWLObject testObject,
Collection<String> subsets)
Determine if
testObject belongs to at least one of the subsets
in subsets. |
boolean |
isRealClass(org.semanticweb.owlapi.model.OWLObject object)
Determines that
object is an OWLClass that is neither owl:thing,
nor owl:nothing, and that it is not deprecated
(OWLGraphWrapperExtended.isObsolete(OWLObject) returns false). |
cacheEdges, combinedQuantifiedPropertyPair, combineEdgePair, combineEdgePair, edgeToTargetExpression, expandRelationChain, filterEdges, getAncestors, getAncestors, getAncestors, getAncestorsReflexive, getAncestorsReflexive, getCompleteEdgesBetween, getCompleteOutgoingEdgesClosure, getConfig, getDescendants, getDescendantsReflexive, getEdgeLabel, getEdgesBetween, getIncomingEdges, getIncomingEdgesClosure, getIncomingEdgesClosure, getIndividualDescendants, getInstanceChainsFromClosure, getInstancesFromClosure, getNamedAncestors, getNamedAncestorsReflexive, getOutgoingEdges, getOutgoingEdges, getOutgoingEdges, getOutgoingEdgesClosure, getOutgoingEdgesClosure, getOutgoingEdgesClosure, getOutgoingEdgesClosureReflexive, getOutgoingEdgesClosureReflexive, getOWLGraphEdgeSubsumers, getOWLGraphEdgeSubsumers, getPrimitiveIncomingEdges, getPrimitiveOutgoingEdges, getPrimitiveOutgoingEdges, getProfiler, getReasoner, getRelationOrChain, getSubsumersFromClosure, getSuperPropertiesOf, getSuperPropertyClosureOf, isExcluded, isExcludeEdge, primitiveEdgeToFullEdges, queryDescendants, queryDescendants, queryDescendants, setConfig, setProfiler, setReasonergetAllOWLObjectsByAltId, getAllUsedSubsets, getAltIds, getAnnotationProperty, getAnnotationPropertyValue, getAnnotationPropertyValue, getAnnotationPropertyValues, getAnnotationPropertyValues, getAnnotationValue, getAnnotationValues, getBuiltin, getComment, getComment, getConsider, getCreatedBy, getDef, getDef, getDefXref, getDefXref, getDomain, getIdentifier, getIdentifier, getIdentifier, getIdentifier, getIRIByIdentifier, getIRIByIdentifier, getIRIByLabel, getIRIByLabel, getIsAnonymous, getIsAntiSymmetric, getIsCyclic, getIsFunctional, getIsInverseFunctional, getIsMetaTag, getIsObsolete, getIsObsoleteBinaryString, getIsReflexive, getIsSymmetric, getIsTransitive, getLabel, getLabel, getLabelOrDisplayId, getNamespace, getNamespace, getObjectByAltId, getOntologyId, getOWLAnnotationProperty, getOWLClass, getOWLClass, getOWLClass, getOWLClassByIdentifier, getOWLClassByIdentifier, getOWLClassesInSubset, getOWLIndividual, getOWLIndividual, getOWLIndividualByIdentifier, getOWLObject, getOWLObject, getOWLObjectByAltId, getOWLObjectByIdentifier, getOWLObjectByLabel, getOWLObjectProperty, getOWLObjectProperty, getOWLObjectPropertyByIdentifier, getOWLObjectsByAltId, getOWLObjectsInSubset, getRange, getReplacedBy, getSubsets, getSubsets, getVersions, getXref, getXref, isObsoleteaddImport, addImportsFromSupportOntologies, addSupportOntologiesFromImportsClosure, addSupportOntologiesFromImportsClosure, addSupportOntology, getAllOntologies, getAllOWLObjects, getAllOWLSubClassOfAxiomsForSubClass, getAllOWLSubClassOfAxiomsForSuperClass, getDataFactory, getManager, getSourceOntology, getSupportOntologySet, mergeImportClosure, mergeImportClosure, mergeOntology, mergeOntology, mergeSupportOntology, mergeSupportOntology, remakeOntologiesFromImportsClosure, remakeOntologiesFromImportsClosure, removeSupportOntology, setSourceOntology, setSupportOntologySetpublic OWLGraphWrapperEdgesExtended(org.semanticweb.owlapi.model.OWLOntology ontology)
ontology - The OWLOntology that this object wraps.protected OWLGraphWrapperEdgesExtended(String iri) throws org.semanticweb.owlapi.model.UnknownOWLOntologyException, org.semanticweb.owlapi.model.OWLOntologyCreationException
org.semanticweb.owlapi.model.UnknownOWLOntologyExceptionorg.semanticweb.owlapi.model.OWLOntologyCreationExceptionpublic boolean isOWLObjectInSubsets(org.semanticweb.owlapi.model.OWLObject testObject,
Collection<String> subsets)
testObject belongs to at least one of the subsets
in subsets.testObject - An OWLObject for which we want to know if it belongs
to a subset in subsets.subsets - A Collection of Strings that are
the names of the subsets for which we want to check belonging
of testObject.true if testObject belongs to a subset
in subsets, false otherwise.public Set<org.semanticweb.owlapi.model.OWLAnnotationProperty> getSubAnnotationPropertiesOf(org.semanticweb.owlapi.model.OWLAnnotationProperty prop)
prop in all ontologies.prop - The OWLAnnotationProperty for which
we want the direct sub-properties.Set of OWLAnnotationPropertys
that are the direct sub-properties of prop.getSubPropertyClosureOf(OWLObjectPropertyExpression),
getSubPropertyReflexiveClosureOf(OWLObjectPropertyExpression)public LinkedHashSet<org.semanticweb.owlapi.model.OWLAnnotationProperty> getSubAnnotationPropertyClosureOf(org.semanticweb.owlapi.model.OWLAnnotationProperty prop)
prop in all ontologies,
ordered from the more general (closer from prop) to the more precise.prop - the OWLAnnotationProperty for which we want
the ordered sub-properties.LinkedHashSet of OWLAnnotationPropertys
ordered from the more general to the more precise.getSubAnnotationPropertiesOf(OWLAnnotationProperty),
getSubAnnotationPropertyReflexiveClosureOf(OWLAnnotationProperty)public LinkedHashSet<org.semanticweb.owlapi.model.OWLAnnotationProperty> getSubAnnotationPropertyReflexiveClosureOf(org.semanticweb.owlapi.model.OWLAnnotationProperty prop)
prop in all ontologies,
and prop itself as the first element (reflexive).
The returned sub-properties are ordered from the more general (the closest
from prop) to the more precise.prop - the OWLAnnotationProperty for which we want
the ordered sub-properties.LinkedHashSet of OWLAnnotationPropertys
ordered from the more general to the more precise, with prop
as the first element.getSubAnnotationPropertiesOf(OWLAnnotationProperty),
getSubAnnotationPropertyClosureOf(OWLAnnotationProperty)public Set<org.semanticweb.owlapi.model.OWLObjectPropertyExpression> getSubPropertiesOf(org.semanticweb.owlapi.model.OWLObjectPropertyExpression prop)
prop in all ontologies.prop - The OWLObjectPropertyExpression for which
we want the direct sub-properties.Set of OWLObjectPropertyExpressions
that are the direct sub-properties of prop.getSubPropertyClosureOf(OWLObjectPropertyExpression),
getSubPropertyReflexiveClosureOf(OWLObjectPropertyExpression)public LinkedHashSet<org.semanticweb.owlapi.model.OWLObjectPropertyExpression> getSubPropertyClosureOf(org.semanticweb.owlapi.model.OWLObjectPropertyExpression prop)
prop in all ontologies,
ordered from the more general (closer from prop) to the more precise
(e.g., for the "overlaps" property, return "part_of" then "in_deep_part_of").prop - the OWLObjectPropertyExpression for which we want
the ordered sub-properties.LinkedHashSet of OWLObjectPropertyExpressions
ordered from the more general to the more precise.getSubPropertiesOf(OWLObjectPropertyExpression),
getSubPropertyReflexiveClosureOf(OWLObjectPropertyExpression)public LinkedHashSet<org.semanticweb.owlapi.model.OWLObjectPropertyExpression> getSubPropertyReflexiveClosureOf(org.semanticweb.owlapi.model.OWLObjectPropertyExpression prop)
prop in all ontologies,
and prop itself as the first element (reflexive).
The returned sub-properties are ordered from the more general (the closest
from prop) to the more precise.
For instance, if prop is "overlaps", the returned properties will be
"overlaps", then "part_of", then "in_deep_part_of", ....prop - the OWLObjectPropertyExpression for which we want
the ordered sub-properties.LinkedHashSet of OWLObjectPropertyExpressions
ordered from the more general to the more precise, with prop
as the first element.getSubPropertiesOf(OWLObjectPropertyExpression),
getSubPropertyClosureOf(OWLObjectPropertyExpression)public LinkedHashSet<org.semanticweb.owlapi.model.OWLObjectPropertyExpression> getSuperPropertyReflexiveClosureOf(org.semanticweb.owlapi.model.OWLObjectPropertyExpression prop)
prop in all ontologies,
and prop itself as the first element (reflexive).
Unlike the method owltools.graph.OWLGraphWrapperEdges.getSuperPropertyReflexiveClosureOf,
the returned super properties here are ordered from the more precise to the more general
(e.g., "in_deep_part_of", then "part_of", then "overlaps").getSuperPropertyReflexiveClosureOf in class OWLGraphWrapperEdgesprop - the OWLObjectPropertyExpression for which we want
the ordered super properties.LinkedHashSet of OWLObjectPropertyExpressions
ordered from the more precise to the more general, with prop
as the first element.public LinkedHashSet<OWLGraphEdge> getOWLGraphEdgeSubRelsReflexive(OWLGraphEdge edge)
edge. This method returns
OWLGraphEdges with their OWLQuantifiedPropertys
corresponding to the sub-properties of the properties of edge
(even indirect sub-properties), ordered from the more general relations
(the closest to edge) to the more precise relations.
The first OWLGraphEdge in the returned Set
is edge (reflexive method).
This is the opposite method of
owltools.graph.OWLGraphWrapperEdges.getOWLGraphEdgeSubsumers(OWLGraphEdge),
with reflexivity added.
edge - A OWLGraphEdge for which all sub-relations
should be obtained.Set of OWLGraphEdges representing
the sub-relations of edge ordered from the more general
to the more precise relation, with edge as the first element.
An empty Set if the OWLQuantifiedPropertys
of edge have no sub-properties.public OWLGraphEdge combineEdgePairWithSuperPropsAndGCI(OWLGraphEdge firstEdge, OWLGraphEdge secondEdge)
firstEdge and secondEdge to create a new edge
from the source of firstEdge to the target of secondEdge,
with properties combined in a regular way, and over super properties.
This method is similar to
owltools.graph.OWLGraphWrapperEdges#combineEdgePair(OWLObject, OWLGraphEdge,
OWLGraphEdge, int),
except it also tries to combine the OWLQuantifiedPropertys of the edges
over super properties (see combinePropertyPairOverSuperProperties(
OWLQuantifiedProperty, OWLQuantifiedProperty), currently combines over
2 properties only).
If one or both of the edges are GCI relations, and that their GCI fillers and/or
GCI relations are related (see hasFirstEdgeMoreGeneralGCIParams(OWLGraphEdge,
OWLGraphEdge)), the combined returned edge will have the most restrictive
GCI filler and GCI relation. If they are not related, the edges will not be combined.
firstEdge - A OWLGraphEdge that is the first edge to combine,
its source will be the source of the new edgesecondEdge - A OWLGraphEdge that is the second edge to combine,
its target will be the target of the new edgeOWLGraphEdge resulting from the composition of
firstEdge and secondEdge,
with its OWLQuantifiedPropertys composed
in a regular way, but also over super properties,
and with the most restrictive GCI filler and GCI relation.public Set<OWLGraphEdge> getOutgoingEdgesNamedClosureOverSupProps(org.semanticweb.owlapi.model.OWLObject s)
OWLGraphWrapperEdges.getOutgoingEdgesClosure(OWLObject),
except that only the OWLGraphEdges going to a named target are returned,
and that the list of connecting edge properties are not only combined using the
composition rules as usual, but also over super properties (see for instance
#combineEdgePairWithSuperPropsAndGCI(OWLGraphEdge, OWLGraphEdge).
Also, redundant edges are filtered: if an edge is a sub-property of another one, only the most precise edge is returned.
s - The OWLObject which outgoing edges start from.Set of OWLGraphEdges that represent
the graph closure originating from s,
with OWLQuantifiedPropertys combined using
standard composition rules, but also over super-properties.public Set<OWLGraphEdge> getOutgoingEdgesNamedClosureOverSupPropsWithGCI(org.semanticweb.owlapi.model.OWLObject s)
getOutgoingEdgesNamedClosureOverSupProps(OWLObject) but with
the OBO GCI relations also taken into account.
If both edges are GCI relations, and their GCI fillers and/or
GCI relations are related (see hasFirstEdgeMoreGeneralGCIParams(OWLGraphEdge,
OWLGraphEdge)), the combined returned edge will have the most restrictive
GCI filler and GCI relation. If they are not related, the edges will not be combined.
To retrieve all ancestors of an object, using also GCI relations,
you should rather use getNamedAncestorsWithGCI(OWLObject).
s - See getOutgoingEdgesNamedClosureOverSupProps(OWLObject)getOutgoingEdgesNamedClosureOverSupProps(OWLObject)public Set<OWLGraphEdge> getOutgoingEdgesClosureWithGCI(org.semanticweb.owlapi.model.OWLObject s)
OWLGraphWrapperEdges.getOutgoingEdgesClosure(OWLObject), but also considering
OBO GCI relations.
Note that GCI relations are not combined when their gci_filler or gci_relation are different. The closure might then be incomplete.
s - See OWLGraphWrapperEdges.getOutgoingEdgesClosure(OWLObject)OWLGraphWrapperEdges.getOutgoingEdgesClosure(OWLObject)public Set<OWLGraphEdge> getGCIOutgoingEdges(org.semanticweb.owlapi.model.OWLClass s)
s as a Set of OWLGraphEdges.
This is similar to the method OWLGraphWrapperEdges.getOutgoingEdges(OWLObject),
but returning GCI relations only. The OBO "gci_filler" and "gci_relation"
could be retrieved by calling OWLGraphEdge.getGCIFiller() and
OWLGraphEdge.getGCIRelation(), respectively.
More formally: OBO GCI relations are represented as SubClassOf axioms,
where the sub-class is an ObjectIntersectionOf, with one operand
being an OWLClass, and the other operand being
an ObjectSomeValuesFrom(ObjectPropertyExpression OWLClass).
The ObjectPropertyExpression will be retrieved by calling
OWLGraphEdge.getGCIRelation(), the associated OWLClass in the
ObjectSomeValuesFrom will be retrieved by calling
OWLGraphEdge.getGCIFiller(). The OWLClass operand in
the ObjectIntersectionOf will be considered as the source
of the OWLGraphEdge. The target will be the super-class
of the SubClassOf axiom, expanded to reach a named target
(as usually with methods in OWLGraphWrapper). The current
implementation assumes that OWLGraphEges representing OBO GCI relations
always have OWLClasses as source and target.
s - An OWLClass for which we want to retrieve outgoing OBO GCI
relations.Set of OWLGraphEdges corresponding to GCI relations
outgoing from s.public Set<OWLGraphEdge> getGCIOutgoingEdges(org.semanticweb.owlapi.model.OWLClass s, Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProps)
getGCIOutgoingEdges(OWLClass), but with a Set of
OWLPropertyExpression allowing to filter the relations retrieved.s - See getGCIOutgoingEdges(OWLClass).overProps - A Set of OWLPropertyExpression allowing
to filter the OWLGraphEdges returned.getGCIOutgoingEdges(OWLClass).getGCIOutgoingEdges(OWLClass)public Set<OWLGraphEdge> getGCIIncomingEdges(org.semanticweb.owlapi.model.OWLClass t)
t as a Set of OWLGraphEdges.
See #getGCIOutgoingEdges(OWLObject) for details about OBO GCI relations,
and about retrieving the associated "gci_filler" and "gci_relation".t - An OWLClass for which we want to retrieve incoming OBO GCI
relations.Set of OWLGraphEdges corresponding to GCI relations
incoming to t.public Set<OWLGraphEdge> getOutgoingEdgesWithGCI(org.semanticweb.owlapi.model.OWLObject s)
OWLGraphWrapperEdges.getOutgoingEdges(OWLObject), but the returned
Set also includes OBO GCI outgoing edges (see
getGCIOutgoingEdges(OWLClass)).s - An OWLObject for which we want to retrieve outgoing edges,
including OBO GCI relations.Set of OWLGraphEdges outgoing from s,
including OBO GCI relations.getOutgoingEdgesWithGCI(OWLObject, Set),
getGCIOutgoingEdges(OWLClass)public Set<OWLGraphEdge> getOutgoingEdgesWithGCI(org.semanticweb.owlapi.model.OWLObject s, Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProperties)
OWLGraphWrapperEdges.getOutgoingEdges(OWLObject, Set), but the returned
Set also includes OBO GCI outgoing edges (see
getGCIOutgoingEdges(OWLClass)).s - An OWLObject for which we want to retrieve outgoing edges,
including OBO GCI relations.overProps - A Set of OWLPropertyExpression allowing
to filter the OWLGraphEdges returned.Set of OWLGraphEdges outgoing from s,
including OBO GCI relations.getGCIOutgoingEdges(OWLClass)public Set<OWLGraphEdge> getIncomingEdgesWithGCI(org.semanticweb.owlapi.model.OWLObject t)
OWLGraphWrapperEdges.getIncomingEdges(OWLObject), but the returned
Set also includes OBO GCI incoming edges (see
getGCIIncomingEdges(OWLClass)).t - An OWLObject for which we want to retrieve incoming edges,
including OBO GCI relations.Set of OWLGraphEdges incoming to t,
including OBO GCI relations.getGCIIncomingEdges(OWLClass)public Set<org.semanticweb.owlapi.model.OWLNamedObject> getNamedAncestorsWithGCI(org.semanticweb.owlapi.model.OWLObject sourceObject)
OWLGraphWrapperEdges.getNamedAncestors(OWLObject) but also
considering GCI relations.sourceObject - An OWLObject for which we want to retrieve ancestors
through classical relations and through OBO GCI relations.Set of OWLNamedObjects that are ancestors of
sourceObject through classical relations and through OBO GCI relations.getNamedAncestorsWithGCI(OWLObject, Set),
#getOWLClassAncestorsWithGCI(OWLObject, Set)public Set<org.semanticweb.owlapi.model.OWLNamedObject> getNamedAncestorsWithGCI(org.semanticweb.owlapi.model.OWLObject sourceObject, Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProps)
getNamedAncestorsWithGCI(OWLObject, Set) but allowing to filter
the relations considered.sourceObject - An OWLObject for which we want to retrieve ancestors
through classical relations and through OBO GCI relations.overProps - A Set of OWLPropertyExpression allowing to filter
the relations considered to retrieve ancestors.Set of OWLObjects that are ancestors of
sourceObject through classical relations and through OBO GCI relations,
filtered using overProps.getNamedAncestorsWithGCI(OWLObject),
getOWLClassAncestorsWithGCI(OWLObject)public Set<org.semanticweb.owlapi.model.OWLClass> getOWLClassAncestorsWithGCI(org.semanticweb.owlapi.model.OWLObject sourceObject)
getNamedAncestorsWithGCI(OWLObject) but returning only
OWLClasses.sourceObject - An OWLObject for which we want to retrieve ancestors
through classical relations and through OBO GCI relations.Set of OWLClasss that are ancestors of
sourceObject through classical relations and through OBO GCI relations.public Set<org.semanticweb.owlapi.model.OWLClass> getOWLClassDirectDescendantsWithGCI(org.semanticweb.owlapi.model.OWLClass parentClass)
getOWLClassDirectDescendants(OWLClass) but also considering GCI relations.parentClass - An OWLClass for which we want to retrieve direct descendants
through classical relations and through OBO GCI relations.Set of OWLClasss that are direct descendants of parentClass
through classical relations and through OBO GCI relations.public Set<org.semanticweb.owlapi.model.OWLClass> getOWLClassDescendantsWithGCI(org.semanticweb.owlapi.model.OWLClass parentClass)
getOWLClassDescendants(OWLClass) but also considering GCI relations.parentClass - An OWLClass for which we want to retrieve descendants
through classical relations and through OBO GCI relations.Set of OWLClasss that are descendants of parentClass
through classical relations and through OBO GCI relations.public Set<org.semanticweb.owlapi.model.OWLClass> getOWLClassDescendantsWithGCI(org.semanticweb.owlapi.model.OWLClass parentClass, Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProps)
#getOWLClassDescendantsWithGCI(OWLObject) but allowing to filter
the relations considered.parentClass - An OWLClass for which we want to retrieve descendants
through classical relations and through OBO GCI relations.overProps - A Set of OWLPropertyExpression allowing to filter
the relations considered to retrieve descendants.Set of OWLClasss that are descendants of parentClass
through classical relations and through OBO GCI relations,
filtered using overProps.public OWLGraphEdge combineEdgePairWithGCI(org.semanticweb.owlapi.model.OWLObject s, OWLGraphEdge ne, OWLGraphEdge extEdge, int nextDist)
OWLGraphWrapperEdges.combineEdgePair(OWLObject, OWLGraphEdge,
OWLGraphEdge, int) except that the GCI filler an GCI relation of the edges
are taken into account.
If both edges are GCI relations, and their GCI fillers and/or
GCI relations are related (see hasFirstEdgeMoreGeneralGCIParams(OWLGraphEdge,
OWLGraphEdge)), the combined returned edge will have the most restrictive
GCI filler and GCI relation. If they are not related, the edges will not be combined.
s - See combineEdgePair method.ne - See combineEdgePair method.extEdge - See combineEdgePair method.nextDist - See combineEdgePair method.combineEdgePair method.OWLGraphWrapperEdges.combineEdgePair(OWLObject, OWLGraphEdge, OWLGraphEdge, int)public boolean hasFirstEdgeMoreGeneralGCIParams(OWLGraphEdge firstEdge, OWLGraphEdge otherEdge)
firstEdge
are more general than the GCI parameters of the GCI relation otherEdge.
Note that if the GCI parameters (OWLGraphEdge.getGCIFiller() and
OWLGraphEdge.getGCIRelation()) of firstEdge and of otherEdge
are equal, this method will return false (use
OWLGraphEdge.equalsGCI(OWLGraphEdge) instead). As a result,
this method will also return false if none of the arguments are GCI relations.
For this method to return true, one of the parameters of firstEdge
has to be more general than the same parameter of otherEdge, while
the other parameter of firstEdge is equal or more general than
the same parameter of otherEdge.
Note that the order of the parameters is important (if
hasFirstEdgeMoreGeneralGCI(edge1, edge2) returns true,
hasFirstEdgeMoreGeneralGCI(edge2, edge1) will return false).
firstEdge - An OWLGraphEdge for which we want to determine whether
its GCI parameters are more general than those of otherEdge.otherEdge - An OWLGraphEdge for which we want to determine GCI parameter
inclusion into those of firstEdge.true if firstEdge has more general GCI parameters
than those of otherEdge.public Set<org.semanticweb.owlapi.model.OWLClass> getAncestorsThroughIsA(org.semanticweb.owlapi.model.OWLObject x)
OWLClass ancestors of x only using "is_a" relations
(SubClassOf).x - An OWLObject for which we want to retrieve OWLClass ancestors
through "is_a" relations, even indirect.Set of OWLClasses that are the ancestors of x
through "is_a" relations.getDescendantsThroughIsA(OWLObject)public Set<org.semanticweb.owlapi.model.OWLClass> getDescendantsThroughIsA(org.semanticweb.owlapi.model.OWLObject x)
OWLClass descendants of x only using "is_a" relations
(SubClassOf).x - An OWLObject for which we want to retrieve OWLClass descendants
through "is_a" relations, even indirect.Set of OWLClasses that are the descendants of x
through "is_a" relations.getAncestorsThroughIsA(OWLObject)public void clearCachedEdges()
OWLGraphWrapperEdgesclearCachedEdges in class OWLGraphWrapperEdgesOWLGraphWrapperEdges.cacheEdges()public org.semanticweb.owlapi.model.OWLObject edgeToSourceExpression(OWLGraphEdge e)
OWLGraphEdge into an OWLClassExpression
(but, as the method OWLGraphEdge.getSource() returns an OWLObject,
this method also returns an OWLObject). This is the equivalent method
to OWLGraphWrapperEdges.edgeToTargetExpression(OWLGraphEdge),
but for the source.
This is useful when an OWLGraphEdge corresponds to an OBO gci_relation
(OWLGraphEdge.isGCI() returns true). In that case, the returned value
is an OWLObjectIntersectionOf. If it is not a GCI, the returned value
is equal to OWLGraphEdge.getSource().
e - The OWLGraphEdge for which we want to translate the source
into an OWLClassExpression.OWLObject corresponding to the source of e.public Set<org.semanticweb.owlapi.model.OWLClass> getAllOWLClasses()
OWLClasses from all ontologies,
that are neither top entity (owl:thing), nor bottom entity (owl:nothing),
nor deprecated (OWLGraphWrapperExtended.isObsolete(OWLObject)
returns false).getAllOWLClasses in class OWLGraphWrapperBasicSet containing all "real" OWLClasses
from all ontologies.public Set<org.semanticweb.owlapi.model.OWLClass> getAllOWLClassesFromSource()
OWLClasses from the OWLOntology returned
by OWLGraphWrapperBasic.getSourceOntology(), that are neither top entity (owl:thing),
nor bottom entity (owl:nothing), nor deprecated (OWLGraphWrapperExtended.isObsolete(OWLObject) returns false).Set of OWLClasses from the source ontology,
owl:thing, owl:nothing, deprecated classes excluded.public Set<org.semanticweb.owlapi.model.OWLClass> getOntologyRoots()
OWLClasses root of any ontology
(OWLClasses with no outgoing edges as returned by
{OWLGraphWrapperEdges#getOutgoingEdgesWithGCI(OWLObject)}), and not deprecated
(OWLGraphWrapperExtended.isObsolete(OWLObject) returns false)).Set of OWLClasses that are
the roots of any ontology.public Set<org.semanticweb.owlapi.model.OWLClass> getOntologyRoots(Set<org.semanticweb.owlapi.model.OWLPropertyExpression> overProperties)
OWLClasses root of any ontology over the specified
OWLPropertyExpressions (OWLClasses with no outgoing edges
of the specified type, as returned by
{OWLGraphWrapperEdges#getOutgoingEdgesWithGCI(OWLObject, Set)}), and not deprecated
(OWLGraphWrapperExtended.isObsolete(OWLObject) returns false);
edges going to obsolete classes are not taken into account).
Filtering roots using overProperties allow to ask question such as:
what are the roots of the ontology according only to is_a
and part_of relations.
overProps - A Set of OWLPropertyExpression allowing
to filter the roots returned.Set of OWLClasses that are
the roots of any ontology over the provided OWLPropertyExpressions.public Set<org.semanticweb.owlapi.model.OWLClass> getOntologyLeaves()
OWLClasses leaves of any ontology
(OWLClasses with no incoming edges as returned by
{OWLGraphWrapperEdges#getIncomingEdgesWithGCI(OWLObject)}), and not deprecated
(OWLGraphWrapperExtended.isObsolete(OWLObject) returns false;
edges incoming from an obsolete class are not considered)Set of OWLClasses that are
the leaves of any ontology.public Set<org.semanticweb.owlapi.model.OWLClass> getOWLClassDescendants(org.semanticweb.owlapi.model.OWLClass parentClass)
OWLClasses descendant of parentClass.
This method is the same than
owltools.graph.OWLGraphWrapperEdges.getDescendants(OWLObject),
except it returns only OWLClasses.parentClass - Set of OWLClasses being the descendants
of parentClass.public Set<org.semanticweb.owlapi.model.OWLClass> getOWLClassDirectDescendants(org.semanticweb.owlapi.model.OWLClass parentClass)
OWLClasses directly descendant of parentClass.
This method returns all sources of all edges incoming to parentClass,
that are OWLClasses.parentClass - The OWLClass for which we want the direct
descendant OWLClassesSet of OWLClasses being the direct descendants
of parentClass.OWLGraphWrapperEdges.getIncomingEdges(OWLObject)public Set<org.semanticweb.owlapi.model.OWLClass> getOWLClassDirectAncestors(org.semanticweb.owlapi.model.OWLClass subClass)
OWLClasses that are direct parent of subClass.
This method returns all sources of all edges incoming to subClass,
that are OWLClasses.subClass - Set of OWLClasses being the direct parents
of subClass.OWLGraphWrapperEdges.getOutgoingEdges(OWLObject)public Set<org.semanticweb.owlapi.model.OWLClass> getOWLClassAncestors(org.semanticweb.owlapi.model.OWLClass sourceClass)
OWLClasses ancestor of sourceClass.
This method is the same than
owltools.graph.OWLGraphWrapperEdges.getAncestors(OWLObject),
except it returns only the ancestor that are OWLClasses.sourceClass - Set of OWLClasses being the ancestors
of sourceClass.public boolean isRealClass(org.semanticweb.owlapi.model.OWLObject object)
object is an OWLClass that is neither owl:thing,
nor owl:nothing, and that it is not deprecated
(OWLGraphWrapperExtended.isObsolete(OWLObject) returns false).object - An OWLObject to be checked to be an OWLClass
actually used.true if object is an OWLClass that is not
owl:thing, nor owl:nothing, and is not deprecated.Copyright © 2010–2015. All rights reserved.