Class UMLBasicObject

java.lang.Object
com.xxrjun.components.uml.UMLObject
com.xxrjun.components.uml.basics.UMLBasicObject
Direct Known Subclasses:
ClassBasicObject, UseCaseBasicObject

public abstract class UMLBasicObject extends UMLObject
The type Uml basic object.
  • Constructor Details

    • UMLBasicObject

      protected UMLBasicObject(int x, int y, int width, int height, String objectName, UMLObjectTypes objectType)
      Instantiates a new Uml basic object.
      Parameters:
      x - the x
      y - the y
      width - the width
      height - the height
      objectName - the object name
      objectType - the object type
  • Method Details

    • initializePorts

      public void initializePorts()
      Description copied from class: UMLObject
      Initialize ports.
      Specified by:
      initializePorts in class UMLObject
    • highlightSelection

      public void highlightSelection(Graphics g)
      Description copied from class: UMLObject
      Highlight selection.
      Specified by:
      highlightSelection in class UMLObject
      Parameters:
      g - the g
    • contains

      public boolean contains(Point p)
      Description copied from class: UMLObject
      Contains boolean.
      Specified by:
      contains in class UMLObject
      Parameters:
      p - the p
      Returns:
      the boolean
    • findNearestPort

      public UMLPort findNearestPort(Point point)
      Find nearest port uml port.
      Parameters:
      point - the point
      Returns:
      the uml port
    • updateConnectionLine

      public void updateConnectionLine()
      Update connection line.
    • updateLocation

      public void updateLocation(int deltaX, int deltaY)
      Description copied from class: UMLObject
      Update location.
      Overrides:
      updateLocation in class UMLObject
      Parameters:
      deltaX - the move x
      deltaY - the move y
    • addConnectionLine

      public void addConnectionLine(UMLConnectionLine connectionLine, UMLConnectionLine.EndPointTypes endPointType)
      Add connection line.
      Parameters:
      connectionLine - the connection line
      endPointType - the end point type
    • setObjectName

      public void setObjectName(String objectName)
      Sets object name.
      Parameters:
      objectName - the object name
    • getObjectName

      public String getObjectName()
      Gets object name.
      Returns:
      the object name
    • drawObjectName

      public void drawObjectName(int width, int textOffset, Graphics g)
      Draw object name.
      Parameters:
      width - the width
      textOffset - the text offset
      g - the g