Class Port

java.lang.Object
de.xima.fc.common.graphdot.Port
All Implemented Interfaces:
IGraphDotElement, Serializable

public final class Port extends Object implements IGraphDotElement
Represents a graph dot port. Either an ID or compass point is required.
"my-port" : ne
"my-port"
ne
Since:
8.2.0
Author:
XIMA MEDIA GmbH
See Also:
  • Constructor Details

    • Port

      public Port(CharSequence id, ECompassPointType compassPoint)
      Creates a new port. Either an ID or a compass point is required.
      Parameters:
      id - Optional ID of the port.
      compassPoint - Optional compass point of the port.
  • Method Details

    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • getCompassPoint

      public ECompassPointType getCompassPoint()
      Returns:
      Optional direction of the port.
    • getId

      public CharSequence getId()
      Returns:
      ID of the port. Never null, but may be empty.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • write

      public void write(GraphDotModelWriter writer) throws IOException
      Description copied from interface: IGraphDotElement
      Writes this element to the given writer, as a string in the graph dot language representing this element.
      Specified by:
      write in interface IGraphDotElement
      Parameters:
      writer - Writer to write to.
      Throws:
      IOException - When the writer could not be written to.
    • toGraphDotString

      public final String toGraphDotString()
      Description copied from interface: IGraphDotElement
      Creates a string in the graph dot language representing this element.
      Specified by:
      toGraphDotString in interface IGraphDotElement
      Returns:
      The graph dot representation of this graph dot element.
    • toString

      public final String toString()
      Overrides:
      toString in class Object