Java 类org.semanticweb.owlapi.model.OWLSubAnnotationPropertyOfAxiom 实例源码

项目:owltools    文件:Mooncat.java   
void addSubAnnotationProperties(Set<OWLAxiom> axioms) {
    // add ALL subannotprop axioms
    // - this is quite geared towards obo ontologies, where
    //   we want to preserve obo headers.
    // TODO: make this configurable
    LOG.info("adding SubAnnotationProperties");
    Set<OWLAxiom> sapAxioms = new HashSet<OWLAxiom>();
    for (OWLOntology refOnt : this.getReferencedOntologies()) {
        for (OWLSubAnnotationPropertyOfAxiom a : refOnt.getAxioms(AxiomType.SUB_ANNOTATION_PROPERTY_OF)) {
            sapAxioms.add(a);
            Set<OWLAnnotationAssertionAxiom> s = refOnt.getAnnotationAssertionAxioms(a.getSubProperty().getIRI());
            if (s != null && !s.isEmpty()) {
                for (OWLAnnotationAssertionAxiom owlAnnotationAssertionAxiom : s) {
                    sapAxioms.add(owlAnnotationAssertionAxiom);
                }
            }
        }
    }
    axioms.addAll(sapAxioms);
}
项目:owltools    文件:OWLGraphWrapperEdgesExtended.java   
/**
 * Returns the direct child properties of <code>prop</code> in all ontologies.
 * @param prop      The <code>OWLAnnotationProperty</code> for which 
 *                  we want the direct sub-properties.
 * @return          A <code>Set</code> of <code>OWLAnnotationProperty</code>s 
 *                  that are the direct sub-properties of <code>prop</code>.
 * 
 * @see #getSubPropertyClosureOf(OWLObjectPropertyExpression)
 * @see #getSubPropertyReflexiveClosureOf(OWLObjectPropertyExpression)
 */
public Set<OWLAnnotationProperty> getSubAnnotationPropertiesOf(
        OWLAnnotationProperty prop) {
    Set<OWLAnnotationProperty> subProps = new HashSet<OWLAnnotationProperty>();
    for (OWLOntology ont : this.getAllOntologies()) {
        //we need to iterate each annotation property, to get 
        //its getSubAnnotationPropertyOfAxioms and see if prop is its parent 
        //(there is no method "getSuperAnnotationPropertyOfAxioms").
        for (OWLAnnotationProperty subProp : ont.getAnnotationPropertiesInSignature()) {
            for (OWLSubAnnotationPropertyOfAxiom ax: 
                    ont.getSubAnnotationPropertyOfAxioms(subProp)) {
                if (ax.getSuperProperty().equals(prop)) {
                    subProps.add(subProp);
                }
            }
        }
    }
    return subProps;
}
项目:owlapi-gwt    文件:OWLSubAnnotationPropertyOfAxiomImpl.java   
@Override
public boolean equals(Object obj) {
    if (this == obj) {
        return true;
    }
    if (!super.equals(obj)) {
        return false;
    }
    // superclass is responsible for null, identity, owlaxiom type and
    // annotations
    if (!(obj instanceof OWLSubAnnotationPropertyOfAxiom)) {
        return false;
    }
    OWLSubAnnotationPropertyOfAxiom other = (OWLSubAnnotationPropertyOfAxiom) obj;
    return subProperty.equals(other.getSubProperty())
            && superProperty.equals(other.getSuperProperty());
}
项目:elk-reasoner    文件:AbstractElkObjectConverter.java   
@Override
public OWLSubAnnotationPropertyOfAxiom visit(
        ElkSubAnnotationPropertyOfAxiom axiom) {
    return owlFactory_.getOWLSubAnnotationPropertyOfAxiom(
            convert(axiom.getSubAnnotationProperty()),
            convert(axiom.getSuperAnnotationProperty()));
}
项目:elk-reasoner    文件:AbstractOwlAxiomConverterVisitor.java   
@Override
public T visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    throw new IllegalArgumentException(
            OWLSubAnnotationPropertyOfAxiom.class.getSimpleName()
                    + " cannot be converted to "
                    + getTargetClass().getSimpleName());
}
项目:owltools    文件:OwlHelper.java   
public static Set<OWLAnnotationProperty> getSubProperties(OWLAnnotationProperty superProp, Set<OWLOntology> ontologies) {
    Set<OWLAnnotationProperty> result = new HashSet<OWLAnnotationProperty>();
    for (OWLOntology ont : ontologies) {
        for (OWLSubAnnotationPropertyOfAxiom ax : ont.getAxioms(AxiomType.SUB_ANNOTATION_PROPERTY_OF)) {
            if (ax.getSuperProperty().equals(superProp)) {
                result.add(ax.getSubProperty());
            }
        }
    }
    return result;
}
项目:owltools    文件:OwlHelper.java   
public static Set<OWLAnnotationProperty> getSuperProperties(OWLAnnotationProperty subProp, Set<OWLOntology> ontologies) {
    Set<OWLAnnotationProperty> result = new HashSet<OWLAnnotationProperty>();
    for (OWLOntology ont : ontologies) {
        for (OWLSubAnnotationPropertyOfAxiom ax : ont.getAxioms(AxiomType.SUB_ANNOTATION_PROPERTY_OF)) {
            if (ax.getSubProperty().equals(subProp)) {
                result.add(ax.getSuperProperty());
            }
        }
    }
    return result;
}
项目:owltools    文件:OWLConverter.java   
/**
 * Convenience method for asserting a subAnnotationProperty relation 
 * between a parent and child property in an ontology.
 *
 * @param ontology the current ontology
 * @param child the child property
 * @param parent the parent property
 * @return the axiom
 */
protected static OWLSubAnnotationPropertyOfAxiom
        assertSubAnnotationProperty(
        OWLOntology ontology, OWLAnnotationProperty child,
        OWLAnnotationProperty parent) {
    OWLOntologyManager manager = ontology.getOWLOntologyManager();
    OWLDataFactory dataFactory = manager.getOWLDataFactory();
    OWLSubAnnotationPropertyOfAxiom axiom = 
        dataFactory.getOWLSubAnnotationPropertyOfAxiom(
            child, parent);
    manager.addAxiom(ontology, axiom);
    return axiom;
}
项目:SciGraph    文件:GraphOwlVisitor.java   
@Override
public Void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
  long subProperty =
      getOrCreateNode(getIri(axiom.getSubProperty()), OwlLabels.OWL_ANNOTATION_PROPERTY);
  long superProperty =
      getOrCreateNode(getIri(axiom.getSuperProperty()), OwlLabels.OWL_ANNOTATION_PROPERTY);
  getOrCreateRelationship(subProperty, superProperty, OwlRelationships.RDFS_SUB_PROPERTY_OF);
  return null;
}
项目:owlapi-gwt    文件:OWLSubAnnotationPropertyOfAxiomImpl.java   
@Override
public OWLSubAnnotationPropertyOfAxiom getAxiomWithoutAnnotations() {
    if (!isAnnotated()) {
        return this;
    }
    return new OWLSubAnnotationPropertyOfAxiomImpl(getSubProperty(),
            getSuperProperty(), NO_ANNOTATIONS);
}
项目:owlapi-gwt    文件:OWLSubAnnotationPropertyOfAxiomImpl.java   
@Override
protected int compareObjectOfSameType(OWLObject object) {
    OWLSubAnnotationPropertyOfAxiom other = (OWLSubAnnotationPropertyOfAxiom) object;
    int diff = subProperty.compareTo(other.getSubProperty());
    if (diff != 0) {
        return diff;
    }
    return superProperty.compareTo(other.getSuperProperty());
}
项目:jopa    文件:IntegrityConstraintParser.java   
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    notSupported(axiom);
}
项目:HermiT-android    文件:OWLNormalization.java   
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
}
项目:HermiT-android    文件:EntailmentChecker.java   
public Boolean visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    return Boolean.TRUE;
}
项目:HermiT-android    文件:EntailmentChecker.java   
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
}
项目:elk-reasoner    文件:OwlAnnotationAxiomConverterVisitor.java   
@Override
public ElkAnnotationAxiom visit(OWLSubAnnotationPropertyOfAxiom owlSubAnnotationPropertyOfAxiom) {
    return new ElkSubAnnotationPropertyOfAxiomWrap<OWLSubAnnotationPropertyOfAxiom>(owlSubAnnotationPropertyOfAxiom);
}
项目:elk-reasoner    文件:OwlAxiomConverterVisitor.java   
@Override
public ElkAxiom visit(
        OWLSubAnnotationPropertyOfAxiom owlSubAnnotationPropertyOfAxiom) {
    return CONVERTER.convert(owlSubAnnotationPropertyOfAxiom);
}
项目:elk-reasoner    文件:FailingOwlAxiomVisitor.java   
@Override
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    defaultVisit(axiom);
}
项目:Hermit_1.3.8_android    文件:OWLNormalization.java   
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
}
项目:Hermit_1.3.8_android    文件:EntailmentChecker.java   
public Boolean visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    return Boolean.TRUE;
}
项目:Hermit_1.3.8_android    文件:EntailmentChecker.java   
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
}
项目:owltools    文件:AxiomAnnotationTools.java   
@Override
public OWLAxiom visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    return factory.getOWLSubAnnotationPropertyOfAxiom(axiom.getSubProperty(), axiom.getSuperProperty(), annotations);
}
项目:owltools    文件:CardinalityContraintsTools.java   
@Override
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
}
项目:Wolpertinger    文件:OWLNormalization.java   
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
}
项目:Wolpertinger    文件:DebugTranslation.java   
public void visit(OWLSubAnnotationPropertyOfAxiom arg0) {
    throw new NotImplementedException();
}
项目:Wolpertinger    文件:NaiveTranslation.java   
public void visit(OWLSubAnnotationPropertyOfAxiom arg0) {
    throw new NotImplementedException();
}
项目:born    文件:CycleDetector.java   
@Override
public Boolean visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    return true;
}
项目:born    文件:ElAxiomFilter.java   
@Override
public Boolean visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    return this.withAnnotations;
}
项目:born    文件:AnnotationProcessor.java   
@Override
public Boolean visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    Objects.requireNonNull(axiom);
    return add(this.df.getOWLSubAnnotationPropertyOfAxiom(axiom.getSubProperty(), axiom.getSuperProperty(),
            reg(axiom.getAnnotations())));
}
项目:born    文件:AnnotationCreator.java   
@Override
public Boolean visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    Objects.requireNonNull(axiom);
    return add(
            this.df.getOWLSubAnnotationPropertyOfAxiom(axiom.getSubProperty(), axiom.getSuperProperty(), empty()));
}
项目:jcel    文件:AxiomTranslator.java   
@Override
public Set<ComplexIntegerAxiom> visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    Objects.requireNonNull(axiom);
    return Collections.emptySet();
}
项目:semantika    文件:TMappingProcessor.java   
@Override
public void visit(OWLSubAnnotationPropertyOfAxiom axiom)
{
   ignoreOwlAxiom("SubAnnotationPropertyOf", axiom);
}
项目:OWL2SPARQL    文件:OWLAxiomToSPARQLConverter.java   
@Override
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    annotationAxiomsNotSupportedWarning(axiom);
}
项目:owlapi-gwt    文件:OWLObjectVisitorExAdapter.java   
@Override
public O visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    return doDefault(axiom);
}
项目:owlapi-gwt    文件:OWLObjectVisitorAdapter.java   
@Override
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    handleDefault(axiom);
}
项目:owlapi-gwt    文件:OWLObjectTypeIndexProvider.java   
@Override
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    type = AXIOM_TYPE_INDEX_BASE + axiom.getAxiomType().getIndex();
}
项目:owlapi-gwt    文件:NNF.java   
@Override
public OWLAxiom visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    return axiom;
}
项目:owlapi-gwt    文件:HashCode.java   
@Override
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    hashCode = primes[75];
    hashCode = hashCode * MULT + axiom.getSubProperty().hashCode();
    hashCode = hashCode * MULT + axiom.getSuperProperty().hashCode();
}
项目:owlapi-gwt    文件:OWLAxiomVisitorAdapter.java   
@Override
public void visit(OWLSubAnnotationPropertyOfAxiom axiom) {
    handleDefault(axiom);
}
项目:owlapi-gwt    文件:AbstractEntityRegistrationManager.java   
@Override
public void visit(@Nonnull OWLSubAnnotationPropertyOfAxiom axiom) {
    axiom.getSubProperty().accept(this);
    axiom.getSuperProperty().accept(this);
    processAxiomAnnotations(axiom);
}