public class MetadataRelationship extends ElementHeader
MetadataRelationship describes a relationship between two metadata elements. These relationships are directional (end1->end1) - although it is possible to navigate the relationships in either direction.
  • Constructor Details

    • MetadataRelationship

      public MetadataRelationship()
      Default constructor
    • MetadataRelationship

      public MetadataRelationship(MetadataRelationship template)
      Copy/clone constructor
      Parameters:
      template - template to copy
    • MetadataRelationship

      public MetadataRelationship(ElementHeader template)
      Copy/clone constructor
      Parameters:
      template - template to copy
  • Method Details

    • setProperties

      public void setProperties(Map<String,Object> properties)
      Set up the properties for the element. If no stored properties are present then null is returned.
      Parameters:
      properties - properties for the classification
    • getProperties

      public Map<String,Object> getProperties()
      Return a collection of the properties for the element. If no stored properties are present then null is returned.
      Returns:
      properties map
    • getEnd1

      public ElementStub getEnd1()
      Return the summary of the metadata element at end 1 of the relationship.
      Returns:
      element stub
    • setEnd1

      public void setEnd1(ElementStub end1)
      Set up the summary of the metadata element at end 1 of the relationship.
      Parameters:
      end1 - element stub
    • getEnd2

      public ElementStub getEnd2()
      Return the summary of the metadata element at end 2 of the relationship.
      Returns:
      element stub
    • setEnd2

      public void setEnd2(ElementStub end2)
      Set up the summary of the metadata element at end 2 of the relationship.
      Parameters:
      end2 - element stub
    • toString

      public String toString()
      Standard toString method.
      Overrides:
      toString in class ElementHeader
      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 ElementHeader
      Parameters:
      objectToCompare - supplied object
      Returns:
      boolean result of comparison
    • hashCode

      public int hashCode()
      Create a hash code for this element type.
      Overrides:
      hashCode in class ElementHeader
      Returns:
      int hash code