/** * Adds the qualifiers. * * @param c the c * @param qualifiers the qualifiers */ protected static void addQualifiers(Clause c, Stream<OWLAnnotation> qualifiers) { qualifiers.forEach(a -> addQualifiers(c, a)); }
/** * Adds the qualifiers. * * @param c the c * @param qualifiers the qualifiers */ protected static void addQualifiers(Clause c, Stream<OWLAnnotation> qualifiers) { qualifiers.forEach(a -> addQualifiers(c, a)); }
/** * Adds the qualifiers. * * @param c the c * @param qualifiers the qualifiers */ protected static void addQualifiers(Clause c, Stream<OWLAnnotation> qualifiers) { qualifiers.forEach(a -> addQualifiers(c, a)); }
/** * Adds the qualifiers. * * @param c the c * @param qualifiers the qualifiers */ protected static void addQualifiers(Clause c, Stream<OWLAnnotation> qualifiers) { qualifiers.forEach(a -> addQualifiers(c, a)); }
/** * Tr object property. * * @param prop the prop * @param tag the tag * @param value the value * @param annotations the annotations * @return true, if successful */ protected boolean trObjectProperty(@Nullable OWLObjectProperty prop, @Nullable String tag, @Nullable String value, Stream<OWLAnnotation> annotations) { if (prop == null || value == null) { return false; } addQualifiers(clause(prop, tag, value), annotations); return true; }
/** * Tr object property. * * @param prop the prop * @param tag the tag * @param value the value * @param annotations the annotations * @return true, if successful */ protected boolean trObjectProperty(@Nullable OWLObjectProperty prop, @Nullable String tag, @Nullable String value, Stream<OWLAnnotation> annotations) { if (prop == null || value == null) { return false; } addQualifiers(clause(prop, tag, value), annotations); return true; }
/** * Tr object property. * * @param prop the prop * @param tag the tag * @param value the value * @param annotations the annotations * @return true, if successful */ protected boolean trObjectProperty(@Nullable OWLObjectProperty prop, @Nullable String tag, @Nullable String value, Stream<OWLAnnotation> annotations) { if (prop == null || value == null) { return false; } addQualifiers(clause(prop, tag, value), annotations); return true; }
/** * Tr object property. * * @param prop the prop * @param tag the tag * @param value the value * @param annotations the annotations * @return true, if successful */ protected boolean trObjectProperty(@Nullable OWLObjectProperty prop, @Nullable String tag, @Nullable String value, Stream<OWLAnnotation> annotations) { if (prop == null || value == null) { return false; } addQualifiers(clause(prop, tag, value), annotations); return true; }
/** * Tr object property. * * @param prop the prop * @param tag the tag * @param value the value * @param annotations the annotations * @return true, if successful */ protected boolean trObjectProperty(@Nullable OWLObjectProperty prop, String tag, @Nullable Boolean value, Stream<OWLAnnotation> annotations) { if (prop == null || value == null) { return false; } Frame f = getTypedefFrame(prop); Clause clause = new Clause(tag); clause.addValue(value); f.addClause(clause); addQualifiers(clause, annotations); return true; }
/** * Tr object property. * * @param prop the prop * @param tag the tag * @param value the value * @param annotations the annotations * @return true, if successful */ protected boolean trObjectProperty(@Nullable OWLObjectProperty prop, String tag, @Nullable Boolean value, Stream<OWLAnnotation> annotations) { if (prop == null || value == null) { return false; } Frame f = getTypedefFrame(prop); Clause clause = new Clause(tag); clause.addValue(value); f.addClause(clause); addQualifiers(clause, annotations); return true; }
/** * Tr object property. * * @param prop the prop * @param tag the tag * @param value the value * @param annotations the annotations * @return true, if successful */ protected boolean trObjectProperty(@Nullable OWLObjectProperty prop, String tag, @Nullable Boolean value, Stream<OWLAnnotation> annotations) { if (prop == null || value == null) { return false; } Frame f = getTypedefFrame(prop); Clause clause = new Clause(tag); clause.addValue(value); f.addClause(clause); addQualifiers(clause, annotations); return true; }
/** * Tr object property. * * @param prop the prop * @param tag the tag * @param value the value * @param annotations the annotations * @return true, if successful */ protected boolean trObjectProperty(@Nullable OWLObjectProperty prop, String tag, @Nullable Boolean value, Stream<OWLAnnotation> annotations) { if (prop == null || value == null) { return false; } Frame f = getTypedefFrame(prop); Clause clause = new Clause(tag); clause.addValue(value); f.addClause(clause); addQualifiers(clause, annotations); return true; }
/** * Creates the relationship clause with restrictions. * * @param r the r * @param fillerId the filler id * @param qvs the qvs * @param ax the ax * @return the clause */ protected Clause createRelationshipClauseWithRestrictions(OWLQuantifiedObjectRestriction r, String fillerId, Set<QualifierValue> qvs, OWLSubClassOfAxiom ax) { Clause c = new Clause(OboFormatTag.TAG_RELATIONSHIP.getTag()); c.addValue(getIdentifier(r.getProperty())); c.addValue(fillerId); c.setQualifierValues(qvs); addQualifiers(c, ax.annotations()); return c; }
/** * Creates the relationship clause with restrictions. * * @param r the r * @param fillerId the filler id * @param qvs the qvs * @param ax the ax * @return the clause */ protected Clause createRelationshipClauseWithRestrictions(OWLQuantifiedObjectRestriction r, String fillerId, Set<QualifierValue> qvs, OWLSubClassOfAxiom ax) { Clause c = new Clause(OboFormatTag.TAG_RELATIONSHIP.getTag()); c.addValue(getIdentifier(r.getProperty())); c.addValue(fillerId); c.setQualifierValues(qvs); addQualifiers(c, ax.annotations()); return c; }
/** * Creates the relationship clause with restrictions. * * @param r the r * @param fillerId the filler id * @param qvs the qvs * @param ax the ax * @return the clause */ protected Clause createRelationshipClauseWithRestrictions(OWLQuantifiedObjectRestriction r, String fillerId, Set<QualifierValue> qvs, OWLSubClassOfAxiom ax) { Clause c = new Clause(OboFormatTag.TAG_RELATIONSHIP.getTag()); c.addValue(getIdentifier(r.getProperty())); c.addValue(fillerId); c.setQualifierValues(qvs); addQualifiers(c, ax.annotations()); return c; }
/** * Creates the relationship clause with restrictions. * * @param r the r * @param fillerId the filler id * @param qvs the qvs * @param ax the ax * @return the clause */ protected Clause createRelationshipClauseWithRestrictions(OWLQuantifiedObjectRestriction r, String fillerId, Set<QualifierValue> qvs, OWLSubClassOfAxiom ax) { Clause c = new Clause(OboFormatTag.TAG_RELATIONSHIP.getTag()); c.addValue(getIdentifier(r.getProperty())); c.addValue(fillerId); c.setQualifierValues(qvs); addQualifiers(c, ax.annotations()); return c; }
protected void tr(OWLSubObjectPropertyOfAxiom ax) { OWLObjectPropertyExpression sup = ax.getSuperProperty(); OWLObjectPropertyExpression sub = ax.getSubProperty(); if (sub.isBottomEntity() || sub.isTopEntity() || sup.isBottomEntity() || sup .isTopEntity()) { error("SubProperties using Top or Bottom entites are not supported in OBO.", false); return; } if (sub.isOWLObjectProperty() && sup.isOWLObjectProperty()) { String supId = checkNotNull(getIdentifier(sup)); if (supId.startsWith("owl:")) { return; } Frame f = getTypedefFrame((OWLObjectProperty) sub); Clause clause = new Clause(OboFormatTag.TAG_IS_A, supId); f.addClause(clause); addQualifiers(clause, ax.annotations()); } else { error(ax, true); } }
protected void tr(OWLSubObjectPropertyOfAxiom ax) { OWLObjectPropertyExpression sup = ax.getSuperProperty(); OWLObjectPropertyExpression sub = ax.getSubProperty(); if (sub.isBottomEntity() || sub.isTopEntity() || sup.isBottomEntity() || sup .isTopEntity()) { error("SubProperties using Top or Bottom entites are not supported in OBO.", false); return; } if (sub.isOWLObjectProperty() && sup.isOWLObjectProperty()) { String supId = checkNotNull(getIdentifier(sup)); if (supId.startsWith("owl:")) { return; } Frame f = getTypedefFrame((OWLObjectProperty) sub); Clause clause = new Clause(OboFormatTag.TAG_IS_A, supId); f.addClause(clause); addQualifiers(clause, ax.annotations()); } else { error(ax, true); } }
protected void tr(OWLSubObjectPropertyOfAxiom ax) { OWLObjectPropertyExpression sup = ax.getSuperProperty(); OWLObjectPropertyExpression sub = ax.getSubProperty(); if (sub.isBottomEntity() || sub.isTopEntity() || sup.isBottomEntity() || sup .isTopEntity()) { error("SubProperties using Top or Bottom entites are not supported in OBO.", false); return; } if (sub.isOWLObjectProperty() && sup.isOWLObjectProperty()) { String supId = checkNotNull(getIdentifier(sup)); if (supId.startsWith("owl:")) { return; } Frame f = getTypedefFrame((OWLObjectProperty) sub); Clause clause = new Clause(OboFormatTag.TAG_IS_A, supId); f.addClause(clause); addQualifiers(clause, ax.annotations()); } else { error(ax, true); } }
protected void tr(OWLSubObjectPropertyOfAxiom ax) { OWLObjectPropertyExpression sup = ax.getSuperProperty(); OWLObjectPropertyExpression sub = ax.getSubProperty(); if (sub.isBottomEntity() || sub.isTopEntity() || sup.isBottomEntity() || sup .isTopEntity()) { error("SubProperties using Top or Bottom entites are not supported in OBO.", false); return; } if (sub.isOWLObjectProperty() && sup.isOWLObjectProperty()) { String supId = checkNotNull(getIdentifier(sup)); if (supId.startsWith("owl:")) { return; } Frame f = getTypedefFrame((OWLObjectProperty) sub); Clause clause = new Clause(OboFormatTag.TAG_IS_A, supId); f.addClause(clause); addQualifiers(clause, ax.annotations()); } else { error(ax, true); } }