Class SequenceLifelineView

java.lang.Object
com.nomagic.magicdraw.uml.MDElementImpl
com.nomagic.magicdraw.uml.symbols.PresentationElement
com.nomagic.magicdraw.uml.symbols.paths.PathConnector
com.nomagic.magicdraw.uml.symbols.shapes.ShapeElement
com.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView
com.nomagic.magicdraw.uml.symbols.shapes.AbstractHeaderShapeView
com.nomagic.magicdraw.uml.symbols.shapes.BaseHeaderShapeView
com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
com.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
com.nomagic.magicdraw.uml.symbols.shapes.BaseLifelineView
com.nomagic.magicdraw.uml.symbols.shapes.SequenceLifelineView
All Implemented Interfaces:
BaseElement, com.nomagic.magicdraw.uml.CompartmentSupport, MDElement, ModelElementProvider, com.nomagic.magicdraw.uml.symbols.CompartmentContainer, com.nomagic.magicdraw.uml.symbols.CompartmentOwner, com.nomagic.magicdraw.uml.symbols.manipulators.centerlines.CenterlineableShape, com.nomagic.magicdraw.uml.symbols.PropertyBasedPresentationElement, com.nomagic.magicdraw.uml.symbols.shapes.OwnerNameLabelOwner, com.nomagic.magicdraw.uml.symbols.shapes.QualifiedNameLabelOwner, StereotypesDisplayModeOwner, com.nomagic.magicdraw.uml.symbols.shapes.StickyShapeElement, com.nomagic.magicdraw.uml.symbols.SuspendShapeAutoResizeModeProvider, com.nomagic.magicdraw.uml.symbols.Wrapable, NameOwner, PropertyChangeListener, Cloneable, Comparable, EventListener

@OpenApi public class SequenceLifelineView extends com.nomagic.magicdraw.uml.symbols.shapes.BaseLifelineView implements com.nomagic.magicdraw.uml.symbols.shapes.StickyShapeElement
Creates lifeline "head" in sequence diagram.
  • Field Details

    • TOP_Y

      public static final int TOP_Y
      Sequence objects top left corner y coordinate.
      See Also:
  • Constructor Details

    • SequenceLifelineView

      public SequenceLifelineView()
    • SequenceLifelineView

      public SequenceLifelineView(@CheckForNull PresentationElement parent)
  • Method Details

    • getStickyDistance

      public int getStickyDistance()
      Specified by:
      getStickyDistance in interface com.nomagic.magicdraw.uml.symbols.shapes.StickyShapeElement
    • getMainLifeLine

      @CheckForNull public LifeLineLineView getMainLifeLine()
      Returns:
      main lifeline
    • sSetShowEntireActivation

      public void sSetShowEntireActivation(boolean show)
    • isShowEntireActivation

      public boolean isShowEntireActivation()
    • isShowSelector

      public boolean isShowSelector()
    • internalSilentApply

      public void internalSilentApply()
      Description copied from class: PresentationElement
      Silently applies all properties after initialization
      Overrides:
      internalSilentApply in class com.nomagic.magicdraw.uml.symbols.shapes.BaseLifelineView
    • setShowEntireActivation

      public void setShowEntireActivation(boolean show)
    • internalApplyProperties

      public void internalApplyProperties(com.dassault_systemes.modeler.magic.diagram.styledelegates.PresentationElementStyleChanger changer)
      Description copied from class: PresentationElement
      Applies properties from given property manager
      Overrides:
      internalApplyProperties in class com.nomagic.magicdraw.uml.symbols.shapes.BaseLifelineView
      Parameters:
      changer - new properties
    • canHavePaths

      public boolean canHavePaths()
      Overrides:
      canHavePaths in class ShapeElement
      Returns:
      true if symbol can have connected paths. Return false here.
    • internalSpecificUpdate

      protected void internalSpecificUpdate()
      Description copied from class: com.nomagic.magicdraw.uml.symbols.shapes.AbstractHeaderShapeView
      Specific to every shape and model element update operation. Must be overridden in subclasses if you need to do specific tasks. !!! Important - all resizing, paths moving and so on is done in updatePresentationElement and should not be done in specific update.
      Overrides:
      internalSpecificUpdate in class com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
      See Also:
      • AbstractHeaderShapeView.internalUpdatePresentationElement()
    • clone

      public SequenceLifelineView clone()
      Specified by:
      clone in interface BaseElement
      Overrides:
      clone in class com.nomagic.magicdraw.uml.symbols.shapes.BaseHeaderShapeView
    • canAddInstance

      public boolean canAddInstance(PresentationElement symbol)
      Description copied from class: PresentationElement
      Object view has no children.
      Overrides:
      canAddInstance in class com.nomagic.magicdraw.uml.symbols.shapes.AbstractHeaderShapeView
    • accept

      public void accept(Visitor visitor) throws Exception
      Description copied from interface: MDElement
      Method accepts a visitor, and calls method "visit<class name>(this)" of a visitor. See "Visitor" pattern for more details.
      Specified by:
      accept in interface MDElement
      Overrides:
      accept in class com.nomagic.magicdraw.uml.symbols.shapes.BaseLifelineView
      Parameters:
      visitor - which visits this element.
      Throws:
      Exception
    • resizeParent

      public void resizeParent()
      Description copied from class: PresentationElement
      Method that initiates parent resize to accommodate children if some child's bounds are changed.
      Overrides:
      resizeParent in class PresentationElement
    • prefDimensionByManipulatedChildren

      protected void prefDimensionByManipulatedChildren(Dimension pref, int locationX, int locationY)
      Overrides:
      prefDimensionByManipulatedChildren in class com.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView
    • autosizeByChildren

      public void autosizeByChildren(boolean calculatePrefSize)
      Overrides:
      autosizeByChildren in class com.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView
    • internalGetManipulatedChildrenRect

      @CheckForNull protected Rectangle internalGetManipulatedChildrenRect(com.nomagic.magicdraw.uml.symbols.shapes.InsetsLevel insetsLevel)
      Description copied from class: com.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView
      Calculate union area of owned manipulated children added not on a shape border
      Overrides:
      internalGetManipulatedChildrenRect in class com.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView
      Parameters:
      insetsLevel - include insets if shape has manipulated children
      Returns:
      rectangle of children or null if there are no children
    • adjustBounds

      public void adjustBounds(Rectangle bounds)
      Description copied from class: ShapeElement
      Validates bounds
      Overrides:
      adjustBounds in class ShapeElement
      Parameters:
      bounds - bounds
    • internalSnapToGrid

      protected void internalSnapToGrid(Point p, float step)
      Overrides:
      internalSnapToGrid in class PresentationElement
    • setCreated

      public void setCreated(boolean created)
    • isCreated

      public boolean isCreated()
    • getAllMessages

      public List<com.nomagic.magicdraw.uml.symbols.paths.SeqBaseMessageView> getAllMessages()
    • getAllLifelines

      public List<LifeLineLineView> getAllLifelines()
    • moveObjectToXY

      @CheckForNull public Rectangle moveObjectToXY(int newX, int newY)
    • movePathElement

      public void movePathElement(PathElement link, @CheckForNull PathConnector requestor)
      Description copied from class: PathConnector
      Calculates position of a path element.
      Overrides:
      movePathElement in class com.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
      Parameters:
      link - element which position will be calculated.
      requestor - the requestor of this path moving. Implementations may check to avoid endless loops.
    • getCreateMessage

      @CheckForNull public com.nomagic.magicdraw.uml.symbols.paths.SeqBaseMessageView getCreateMessage()
      Returns:
      if lifeline is created by message, returns that message
    • getDeleteMessage

      @CheckForNull public com.nomagic.magicdraw.uml.symbols.paths.SeqBaseMessageView getDeleteMessage()
      Gets delete message destroying this lifeline.
      Returns:
      delete message is this lifeline is destroyed, null otherwise.
    • adjustBoundsBeforeChange

      public Rectangle adjustBoundsBeforeChange(Rectangle rec, boolean autosizeOperation, Collection<PresentationElement> movedTogether)
      Description copied from class: PresentationElement
      Validate bounds before bounds change operation
      Overrides:
      adjustBoundsBeforeChange in class com.nomagic.magicdraw.uml.symbols.shapes.AbstractHeaderShapeView
    • getMinimalDistanceFromTop

      public int getMinimalDistanceFromTop()
    • findOwnerForElement

      public com.dassault_systemes.modeler.foundation.model.ModelElement findOwnerForElement(PresentationElement parent, com.dassault_systemes.modeler.foundation.model.ModelElementOwnershipContext ownershipContext)
      Overrides:
      findOwnerForElement in class PresentationElement
    • internalAppendChildRect

      protected boolean internalAppendChildRect(PresentationElement view)
      Overrides:
      internalAppendChildRect in class com.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView
    • canSuppressContent

      public boolean canSuppressContent()
      Overrides:
      canSuppressContent in class com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
    • getSeqContainer

      public com.nomagic.magicdraw.uml.symbols.SequenceObjectViewContainer getSeqContainer()
    • autosize

      public void autosize(boolean calculatePrefSize)
      Description copied from class: ShapeElement
      Calculate preferred size and make this shape size at least as preferred (if size is smaller)
      Overrides:
      autosize in class com.nomagic.magicdraw.uml.symbols.shapes.AbstractHeaderShapeView
      Parameters:
      calculatePrefSize - calculate preferred size
    • canUseEntireActivation

      public boolean canUseEntireActivation()
    • isUseEntireActivation

      public boolean isUseEntireActivation()
    • atInsert

      public void atInsert()
      Description copied from class: PresentationElement
      Invalidates object at insert
      Specified by:
      atInsert in interface BaseElement
      Overrides:
      atInsert in class com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
    • rememberBounds

      public void rememberBounds()
      Description copied from class: PresentationElement
      Remember old bounds
      Overrides:
      rememberBounds in class PresentationElement
    • rememberBounds

      public void rememberBounds(Rectangle bounds)
      Overrides:
      rememberBounds in class PresentationElement
    • getLifelinesCollector

      public com.nomagic.magicdraw.uml.symbols.SequenceObjectViewContainer.LifelineCollector getLifelinesCollector()
    • isDrawSeparator

      protected boolean isDrawSeparator()
      Overrides:
      isDrawSeparator in class com.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
    • canChangeParent

      public boolean canChangeParent(Collection<? extends PresentationElement> movedTogether, @CheckForNull BaseElement newParent, boolean changeElementParent)
      Description copied from class: PresentationElement
      Returns true, if element can change parent.
      Overrides:
      canChangeParent in class com.nomagic.magicdraw.uml.symbols.shapes.BaseHeaderShapeView
      Parameters:
      movedTogether - collection of the elements, whose will change the parent together with this.
      newParent - new symbol parent
      changeElementParent - change element parent
      Returns:
      true if parent of symbol can be changed
    • hasSharedModelElement

      public boolean hasSharedModelElement()
      Description copied from class: PresentationElement
      Returns true if ModelElement of this symbol can represented with other symbol. If ModelElement is not shared, it can be deleted together with symbol deleting.
      Overrides:
      hasSharedModelElement in class com.nomagic.magicdraw.uml.symbols.shapes.BaseHeaderShapeView
      Returns:
      true if element of this symbol can be represented with other symbol.
    • createSmartListenerConfig

      protected void createSmartListenerConfig(List<SmartListenerConfig> configurations)
      Overrides:
      createSmartListenerConfig in class com.nomagic.magicdraw.uml.symbols.shapes.BaseLifelineView
    • getHeaderView

      public com.nomagic.magicdraw.uml.symbols.shapes.SequenceLifelineHeaderView getHeaderView()
      Overrides:
      getHeaderView in class com.nomagic.magicdraw.uml.symbols.shapes.BaseLifelineView