Class PartView
- java.lang.Object
-
- com.nomagic.magicdraw.uml.MDElementImpl
-
- com.nomagic.magicdraw.uml.ElementImpl
-
- 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.HeaderShapeView
-
- com.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
-
- com.nomagic.magicdraw.uml.symbols.shapes.PartView
-
- All Implemented Interfaces:
BaseElement,CompartmentElement,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.shapes.PortOwner,com.nomagic.magicdraw.uml.symbols.shapes.QualifiedNameLabelOwner,StereotypesDisplayModeOwner,com.nomagic.magicdraw.uml.symbols.SuspendShapeAutoResizeModeProvider,com.nomagic.magicdraw.uml.symbols.Wrapable,NameOwner,java.beans.PropertyChangeListener,java.lang.Cloneable,java.lang.Comparable,java.util.EventListener
@OpenApi public class PartView extends com.nomagic.magicdraw.uml.symbols.shapes.TypedElementView implements CompartmentElement, com.nomagic.magicdraw.uml.symbols.shapes.PortOwner
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.nomagic.magicdraw.uml.symbols.shapes.AbstractHeaderShapeView
com.nomagic.magicdraw.uml.symbols.shapes.AbstractHeaderShapeView.StereotypeDisplayData
-
Nested classes/interfaces inherited from class com.nomagic.magicdraw.uml.symbols.shapes.ShapeElement
com.nomagic.magicdraw.uml.symbols.shapes.ShapeElement.OnEdgeBounds
-
Nested classes/interfaces inherited from class com.nomagic.magicdraw.uml.symbols.PresentationElement
com.nomagic.magicdraw.uml.symbols.PresentationElement.SmartListenerConfigData, com.nomagic.magicdraw.uml.symbols.PresentationElement.StructureCache
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.List<Property>nestedPathprivate java.util.List<SmartPropertyChangeListener>nestedPathListeners-
Fields inherited from class com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
SECONDARY_IMAGE_AND_STEREOTYPE_DISPLAY_MODE_DO_NOT_DISPLAY, SECONDARY_IMAGE_AND_STEREOTYPE_DISPLAY_MODE_IMAGE_AND_STEREOTYPES, SECONDARY_IMAGE_AND_STEREOTYPE_DISPLAY_MODE_STEREOTYPES, SECONDARY_IMAGE_AND_STEREOTYPE_DISPLAY_MODES
-
Fields inherited from class com.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView
CONTAINER_SHAPE_INSETS
-
Fields inherited from class com.nomagic.magicdraw.uml.symbols.shapes.ShapeElement
BORDER_ELEMENT_MARGIN_ALL, BORDER_ELEMENT_MARGIN_BOTTOM, BORDER_ELEMENT_MARGIN_LEFT, BORDER_ELEMENT_MARGIN_LEFT_RIGHT, BORDER_ELEMENT_MARGIN_MODES, BORDER_ELEMENT_MARGIN_NONE, BORDER_ELEMENT_MARGIN_RIGHT, BORDER_ELEMENT_MARGIN_TOP, BORDER_ELEMENT_MARGIN_TOP_BOTTOM, BOTTOM_EDGE, INSIDE_EDGE_POSITION, LEFT_EDGE, NEED_AUTOSIZE_FULL, NEED_AUTOSIZE_LAYOUT, NEED_AUTOSIZE_NONE, NO_EDGE, NULL_INSETS, ON_EDGE_POSITION, OUTSIDE_EDGE_POSITION, RIGHT_EDGE, SPACE, SPACE_INSETS, SPACE_INSETS_EMPTY_TOP_BOTTOM, SUSPEND_SHAPE_AUTO_RESIZE_FALSE, SUSPEND_SHAPE_AUTO_RESIZE_MODES, SUSPEND_SHAPE_AUTO_RESIZE_SAME_AS_DIAGRAM, SUSPEND_SHAPE_AUTO_RESIZE_TRUE, TOP_EDGE
-
Fields inherited from class com.nomagic.magicdraw.uml.symbols.paths.PathConnector
showsProxy
-
Fields inherited from class com.nomagic.magicdraw.uml.symbols.PresentationElement
DASHED_STROKE, DEFAULT_LINE_WIDTH, DOTTED_STROKE, HANDLE_SIZE, MAX_LINE_WIDTH, MIN_LINE_WIDTH, SHADOW_WIDTH, SOLID_STROKE
-
Fields inherited from interface com.nomagic.magicdraw.uml.symbols.shapes.QualifiedNameLabelOwner
QNAME_DISPLAY_MODE_ABOVE_NAME, QNAME_DISPLAY_MODE_BELOW_NAME, QNAME_DISPLAY_MODE_DO_NOT_DISPLAY, QNAME_DISPLAY_MODE_MERGE_WITH_NAME, QNAME_DISPLAY_MODES
-
Fields inherited from interface com.nomagic.magicdraw.uml.symbols.shapes.StereotypesDisplayModeOwner
DSL_STEREOTYPE_DISPLAY_MODE_ALL, DSL_STEREOTYPE_DISPLAY_MODE_LAST, DSL_STEREOTYPE_DISPLAY_MODE_NONE, DSL_STEREOTYPE_DISPLAY_MODES, STEREOTYPE_DISPLAY_MODE_DO_NOT_DISPLAY_STEREOTYPES, STEREOTYPE_DISPLAY_MODE_ICON, STEREOTYPE_DISPLAY_MODE_SHAPE_IMAGE, STEREOTYPE_DISPLAY_MODE_SHAPE_IMAGE_AND_TEXT, STEREOTYPE_DISPLAY_MODE_TEXT, STEREOTYPE_DISPLAY_MODE_TEXT_AND_ICON, STEREOTYPES_DISPLAY_MODES, STEREOTYPES_DISPLAY_MODES_SIMPLE
-
-
Constructor Summary
Constructors Constructor Description PartView()PartView(PresentationElement parent)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidaccept(Visitor o)Method accepts visitor, and calls method visit<class name>(this) of visitor .voidaddPresentationElement(PresentationElement element, int index, boolean resize)private booleanaddThisIntoStructureCompartment(PresentationElement obj)booleancanAddChild(PresentationElement obj)Check of given symbol can be added as child into this symbol.booleancanAddInstance(PresentationElement obj)Object view has no children.booleancanChangeParent(java.util.Collection<? extends PresentationElement> movedTogether, BaseElement newParent, boolean changeElementParent)Returns true, if element can change parent.PartViewclone()Returns a copy of theElement.private static booleancontainsProperty(Classifier classifier, Property property)PropertycreateChangedCompartmentVisibilityProperty(com.nomagic.magicdraw.uml.symbols.shapes.Compartment compartment, boolean showCompartment)protected voidcreateSmartListenerConfig(java.util.List<SmartListenerConfig> configurations)ElementfindParentForData(PresentationElement newParent, com.nomagic.uml2.ext.jmi.helpers.ElementAddContext addContext)static PresentationElementfindPresentationElement(java.util.List<PresentationElement> elements, Element element, java.util.List<Property> nestedPath)Finds existing symbol among the given ones with a given Element and given nestedPathprivate voidfixNestedPath()Fix nested path if possible.ClassifiergetClassifier()java.lang.StringgetCompartmentElementID()java.lang.StringgetCompartmentText()PropertygetElement()Returns model element of this presentation element.ElementgetElementFromParentSymbol()ElementgetElementFromParentSymbol(PresentationElement parent)ElementgetElementToMove()Returns element that should be used for during "move" operation.EncapsulatedClassifiergetEncapsulatedClassifier()TypedElementgetEncapsulatedClassifierProvider()ElementgetExpectedDataParent(PresentationElement child)Returns expected element parent.protected intgetHeaderInsetReduce(int edge, com.nomagic.magicdraw.uml.symbols.shapes.ShapeElement.OnEdgeBounds bounds)com.nomagic.magicdraw.uml.symbols.shapes.PartHeaderViewgetHeaderView()java.lang.StringgetMetaClassifiersQPropertyName()java.util.List<Property>getNestedPath()intgetOnEdgePosition()Returns position on edge.PropertygetProperty()Deprecated.use #getElementprivate static ElementgetProxyElementFromParentSymbol(PresentationElement parent)java.lang.StringgetShowSlotTypeMode()Gets value of slot showing property.com.nomagic.magicdraw.uml.symbols.shapes.StructureCompartmentViewgetStructureCompartment()java.lang.StringgetTaggedValuesDisplayMode()voidinternalApplyProperties(PropertyManager propertyManager)Applies properties from given property managerprotected com.nomagic.ui.UnmodifiableInsetsinternalGetHeaderInsets()java.awt.BasicStrokeinternalGetPresentationElementStroke(int width)Return a stroke used to paint symbol's main partvoidinternalLayoutChildren(boolean calculatePrefSize)voidinternalSilentApply()Silently applies all properties after initializationprotected voidinternalSpecificUpdate()protected booleanisDrawSeparator()private booleanisInheritedPart()booleanisInOtherPart()private booleanisNestedPartValid(PresentationElement parent)static booleanisPart(PresentationElement obj)booleanisPartPort()static booleanisPartPort(PresentationElement obj)booleanisShowDefaultValue()Returns show default value flag.booleanisShowDefaultValueCompartmentName()Indicates if default value compartment name should be displayed.booleanisShowInheritedSign()booleanisShowMultiplicity()booleanisShowQualifiedNameInTaggedValues()booleanisShowRakeIcon()booleanisShowTaggedValuesStereotypes()booleanisSuppressStructureCompartment()booleanisValid(PresentationElement parent, boolean changeElementParent)Checks if part is valid by symbol ownership in it's current context.protected voidpreferredSizeIgnoringOrientation(java.awt.Dimension pref, int locationX, int locationY)voidpropertyChange(java.beans.PropertyChangeEvent e)Listens for property change it can be: data was edited text box was editedvoidremovePresentationElement(PresentationElement element, boolean resizeParent)voidsAddPresentationElement(PresentationElement element, int index)Add given child to this symbol at given indexbooleansetDummyResizeMode(boolean b)In dummy resize mode symbol may not resize according it children or move children on bounds changed and etc.voidsetNestedPath(java.util.List<Property> nestedPath)voidsetParent(PresentationElement parent)Sets parent for this view.voidsetShowDefaultValue(boolean show)Set show default value flag.voidsetShowDefaultValueCompartmentName(boolean show)Sets show default value compartment name flag value.voidsetShowInheritedSign(boolean showInheritedSign)Show inherited members sign in compartmentvoidsetShowMultiplicity(boolean showMultiplicity)voidsetShowQualifiedNameInTaggedValues(boolean show)voidsetShowSlotTypeMode(java.lang.String mode)Sets value of slot showing property.voidsetShowTaggedValuesStereotypes(boolean show)voidsetSuppressStructureCompartment(boolean b)voidsetTaggedValuesDisplayMode(java.lang.String mode)voidsRemovePresentationElement(PresentationElement element)Removes given childvoidsSetClassifiers(java.util.List<Classifier> type)voidsSetNestedPath(java.util.List<Property> nestedPart, boolean disposeOldListeners)voidsSetShowDefaultValue(boolean show)Set show default value flag.voidsSetShowDefaultValueCompartmentName(boolean show)Simple sets show default value compartment name flag value.voidsSetShowInheritedSign(boolean showInheritedSign)Show inherited signvoidsSetShowMultiplicity(boolean showMultiplicity)voidsSetShowQualifiedNameInTaggedValues(boolean show)voidsSetShowSlotTypeMode(java.lang.String mode)Sets value of slot showing property.voidsSetShowTaggedValuesStereotypes(boolean show)voidsSetSuppressStructureCompartment(boolean b)voidsSetTaggedValuesDisplayMode(java.lang.String mode)-
Methods inherited from class com.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
addBreakPoints, checkShowsProxy, doActualShapeDrawing, getClassifiers, getDefaultDimension, getSeparatorDistanceFromRightSide, getStereotypesToDisplay, getTypeClass, isActive, isDrawUnderLine, isShowClass, isShowFullType, movePathElement, selfSpecificHeaderShapeDraw, setDrawUnderLine, setShowClass, setShowFullType, sSetShowClass, sSetShowFullType
-
Methods inherited from class com.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
addCompartment, addCompartment, areBoxCompartmentsSuppressed, atInsert, canHideBorder, canSuppressContent, childrenBoundsForReshape, createBoundsShape, createCompartmentElements, createStateForUpdateOperation, dispose, doInternalLayoutAdditionCompartment, doInternalLayoutChildren, getAdditionalCompartment, getAdditionalCompartmentContainer, getAdditionalCompartmentInsets, getAdditionalCompartmentToLayout, getAdditionalRenderersToNotify, getBooleanCompartmentPropertyValue, getChildrenBoundsForPreferredBounds, getChildrenInsets, getCollections, getCompartmentByID, getCompartmentContainer, getCompartmentIDs, getCompartmentRegistrationInfo, getCompartments, getConfiguredPreferredSizeForAutosize, getConstraintAndTaggedValueAlignment, getConstraintTextMode, getDefaultElementStereotypeToHeader, getDSLStereotypesDisplayMode, getElementNumberDisplayMode, getElementPropertiesCompartmentView, getHeaderMaxYForShrinkableShape, getHeaderVerticalPositionForLayout, getMainCompartmentContainer, getName, getPreferredDimensionForAutosize, getQNameDisplayMode, getSecondaryImageAndStereotypeDisplayMode, getStereotypeLabel, getStereotypesDisplayMode, getSuppressCompartmentPropertyID, hasManipulatedChildrenIncludingIndirect, internalAddIndirectManipulatedChildrenRect, internalGetIndirectManipulatedChildrenRect, internalGetSelfManipulationPreferredSize, internalPostSpecificUpdate, internalSetCollections, isBorderVisible, isChildLayoutable, isChildMovable, isMakePreferredSizeAfterPropertiesChange, isShowConstraints, isShowDerivedSign, isShowElementProperties, isShowIcon, isShowNumberTagName, isShowRakeSymbol, isShowTaggedValues, isShowType, isWrapEnabled, makePreferredSizeAfterPropertiesChange, makePreferredSizeAfterPropertiesChange, onChildEdgeChange, paintSelf, recursiveAutosize, removeCompartment, removeCompartment, setCollections, setCompartmentSuppressed, setConstraintAndTaggedValueAlignment, setConstraints, setConstraintTextMode, setDSLStereotypesDisplayMode, setElementNumberDisplayMode, setHeaderObject, setMakePreferredSizeAfterPropertiesChange, setQNameDisplayMode, setReshapeMode, setSecondaryImageAndStereotypeDisplayMode, setShowCompartmentName, setShowConstraints, setShowDerivedSign, setShowElementProperties, setShowIcon, setShowNumberTagName, setShowTaggedValues, setShowType, setStereotype, setStereotypesDisplayMode, setTaggedValues, setVisibleElements, setWrapEnabled, sSetCompartmentSuppressed, sSetConstraintAndTaggedValueAlignment, sSetConstraintTextMode, sSetDSLStereotypesDisplayMode, sSetElement, sSetElementNumberDisplayMode, sSetName, sSetQNameDisplayMode, sSetSecondaryImageAndStereotypeDisplayMode, sSetShowCompartmentName, sSetShowConstraints, sSetShowDerivedSign, sSetShowElementProperties, sSetShowIcon, sSetShowNumberTagName, sSetShowTaggedValues, sSetShowType, sSetStereotypesDisplayMode, sSetWrapEnabled, updateBorderVisibility, updateChildrenVisibility, updateCompartmentsVisibility, updateName
-
Methods inherited from class com.nomagic.magicdraw.uml.symbols.shapes.AbstractHeaderShapeView
autosize, autosizeAndResizeParent, calculateMinY, calculateOvalShapePreferredSize, correctChildrenVector, coversPoint, editName, getAdditionalHeaderHeightForPreferredBounds, getHeaderBoundsForPreferredBounds, getHeaderDistanceFromTopForOvalShape, getHeaderInsets, getHeaderObject, getHeaderVerticalPosition, getNameLabel, getOvalShapeAvailableWidth, getPreferredBounds, getPresentationElementAt, getProxyPresentationElementsStream, internalGetHeaderBoundsForPreferredBounds, internalPostUpdatePresentationElement, internalPreSpecificUpdate, internalUpdatePresentationElement, invalidate, isContentHidden, isHeaderOrientationVertical, isOvalShape, isParentShowsProxy, minimumDimension, minimumDimensionForShrinking, minimumSizeForShrinkingIgnoringOrientation, minimumSizeIgnoringOrientation, paintChildren, preferredDimension, setHeaderVerticalPosition, setName, setTextEditable, sSetAutosize, sSetHeaderVerticalPosition, switchWidthHeightIfVerticalOrientation
-
Methods inherited from class com.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView
addPresentationElement, addPresentationElementWithoutResize, adjustBoundsForMoving, adjustChildBoundsForMoving, autosizeByChildren, calculateAutosizeDimension, calculateAutosizeDimension, canMoveChildOutside, clearShowsProxy, constructLayoutHelper, getChildrenBounds, getChildrenOnBorderBounds, getContainerBounds, getLayoutHelper, getLayoutHelperClone, getManipulatedElementAt, getManipulationPreferredDimension, getPresentationElementIndex, getPresentationElements, getRemovableChildren, hasManipulatedShapesNotOnEdge, hasManipulatedShapesOnEdge, hasManipulatedShapesOnEdge, internalAppendChildRect, internalGetChildAt, internalGetManipulatedChildrenRect, internalGetManipulatedChildrenRect, internalRecursiveAutosizeForChildren, internalSetChildren, isCanChildrenChangeEdge, isCanMoveChildren, layoutChildren, moveChild, moveChildren, needAdjustToPreferred, paintChildrenBackground, prefDimensionByManipulatedChildren, removePresentationElement, setBounds, setBounds, setCanMoveChildren, setFillColor, setLayoutHelper, setPresentationElements, showLinks, simpleSetBounds, simpleSetBounds, sSetPresentationElements
-
Methods inherited from class com.nomagic.magicdraw.uml.symbols.shapes.ShapeElement
adjustBounds, adjustOnEdge, adjustOnEdge, adjustOnEdgeChildren, autosize, calculateAdjustOnEdgeLocation, calculateAndGetMinimumShrinkingDimension, calculateAndGetPreferredDimension, calculateEdge, calculateMinimumDimension, calculateOnEdgeBounds, calculatePreferredDimension, calculatePreferredDimension, canBeAutosized, canHavePaths, clearOldRect, edgeChanged, ensureDimension, ensurePreferredDimensionIfShrinkable, ensurePreferredDimensionIfShrinkable, findFreePlaceForShapeOnBorder, getBorderElementMargin, getBounds, getCenterlineableInnerParts, getDimensionForShrinking, getEdgeLine, getFixedConnectionPoints, getInsetsForOnEdgeShapes, getIntersection, getIntersection, getIntersection, getLoadedDimension, getMiddlePoint, getMiddlePoint, getMiddlePointX, getMiddlePointX, getMiddlePointY, getMiddlePointY, getMinimumDimension, getNearestEdge, getNearestEdge, getNeedAutosizeFlag, getNotCopyBounds, getOnEdge, getOnEdgeCornerDistance, getPreferredDimension, getReshapeMode, getSuspendShapeAutoResizeMode, hasManipulator, initialize, internalGetBoundsShape, intersects, isAutosized, isCenterlineInner, isHorizontalCenterlineProvider, isOnEdge, isShrinkable, isSnapShapesOnBorderToGrid, isSnapToGrid, isUseFixedConnectionPoints, isVerticalCenterlineProvider, layoutChildren, maximumDimension, minimumOrMinimumShrinkableDimension, moveLinksToSelf, movePathElements, needAdjustToMaximumDimension, prepareForShadowDrawing, providesHorizontalCenterline, providesVerticalCenterline, resetCalculatePreferredRegardingChildren, setAutosize, setBorderElementMargin, setCalculatePreferredRegardingChildren, setLoadedDimension, setMinimumDimension, setNeedAutosizeFlag, setOldRect, setOnEdge, setPreferredDimension, setSnapShapesOnBorderToGrid, setSuspendShapeAutoResizeMode, setUseFixedConnectionPoints, shouldDrawShadow, simpleSetBounds, simpleSetBounds, snapsToCenterlines, sSetBorderElementMargin, sSetBounds, sSetSuspendShapeAutoResizeMode, sSetVisibility, toString, updateLater
-
Methods inherited from class com.nomagic.magicdraw.uml.symbols.paths.PathConnector
addConnectedPathElement, disposeConnectedPaths, findSymbolForEnd, findSymbolForEnd, getConnectedPathElement, getConnectedPathElementCount, getConnectedPathElements, getConnectedPathElements, getConnectedPathElements, getPreferredArrowLength, isShowsProxy, movePathElement, removeConnectedPathElement, sAddConnectedPathElement, selectPathsForMoving, setVisibility, sRemoveConnectedPathElement, sSetConnectedPathElements
-
Methods inherited from class com.nomagic.magicdraw.uml.symbols.PresentationElement
addPresentationElement, addProperty, adjustChildBounds, alwaysShowTooltip, applyProperties, askDeleteDataConfirmation, atInsertChildren, autosizeAndResizeManipulatedParent, beforeDelete, boundsChanged, boundsChanged, canAddChild, canAddInstance, canBeDisposedOnUpdate, canChangeElementParent, canChangeParent, canFill, changeProperties, changeProperty, changePropertyManager, checkElementParentOnAdd, checkProxyVisibility, childrenForMoving, clearAntialiasingState, collectSubManipulatedElements, collectSubPresentationElements, collectSubPresentationElements, collectSubShowingPresentationElements, constructChangePropertyCommand, createPropertyChangeListener, createPropertyManager, disposeChildren, disposeListener, draw, drawBackground, drawSymbol, drawSymbolBackground, dynamicFillColor, dynamicLineColor, dynamicLineWidth, dynamicLineWidth, dynamicPaintShadow, dynamicStroke, dynamicStroke, dynamicStroke, dynamicStyleFillColor, dynamicStyleFillPaint, dynamicStyleLineColor, dynamicStyleTextColor, dynamicStyleTransparency, dynamicStyleTransparency, dynamicStyleValue, dynamicTextAlignment, dynamicTextColor, editName, findPresentationElement, firePropertyChange, getActualElement, getActualProperty, getAssignableModelElementsClasses, getBooleanPropertyValue, getBoundsShape, getBoundsToRepaint, getBoundsWithChildrenOnEdge, getCenterlinePoint, getCenterlinePointX, getCenterlinePointY, getChildPresentationElementForContextMenu, getChildrenWithSymbolProperties, getConfiguration, getDiagramPresentationElement, getDiagramSurface, getDrawComparator, getDynamicConfigurations, getDynamicStyleOwner, getElementsForLinkConnecting, getElementToConnectLink, getFillColor, getFont, getFontHeight, getFontRenderContext, getHumanName, getHumanType, getLineColor, getLineWidth, getManipulatedElementAt, getManipulatedIntersectionWith, getManipulatedIntersectionWith, getManipulatedParent, getManipulatedPresentationElements, getManipulationBounds, getNotZoomedTolerance, getObjectParent, getParent, getParentSymbolPropertyOwner, getPreferredSize, getPresentationElementAt, getPresentationElementAt, getPresentationElementCount, getPresentationElementsAt, getPresentationElementsAt, getPresentationElementStroke, getPresentationElementStroke, getProjectImpl, getProperty, getPropertyManager, getPropertyManagerName, getRealPropertyManager, getRenderer, getSelected, getStereotypeColor, getStereotypeFont, getStringPropertyValue, getStroke, getStroke, getStroke, getStroke, getStroke, getStroke, getSymbolRenderer, getTextColor, getTolerance, getVisibility, getVisiblePresentationElements, handleModelDelete, hasDiagramSurface, hasManipulatedPresentationElements, hasSharedData, initializeAndAutosize, internalCreatePropertyChangeListener, internalGetElementsForLinkConnecting, internalGetElementToConnectLink, internalSnapToGrid, internalSnapToGrid, isChildVisible, isCreateElementListener, isDetectable, isDisposed, isLayouting, isMovableByMoveManager, isNotNull, isParentOf, isParentOf, isPreserveProportionsWhenGrowing, isSelected, isShowElementTypeAsLabel, isSortable, isTestUpdateFlag, isTextEditable, isUseFillColor, isUseFillColorByProperty, isUseGradientForFill, isVisible, isVisibleInDiagram, isVisibleOrShrunken, movePathElementsRecursively, mustShowContextMenu, notifyCreated, notifyDiagramFrameSizeChange, notifyRepaintManager, onFind, onFind, onFontChange, paintAdornments, paintAdornmentsBackground, paintChildrenAndAdornments, paintSelfBackground, preDisposeOnUpdate, prepareForFillDrawing, prepareForLineDrawing, prepareForTextDrawing, recreateListeners, registerInSortManager, rememberBounds, rememberBounds, removeFromSortManager, removeItSelfOnUpdate, resizeParent, sAddPresentationElement, selectChildrenForMoving, selectObjectsForMoving, setAllSelected, setBounds, setCreateElementListener, setDiagramSurface, setElement, setFont, setFontProperty, setLayouting, setLineColor, setLineWidth, setLoadedVisibility, setLocation, setLocation, setNeedRecreateListeners, setPropertyManager, setPropertyManagerName, setSelected, setSelected, setSize, setSize, setSize, setStereotypeColor, setStereotypeFont, setStrokeIfNotTheSame, setTestUpdateFlag, setTextColor, setTextColorProperty, setUseFillColor, setVisible, silentApply, silentApply, simpleSetBounds, snapToGrid, snapToGrid, snapViewToGrid, sortObjectsByX, sortObjectsByY, sSetBounds, sSetLineWidth, sSetLocation, sSetLocation, sSetParent, sSetParentForAll, sSetSize, sSetSize, sSetSize, sSetVisible, tryToDeleteModelElementUponRemoval, update, updateLabelsIgnoringSuspendableLater, updateModelByView, updateModelByViewInternal, updateViewAfterPropertyChange, useParentProperties
-
Methods inherited from class com.nomagic.magicdraw.uml.MDElementImpl
accept, addPropertyChangeListener, canAdd, canAdd, canAddChild, canBeDeleted, canDeleteChild, compareTo, createSortKeys, generateID, getClassType, getCommandForAppending, getID, getProject, getProjectProvider, getResourceID, getSortKeys, hasListeners, isEditable, removeAllChildren, removeAllParents, removeAllPropertyChangeListeners, removePropertyChangeListener, setID, setProjectProvider, sGetID
-
-
-
-
Field Detail
-
nestedPath
@CheckForNull private java.util.List<Property> nestedPath
-
nestedPathListeners
@CheckForNull private java.util.List<SmartPropertyChangeListener> nestedPathListeners
-
-
Constructor Detail
-
PartView
public PartView()
-
PartView
public PartView(@CheckForNull PresentationElement parent)
-
-
Method Detail
-
getStructureCompartment
public com.nomagic.magicdraw.uml.symbols.shapes.StructureCompartmentView getStructureCompartment()
-
getClassifier
public Classifier getClassifier()
- Specified by:
getClassifierin classcom.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
-
sSetClassifiers
public void sSetClassifiers(java.util.List<Classifier> type)
- Specified by:
sSetClassifiersin classcom.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
-
getMetaClassifiersQPropertyName
public java.lang.String getMetaClassifiersQPropertyName()
- Specified by:
getMetaClassifiersQPropertyNamein classcom.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
-
internalGetHeaderInsets
protected com.nomagic.ui.UnmodifiableInsets internalGetHeaderInsets()
- Overrides:
internalGetHeaderInsetsin classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
getElement
public Property getElement()
Description copied from class:PresentationElementReturns model element of this presentation element. Some presentation elements (for example TextBoxes) do not have model elements.- Specified by:
getElementin interfaceModelElementProvider- Overrides:
getElementin classPresentationElement- Returns:
- model element of this presentation element.
-
getProperty
@Deprecated public Property getProperty()
Deprecated.use #getElement
-
accept
public void accept(Visitor o) throws java.lang.Exception
Description copied from interface:MDElementMethod accepts visitor, and calls method visit<class name>(this) of visitor . See Visitor pattern for more details.
-
createSmartListenerConfig
protected void createSmartListenerConfig(java.util.List<SmartListenerConfig> configurations)
- Overrides:
createSmartListenerConfigin classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
isShowRakeIcon
public boolean isShowRakeIcon()
- Overrides:
isShowRakeIconin classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
internalGetPresentationElementStroke
public java.awt.BasicStroke internalGetPresentationElementStroke(int width)
Description copied from class:PresentationElementReturn a stroke used to paint symbol's main part- Parameters:
width- a custom stroke width. Other stroke parameters will be specific to symbol- Returns:
- a stroke used to paint symbol's main part
-
findParentForData
@CheckForNull public Element findParentForData(PresentationElement newParent, com.nomagic.uml2.ext.jmi.helpers.ElementAddContext addContext)
-
getElementToMove
public Element getElementToMove()
Description copied from class:PresentationElementReturns element that should be used for during "move" operation. In most cases this is the same as getElement(), but some symbols maybe override and return some other related element.- Returns:
- element to move
- See Also:
PresentationElement.getElement()
-
getCompartmentElementID
public java.lang.String getCompartmentElementID()
- Specified by:
getCompartmentElementIDin interfaceCompartmentElement
-
getCompartmentText
public java.lang.String getCompartmentText()
- Specified by:
getCompartmentTextin interfaceCompartmentElement
-
internalSpecificUpdate
protected void internalSpecificUpdate()
- Overrides:
internalSpecificUpdatein classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
isInheritedPart
private boolean isInheritedPart()
-
isNestedPartValid
private boolean isNestedPartValid(PresentationElement parent)
-
containsProperty
private static boolean containsProperty(Classifier classifier, Property property)
-
fixNestedPath
private void fixNestedPath()
Fix nested path if possible. After structure change in the model sometimes we can remove nested path and do not remove part itself. In such case nested path is set to null. Usually such situation happens if part with nested path is moved to other structure.
-
getProxyElementFromParentSymbol
@CheckForNull private static Element getProxyElementFromParentSymbol(PresentationElement parent)
-
isValid
public boolean isValid(PresentationElement parent, boolean changeElementParent)
Checks if part is valid by symbol ownership in it's current context.- Parameters:
parent- the owner of partchangeElementParent- check if valid for a move operation- Returns:
- true if part ownership is valid
-
getElementFromParentSymbol
@CheckForNull public Element getElementFromParentSymbol()
-
getElementFromParentSymbol
@CheckForNull public Element getElementFromParentSymbol(PresentationElement parent)
-
isDrawSeparator
protected boolean isDrawSeparator()
- Overrides:
isDrawSeparatorin classcom.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
-
getTaggedValuesDisplayMode
public java.lang.String getTaggedValuesDisplayMode()
-
sSetTaggedValuesDisplayMode
public void sSetTaggedValuesDisplayMode(java.lang.String mode)
-
setTaggedValuesDisplayMode
public void setTaggedValuesDisplayMode(java.lang.String mode)
-
getShowSlotTypeMode
public java.lang.String getShowSlotTypeMode()
Gets value of slot showing property. Default is NONE- Returns:
- mode
- See Also:
SlotView.SHOW_TYPE_MODE_NONE,SlotView.SHOW_TYPE_MODE_NAME,SlotView.SHOW_TYPE_MODE_QUALIFIED_NAME
-
sSetShowSlotTypeMode
public void sSetShowSlotTypeMode(java.lang.String mode)
Sets value of slot showing property. Just changes property, but no update is done- Parameters:
mode- mode- See Also:
SlotView.SHOW_TYPE_MODE_NONE,SlotView.SHOW_TYPE_MODE_NAME,SlotView.SHOW_TYPE_MODE_QUALIFIED_NAME
-
setShowSlotTypeMode
public void setShowSlotTypeMode(java.lang.String mode)
Sets value of slot showing property. Calls view update- Parameters:
mode- mode- See Also:
SlotView.SHOW_TYPE_MODE_NONE,SlotView.SHOW_TYPE_MODE_NAME,SlotView.SHOW_TYPE_MODE_QUALIFIED_NAME
-
isShowInheritedSign
public boolean isShowInheritedSign()
- Returns:
- true if inherited sign is shown
-
sSetShowInheritedSign
public void sSetShowInheritedSign(boolean showInheritedSign)
Show inherited sign- Parameters:
showInheritedSign- show
-
setShowInheritedSign
public void setShowInheritedSign(boolean showInheritedSign)
Show inherited members sign in compartment- Parameters:
showInheritedSign- show
-
isShowMultiplicity
public boolean isShowMultiplicity()
-
setShowMultiplicity
public void setShowMultiplicity(boolean showMultiplicity)
-
sSetShowMultiplicity
public void sSetShowMultiplicity(boolean showMultiplicity)
-
isShowDefaultValueCompartmentName
public boolean isShowDefaultValueCompartmentName()
Indicates if default value compartment name should be displayed.- Returns:
- true if default value compartment name should be displayed, false otherwise.
-
sSetShowDefaultValueCompartmentName
public void sSetShowDefaultValueCompartmentName(boolean show)
Simple sets show default value compartment name flag value.- Parameters:
show- value to set.
-
setShowDefaultValueCompartmentName
public void setShowDefaultValueCompartmentName(boolean show)
Sets show default value compartment name flag value.- Parameters:
show- value to set.
-
internalApplyProperties
public void internalApplyProperties(PropertyManager propertyManager)
Description copied from class:PresentationElementApplies properties from given property manager- Overrides:
internalApplyPropertiesin classcom.nomagic.magicdraw.uml.symbols.shapes.TypedElementView- Parameters:
propertyManager- new properties
-
internalSilentApply
public void internalSilentApply()
Description copied from class:PresentationElementSilently applies all properties after initialization- Overrides:
internalSilentApplyin classcom.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
-
setSuppressStructureCompartment
public void setSuppressStructureCompartment(boolean b)
-
sSetSuppressStructureCompartment
public void sSetSuppressStructureCompartment(boolean b)
-
isSuppressStructureCompartment
public boolean isSuppressStructureCompartment()
-
isShowTaggedValuesStereotypes
public boolean isShowTaggedValuesStereotypes()
-
sSetShowTaggedValuesStereotypes
public void sSetShowTaggedValuesStereotypes(boolean show)
-
setShowTaggedValuesStereotypes
public void setShowTaggedValuesStereotypes(boolean show)
-
isShowQualifiedNameInTaggedValues
public boolean isShowQualifiedNameInTaggedValues()
-
sSetShowQualifiedNameInTaggedValues
public void sSetShowQualifiedNameInTaggedValues(boolean show)
-
setShowQualifiedNameInTaggedValues
public void setShowQualifiedNameInTaggedValues(boolean show)
-
isShowDefaultValue
public boolean isShowDefaultValue()
Returns show default value flag. Default value can be shown in separate compartment if it is InstanceValue or after = sign in signature.- Returns:
- flag value
-
sSetShowDefaultValue
public void sSetShowDefaultValue(boolean show)
Set show default value flag. Default value can be shown in separate compartment if it is InstanceValue or after = sign in signature.- Parameters:
show- new value
-
setShowDefaultValue
public void setShowDefaultValue(boolean show)
Set show default value flag. Default value can be shown in separate compartment if it is InstanceValue or after = sign in signature.- Parameters:
show- new value
-
isInOtherPart
public boolean isInOtherPart()
-
getNestedPath
@CheckForNull public java.util.List<Property> getNestedPath()
-
setNestedPath
public void setNestedPath(@CheckForNull java.util.List<Property> nestedPath)
-
sSetNestedPath
public void sSetNestedPath(@CheckForNull java.util.List<Property> nestedPart, boolean disposeOldListeners)
-
propertyChange
public void propertyChange(java.beans.PropertyChangeEvent e)
Description copied from class:PresentationElementListens for property change it can be: data was edited text box was edited- Specified by:
propertyChangein interfacejava.beans.PropertyChangeListener- Overrides:
propertyChangein classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
clone
public PartView clone()
Description copied from class:ElementImplReturns a copy of theElement.- Specified by:
clonein interfaceBaseElement- Overrides:
clonein classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView- Returns:
- the cloned object
-
canAddInstance
public boolean canAddInstance(PresentationElement obj)
Description copied from class:PresentationElementObject view has no children.- Overrides:
canAddInstancein classcom.nomagic.magicdraw.uml.symbols.shapes.AbstractHeaderShapeView
-
canAddChild
public boolean canAddChild(PresentationElement obj)
Description copied from class:PresentationElementCheck of given symbol can be added as child into this symbol.- Overrides:
canAddChildin classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView- Parameters:
obj- symbol- Returns:
- true if symbol can be added
-
addThisIntoStructureCompartment
private boolean addThisIntoStructureCompartment(PresentationElement obj)
-
addPresentationElement
public void addPresentationElement(PresentationElement element, int index, boolean resize)
- Overrides:
addPresentationElementin classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
sAddPresentationElement
public void sAddPresentationElement(PresentationElement element, int index)
Description copied from class:PresentationElementAdd given child to this symbol at given index- Overrides:
sAddPresentationElementin classcom.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView- Parameters:
element- child to addindex- index to add at. Can be -1
-
removePresentationElement
public void removePresentationElement(PresentationElement element, boolean resizeParent)
- Overrides:
removePresentationElementin classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
sRemovePresentationElement
public void sRemovePresentationElement(PresentationElement element)
Description copied from class:PresentationElementRemoves given child- Overrides:
sRemovePresentationElementin classcom.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView- Parameters:
element- child
-
getEncapsulatedClassifier
public EncapsulatedClassifier getEncapsulatedClassifier()
- Specified by:
getEncapsulatedClassifierin interfacecom.nomagic.magicdraw.uml.symbols.shapes.PortOwner
-
getEncapsulatedClassifierProvider
public TypedElement getEncapsulatedClassifierProvider()
- Specified by:
getEncapsulatedClassifierProviderin interfacecom.nomagic.magicdraw.uml.symbols.shapes.PortOwner
-
setDummyResizeMode
public boolean setDummyResizeMode(boolean b)
Description copied from class:PresentationElementIn dummy resize mode symbol may not resize according it children or move children on bounds changed and etc. This is more as hack for resize problems during load or diagram layout- Overrides:
setDummyResizeModein classcom.nomagic.magicdraw.uml.symbols.shapes.ContainerShapeView- Parameters:
b- new value
-
preferredSizeIgnoringOrientation
protected void preferredSizeIgnoringOrientation(java.awt.Dimension pref, int locationX, int locationY)- Overrides:
preferredSizeIgnoringOrientationin classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
internalLayoutChildren
public void internalLayoutChildren(boolean calculatePrefSize)
- Overrides:
internalLayoutChildrenin classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
canChangeParent
public boolean canChangeParent(java.util.Collection<? extends PresentationElement> movedTogether, @CheckForNull BaseElement newParent, boolean changeElementParent)
Description copied from class:PresentationElementReturns true, if element can change parent.- Parameters:
movedTogether- collection of the elements, whose will change the parent together with this.newParent- new symbol parentchangeElementParent- change element parent- Returns:
- true if parent of symbol can be changed
-
getExpectedDataParent
@CheckForNull public Element getExpectedDataParent(PresentationElement child)
Description copied from class:PresentationElementReturns expected element parent. Some views "SimpleActivityRegionView" has no element but it should accept drag and drop of other presentation element- Returns:
- Most suitable element parent for given child element
-
createChangedCompartmentVisibilityProperty
public Property createChangedCompartmentVisibilityProperty(com.nomagic.magicdraw.uml.symbols.shapes.Compartment compartment, boolean showCompartment)
- Specified by:
createChangedCompartmentVisibilityPropertyin interfacecom.nomagic.magicdraw.uml.symbols.CompartmentOwner- Overrides:
createChangedCompartmentVisibilityPropertyin classcom.nomagic.magicdraw.uml.symbols.shapes.HeaderShapeView
-
findPresentationElement
@CheckForNull public static PresentationElement findPresentationElement(java.util.List<PresentationElement> elements, Element element, @CheckForNull java.util.List<Property> nestedPath)
Finds existing symbol among the given ones with a given Element and given nestedPath- Parameters:
elements- symbolselement- elementnestedPath- nested path of the Part- Returns:
- found presentation element or null
-
setParent
public void setParent(PresentationElement parent)
Description copied from class:PresentationElementSets parent for this view. For adding symbols to other symbols usePresentationElement.addPresentationElement(PresentationElement)orPresentationElement.sAddPresentationElement(PresentationElement)}- Parameters:
parent- parent view
-
getOnEdgePosition
public int getOnEdgePosition()
Description copied from class:ShapeElementReturns position on edge.- Returns:
- position on edge.
- See Also:
ShapeElement.ON_EDGE_POSITION,ShapeElement.INSIDE_EDGE_POSITION,ShapeElement.OUTSIDE_EDGE_POSITION
-
isPartPort
public boolean isPartPort()
- Returns:
- true if PartView represents Port.
-
isPart
public static boolean isPart(@CheckForNull PresentationElement obj)- Parameters:
obj- symbol- Returns:
- true if given symbol is pure Part, does not represent Port
-
isPartPort
public static boolean isPartPort(PresentationElement obj)
- Parameters:
obj- symbol- Returns:
- true if given symbol is Part, but it represents Port
-
getHeaderInsetReduce
protected int getHeaderInsetReduce(int edge, com.nomagic.magicdraw.uml.symbols.shapes.ShapeElement.OnEdgeBounds bounds)
-
getHeaderView
public com.nomagic.magicdraw.uml.symbols.shapes.PartHeaderView getHeaderView()
- Overrides:
getHeaderViewin classcom.nomagic.magicdraw.uml.symbols.shapes.TypedElementView
-
-