Class CommentView

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.CommentView
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.PlainTextOrHTMLChangeable, com.nomagic.magicdraw.uml.symbols.shapes.QualifiedNameLabelOwner, StereotypesDisplayModeOwner, com.nomagic.magicdraw.uml.symbols.SuspendShapeAutoResizeModeProvider, com.nomagic.magicdraw.uml.symbols.Wrapable, NameOwner, PropertyChangeListener, Cloneable, Comparable, EventListener

@OpenApi public class CommentView extends com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView implements com.nomagic.magicdraw.uml.symbols.shapes.PlainTextOrHTMLChangeable, com.nomagic.magicdraw.uml.symbols.shapes.OwnerNameLabelOwner
  • Constructor Details

    • CommentView

      public CommentView()
    • CommentView

      public CommentView(@CheckForNull PresentationElement parent)
  • Method Details

    • 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
    • dispose

      public void dispose()
      Description copied from class: PresentationElement
      disposes ends of links when link is deleted
      Specified by:
      dispose in interface BaseElement
      Overrides:
      dispose in class com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
    • getCommentBody

      public com.nomagic.magicdraw.uml.symbols.shapes.TextObject getCommentBody()
    • getDefaultDimension

      protected UnmodifiableDimension getDefaultDimension()
      Overrides:
      getDefaultDimension in class ShapeElement
    • internalGetHeaderInsets

      protected com.nomagic.ui.UnmodifiableInsets internalGetHeaderInsets()
      Overrides:
      internalGetHeaderInsets in class com.nomagic.magicdraw.uml.symbols.shapes.BaseHeaderShapeView
    • selfSpecificHeaderShapeDraw

      protected void selfSpecificHeaderShapeDraw(com.nomagic.magicdraw.uml.symbols.DiagramPaintContext context)
      Overrides:
      selfSpecificHeaderShapeDraw in class com.nomagic.magicdraw.uml.symbols.shapes.BaseHeaderShapeView
    • 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()
    • 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.HeaderShapeView
      Parameters:
      visitor - which visits this element.
      Throws:
      Exception
    • 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.HeaderShapeView
      Parameters:
      changer - new properties
    • 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.HeaderShapeView
    • getOwnerDisplayMode

      public String getOwnerDisplayMode()
      Description copied from interface: com.nomagic.magicdraw.uml.symbols.shapes.OwnerNameLabelOwner
      Gets the owner display mode string.
      Specified by:
      getOwnerDisplayMode in interface com.nomagic.magicdraw.uml.symbols.shapes.OwnerNameLabelOwner
      Returns:
      on of the QNAME_DISPLAY_MODES list elements.
    • sSetOwnerDisplayMode

      public void sSetOwnerDisplayMode(String mode)
      Description copied from interface: com.nomagic.magicdraw.uml.symbols.shapes.OwnerNameLabelOwner
      Sets the owner display mode without updating shape view.
      Specified by:
      sSetOwnerDisplayMode in interface com.nomagic.magicdraw.uml.symbols.shapes.OwnerNameLabelOwner
      Parameters:
      mode - the new mode
    • setOwnerDisplayMode

      public void setOwnerDisplayMode(String mode)
      Description copied from interface: com.nomagic.magicdraw.uml.symbols.shapes.OwnerNameLabelOwner
      Sets the owner display mode and updates the view.
      Specified by:
      setOwnerDisplayMode in interface com.nomagic.magicdraw.uml.symbols.shapes.OwnerNameLabelOwner
      Parameters:
      mode - the new mode
    • updateName

      protected void updateName()
      Description copied from class: com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
      Updates name and owner qualified name text in header view.
      Overrides:
      updateName in class com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
    • internalGetSelfManipulationPreferredSize

      protected UnmodifiableDimension internalGetSelfManipulationPreferredSize()
      Overrides:
      internalGetSelfManipulationPreferredSize in class com.nomagic.magicdraw.uml.symbols.shapes.BaseHeaderShapeView
      Returns:
      size for manipulation which does not take into account the size of children on some specific conditions (for example, in case if wrapped text)
    • setHTMLText

      public void setHTMLText(boolean isHtml)
      Specified by:
      setHTMLText in interface com.nomagic.magicdraw.uml.symbols.shapes.PlainTextOrHTMLChangeable
    • sSetHTMLText

      public void sSetHTMLText(boolean isHtml)
    • isHTMLText

      public boolean isHTMLText()
      Specified by:
      isHTMLText in interface com.nomagic.magicdraw.uml.symbols.shapes.PlainTextOrHTMLChangeable
    • getUserText

      public String getUserText()
      Returns the pure text. If html text is presented, this method returns not tml text, but user visible text.
      Returns:
      the user visible text.
    • createSmartListenerConfig

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

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

      public boolean isVerticalCenterlineProvider()
      Description copied from class: ShapeElement
      Indicates whether this shape provides vertical center-lines to other shapes.
      Overrides:
      isVerticalCenterlineProvider in class ShapeElement
      Returns:
      true if this shape provides vertical center lines, false otherwise.
    • isHorizontalCenterlineProvider

      public boolean isHorizontalCenterlineProvider()
      Description copied from class: ShapeElement
      Indicates whether this shape provides horizontal center-lines to other shapes.
      Overrides:
      isHorizontalCenterlineProvider in class ShapeElement
      Returns:
      true if this shape provides horizontal center-lines, false otherwise.
    • getElement

      public Comment getElement()
      Description copied from class: PresentationElement
      Returns model element of this presentation element. Some presentation elements (for example TextBoxes) do not have model elements.
      Specified by:
      getElement in interface ModelElementProvider
      Overrides:
      getElement in class PresentationElement
      Returns:
      model element of this presentation element.