public class SpeciesSubsetterUtil extends Object
Modifier and Type | Field and Description |
---|---|
org.semanticweb.owlapi.reasoner.OWLReasoner |
reasoner |
org.semanticweb.owlapi.model.OWLClass |
rootClass |
org.semanticweb.owlapi.model.OWLClass |
taxClass |
org.semanticweb.owlapi.model.OWLObjectProperty |
viewProperty |
Constructor and Description |
---|
SpeciesSubsetterUtil(OWLGraphWrapper g)
Constructor providing the
OWLGraphWrapper wrapping the OWLOntology
used for species subsetting. |
Modifier and Type | Method and Description |
---|---|
Collection<List<org.semanticweb.owlapi.model.OWLObject>> |
explainTaxonConstraint(Collection<String> clsIds,
Collection<String> taxonIds)
Provides explanations about the sources of some taxon constraints on
the
OWLClass es provided through clsIds , related to the taxa
provided through taxonIds . |
void |
removeOtherSpecies() |
public org.semanticweb.owlapi.reasoner.OWLReasoner reasoner
public org.semanticweb.owlapi.model.OWLObjectProperty viewProperty
public org.semanticweb.owlapi.model.OWLClass taxClass
public org.semanticweb.owlapi.model.OWLClass rootClass
public SpeciesSubsetterUtil(OWLGraphWrapper g)
OWLGraphWrapper
wrapping the OWLOntology
used for species subsetting. This OWLOntology
will be immediately modified
to remove relations that could generate incorrect taxon constraints.g
- OWLGraphWrapper
wrapping the OWLOntology
to use.public void removeOtherSpecies()
public Collection<List<org.semanticweb.owlapi.model.OWLObject>> explainTaxonConstraint(Collection<String> clsIds, Collection<String> taxonIds) throws IllegalArgumentException
OWLClass
es provided through clsIds
, related to the taxa
provided through taxonIds
. This method allows to know why a given term,
in the OWLOntology
provided at instantiation, is defined as existing,
or not existing, in some given taxa.
For each requested OWLClass
, explanations are provided as paths going from
the OWLClass
, to a taxon constraint pertinent to any of the requested taxa.
A path is represented as a List
of OWLObject
s. The first
OWLObject
is always one of the requested OWLClass
.
Following OWLObject
s are either OWLClass
es, or anonymous
OWLClassExpression
s, representing the targets of SubClassOfAxiom
s.
The final OWLObject
is either an anonymous OWLClassExpression
s
representing a "only_in_taxon" relation, or an OWLAnnotation
representing a "never_in_taxon" annotation.
If some of the requested OWLClass
es are not found in the returned
explanations, or their explanations do not cover all requested taxa, it means
there is no particular explanation for existence of these OWLClass
es
in the taxon, they simply exist by default.
clsIds
- A Set
of String
s that are the OBO-like IDs
of the OWLClass
for which we want to retrieve
explanations about taxon constraints, from the ontology
provided at instantiation of this class.taxonIds
- A Set
of String
s that are the OBO-like IDs
of the taxa for which we want to retrieve explanations
about presence or absence of the OWLClass
es
provided through clsIds
.Collection
of List
s of OWLObject
s,
where each List
correspond to a walk explaining
a taxon constraint.IllegalArgumentException
- If some of the requested OWLClass
es
or requested taxa could not be found in
the ontology provided at instantiation.Copyright © 2010–2015. All rights reserved.