org.argouml.uml.diagram.ui
Class FigEnumLiteralsCompartment

java.lang.Object
  extended by FigGroup
      extended by org.argouml.uml.diagram.ui.ArgoFigGroup
          extended by org.argouml.uml.diagram.ui.FigCompartment
              extended by org.argouml.uml.diagram.ui.FigEnumLiteralsCompartment
All Implemented Interfaces:
ArgoFig

public class FigEnumLiteralsCompartment
extends FigCompartment

The Fig for the compartment of an Enumeration that shows a list of enumeration literals.


Field Summary
 
Fields inherited from interface org.argouml.uml.diagram.ui.ArgoFig
DEBUG, DEBUG_COLOR, FILL_COLOR, INVISIBLE_LINE_COLOR, LINE_COLOR, LINE_WIDTH, ROWHEIGHT, SOLID_FILL_COLOR, STEREOHEIGHT, TEXT_COLOR, X0, Y0
 
Constructor Summary
FigEnumLiteralsCompartment(java.lang.Object owner, java.awt.Rectangle bounds, DiagramSettings settings)
          Constructor.
 
Method Summary
protected  FigSingleLineTextWithNotation createFigText(java.lang.Object owner, java.awt.Rectangle bounds, DiagramSettings settings)
           
protected  void createModelElement()
          Create a new model element for the compartment.
 java.lang.Object getCompartmentType()
          Returns the meta type for Enumeration-Literal to indicate the type of model element within this compartment.
 java.lang.String getName()
          This operation shall return a name unique for this type of compartment.
protected  int getNotationType()
           
protected  java.util.Collection getUmlCollection()
           
 
Methods inherited from class org.argouml.uml.diagram.ui.FigCompartment
addFig, createFigText, createFigText, getBigPort, getFilled, getMinimumSize, getSeparatorFig, isFilled, populate, setBoundsImpl, setExternalSeparatorFigBounds, setFillColor, setFilled, setLineColor, setLineWidth, setVisible, updateFigGroupSize
 
Methods inherited from class org.argouml.uml.diagram.ui.ArgoFigGroup
getProject, getSettings, renderingChanged, setOwner, setProject, setSettings
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FigEnumLiteralsCompartment

public FigEnumLiteralsCompartment(java.lang.Object owner,
                                  java.awt.Rectangle bounds,
                                  DiagramSettings settings)
Constructor.

Parameters:
owner - owning UML element
bounds - bounding rectangle
settings - render settings
Method Detail

getUmlCollection

protected java.util.Collection getUmlCollection()
Specified by:
getUmlCollection in class FigCompartment
Returns:
the collection of UML objects on which this compartment is based

getNotationType

protected int getNotationType()
Specified by:
getNotationType in class FigCompartment
Returns:
the type of the notationProvider used to handle the text in the compartment

createModelElement

protected void createModelElement()
Description copied from class: FigCompartment
Create a new model element for the compartment.

Specified by:
createModelElement in class FigCompartment
See Also:
FigCompartment.createModelElement()

createFigText

protected FigSingleLineTextWithNotation createFigText(java.lang.Object owner,
                                                      java.awt.Rectangle bounds,
                                                      DiagramSettings settings)
Parameters:
owner - owning UML element
bounds - position and size
settings - the render settings
Returns:
a FigSingleLineText with notation provider which can be used to display the text

getName

public java.lang.String getName()
Description copied from class: FigCompartment
This operation shall return a name unique for this type of compartment. Potential use: show at the top in the compartment as described in the UML, or as an identification string for the compartment type.

See UML 1.4.2 OMG, chapter 5.24.1.2: Compartment name.

Specified by:
getName in class FigCompartment
Returns:
the name of the compartment

getCompartmentType

public java.lang.Object getCompartmentType()
Returns the meta type for Enumeration-Literal to indicate the type of model element within this compartment.

Specified by:
getCompartmentType in class FigCompartment
Returns:
a model element type


ArgoUML © 1996-2006ArgoUML HomepageArgoUML Developers' pageArgoUML Cookbook