Class Edge


public class Edge extends OntologyElement
A relationship between two nodes. Currently the only kinds of edges supported in KGCL: A subClassOf B <==> Edge(subject=A, predicate=owl:subClassOf, object=B) A subClassOf P some B <==> Edge(subject=A, predicate=P, object=B) P subPropertyOf Q <==> Edge(subject=P, predicate=owl:subPropertyOf, object=Q) These represent the most common kind of pairwise relationship between classes, and classes are the dominant node type in ontologies. In future a wider variety of OWL axiom types will be supportedn through the use of an additional edge property/slot to indicate the interpretation of the axiom, following owlstar (https://github.com/cmungall/owlstar). For example: `A subClassOf R only B <==> Edge(subject=A, predicate=P, object=B, interpretation=AllOnly)` `A Annotation(P,B) <==> Edge(subject=A, predicate=P, object=B, interpretation=annotationAssertion)` Note that not all axioms are intended to map to edges. Axioms/triples where the object is a literal would be represented as node properties. Complex OWL axioms involving nesting would have their own dedicated construct, or may be represented generically. These are out of scope for the current version of KGCL
  • Constructor Details

    • Edge

      public Edge()
  • Method Details

    • getSubject

      public Node getSubject()
    • getPredicate

      public Node getPredicate()
    • getObject

      public Node getObject()
    • getSubjectRepresentation

      public String getSubjectRepresentation()
    • getPredicateRepresentation

      public String getPredicateRepresentation()
    • getObjectRepresentation

      public String getObjectRepresentation()
    • getAnnotationSet

      public Annotation getAnnotationSet()
    • setSubject

      public void setSubject(Node subject)
    • setPredicate

      public void setPredicate(Node predicate)
    • setObject

      public void setObject(Node object)
    • setSubjectRepresentation

      public void setSubjectRepresentation(String subjectRepresentation)
    • setPredicateRepresentation

      public void setPredicateRepresentation(String predicateRepresentation)
    • setObjectRepresentation

      public void setObjectRepresentation(String objectRepresentation)
    • setAnnotationSet

      public void setAnnotationSet(Annotation annotationSet)
    • toString

      public String toString()
      Overrides:
      toString in class OntologyElement
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class OntologyElement
    • canEqual

      protected boolean canEqual(Object other)
      Overrides:
      canEqual in class OntologyElement
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class OntologyElement