java.lang.Object
org.odpi.openmetadata.viewservices.assetcatalog.beans.Element
org.odpi.openmetadata.viewservices.assetcatalog.beans.Relationship

public class Relationship extends Element
The Relationship object holds properties that are used for displaying a relationship between two assets
  • Constructor Details

    • Relationship

      public Relationship()
      Default constructor.
  • Method Details

    • getFromEntity

      public Element getFromEntity()
      Returns the start element for the relationship.
      Returns:
      the start element for the relationship
    • setFromEntity

      public void setFromEntity(Element fromEntity)
      Set up the start element for the relationship.
      Parameters:
      fromEntity - the start element for the relationship
    • getToEntity

      public Element getToEntity()
      Returns the destination element for the relationship.
      Returns:
      the destination element for the relationship
    • setToEntity

      public void setToEntity(Element toEntity)
      Set up the destination element for the relationship.
      Parameters:
      toEntity - the destination element for the relationship
    • toString

      public String toString()
      Standard toString method.
      Overrides:
      toString in class Element
      Returns:
      print out of variables in a JSON-style
    • equals

      public boolean equals(Object objectToCompare)
      Compare the values of the supplied object with those stored in the current object.
      Overrides:
      equals in class Element
      Parameters:
      objectToCompare - supplied object
      Returns:
      boolean result of comparison
    • hashCode

      public int hashCode()
      Return hash code based on properties.
      Overrides:
      hashCode in class Element
      Returns:
      int