org.jupe.editors.classdiagram.graphics.nodes
Class ClassFigure

java.lang.Object
  extended by org.eclipse.draw2d.Figure
      extended by org.jupe.editors.classdiagram.graphics.nodes.NodeFigure
          extended by org.jupe.editors.classdiagram.graphics.nodes.AbstractClassInterfaceFigure
              extended by org.jupe.editors.classdiagram.graphics.nodes.ClassFigure
All Implemented Interfaces:
org.eclipse.draw2d.IFigure

public class ClassFigure
extends AbstractClassInterfaceFigure

Figure that represents a uml2-class. On first place it contains a nameLabel indicating the name of the class. Optionaly it can contain a first subfigure for attributes of a class as well as a second subfigure for its methods.

Author:
Steffen Klüpfel, Michael Pradel

Nested Class Summary
 
Nested classes/interfaces inherited from class org.eclipse.draw2d.Figure
org.eclipse.draw2d.Figure.FigureIterator
 
Nested classes/interfaces inherited from interface org.eclipse.draw2d.IFigure
org.eclipse.draw2d.IFigure.NoInsets
 
Field Summary
 
Fields inherited from interface org.eclipse.draw2d.IFigure
MAX_DIMENSION, MIN_DIMENSION, NO_INSETS
 
Constructor Summary
ClassFigure(java.lang.String name)
          constructor of a new class figure; sets the name label and creates two figures containing either attributes or methods
 
Method Summary
 void setAbstract(boolean isAbstract)
          Set if this class is abstract.
 void setVisibility(java.lang.String visibilityString)
          Sets the visibility of a class or interface.
 
Methods inherited from class org.jupe.editors.classdiagram.graphics.nodes.AbstractClassInterfaceFigure
add, getName, getNameLabel, remove, setName
 
Methods inherited from class org.eclipse.draw2d.Figure
add, add, add, addAncestorListener, addCoordinateListener, addFigureListener, addFocusListener, addKeyListener, addLayoutListener, addMouseListener, addMouseMotionListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, containsPoint, containsPoint, erase, findFigureAt, findFigureAt, findFigureAt, findFigureAtExcluding, findMouseEventTargetAt, getBackgroundColor, getBorder, getBounds, getChildren, getClientArea, getClientArea, getCursor, getFont, getForegroundColor, getInsets, getLayoutManager, getLocalBackgroundColor, getLocalForegroundColor, getLocation, getMaximumSize, getMinimumSize, getMinimumSize, getParent, getPreferredSize, getPreferredSize, getSize, getToolTip, getUpdateManager, handleFocusGained, handleFocusLost, handleKeyPressed, handleKeyReleased, handleMouseDoubleClicked, handleMouseDragged, handleMouseEntered, handleMouseExited, handleMouseHover, handleMouseMoved, handleMousePressed, handleMouseReleased, hasFocus, internalGetEventDispatcher, intersects, invalidate, invalidateTree, isCoordinateSystem, isEnabled, isFocusTraversable, isMirrored, isOpaque, isRequestFocusEnabled, isShowing, isVisible, paint, removeAll, removeAncestorListener, removeCoordinateListener, removeFigureListener, removeFocusListener, removeKeyListener, removeLayoutListener, removeMouseListener, removeMouseMotionListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, revalidate, setBackgroundColor, setBorder, setBounds, setConstraint, setCursor, setEnabled, setFocusTraversable, setFont, setForegroundColor, setLayoutManager, setLocation, setMaximumSize, setMinimumSize, setOpaque, setParent, setPreferredSize, setPreferredSize, setRequestFocusEnabled, setSize, setSize, setToolTip, setValid, setVisible, translate, translateFromParent, translateToAbsolute, translateToParent, translateToRelative, validate
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClassFigure

public ClassFigure(java.lang.String name)
constructor of a new class figure; sets the name label and creates two figures containing either attributes or methods

Parameters:
name - the new name of the class
Method Detail

setAbstract

public void setAbstract(boolean isAbstract)
Set if this class is abstract. If so the font of the nameLabel is set to italic.

Parameters:
isAbstract - True to set it abstract, false otherwise.

setVisibility

public void setVisibility(java.lang.String visibilityString)
Sets the visibility of a class or interface. Adds the corresponding icon.

Parameters:
visibilityString - the visibility type : public, protected or private.
See Also:
IConstants