| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
org.kaboum.KaboumOpMode
org.kaboum.KaboumGEOMETRYOpMode
public abstract class KaboumGEOMETRYOpMode
Abstract class to create or modify KaboumGeometry within the applet.
| Nested Class Summary | 
|---|
| Nested classes/interfaces inherited from class java.awt.Container | 
|---|
| java.awt.Container.AccessibleAWTContainer | 
| Nested classes/interfaces inherited from class java.awt.Component | 
|---|
| java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy | 
| Field Summary | |
|---|---|
| protected static KaboumGeometryGlobalDescriptor | activeGGDActive GGD | 
| protected static int | activePointClickedPositionActive Point clicked position within the current coordinate vector | 
| protected static KaboumGeometry | activeSimpleGeometryActive geometry (MUST NOT BE A GEOMETRY COLLECTION!) | 
| protected  int | ADD_POINT | 
| protected  java.awt.Point | currentMousePositionMouse position | 
| protected  int | dctimeDouble click time | 
| protected  int | DRAG_POINT | 
| protected  int | dragPointPositionCurrent drag point position | 
| protected  boolean | dragStatusTrue if mouse is dragged | 
| protected  boolean | firstPointDraggedTrue if the mouse dragged a point for the first time | 
| protected  java.awt.Point | freezedMousePositionLast mouse position | 
| protected  boolean | isMenuOnTrue if the validate/undo menu is on | 
| static java.lang.String | PARAM_CANCELALLOWED | 
| static java.lang.String | PARAM_DCTIME | 
| static java.lang.String | PARAM_DRAGALLOWEDCONSTANTS | 
| static java.lang.String | PARAM_HOLEALLOWED | 
| static java.lang.String | PARAM_MULTIALLOWED | 
| static java.lang.String | PARAM_PIXELPRECISION | 
| static java.lang.String | PARAM_PRECISION | 
| static java.lang.String | PARAM_SUPPRESSIONALLOWED | 
| static java.lang.String | PARAM_SUPPRESSIONWITHINCOLLECTIONALLOWED | 
| protected  Kaboum | parentReference to the parent applet | 
| protected  java.awt.event.MouseEvent | pmcCurrent mouse event | 
| protected  java.awt.PopupMenu | popPopup menu (activated by right click mouse) | 
| protected static KaboumCoordinate[] | savedCoordinatesSavec Coordinates array | 
| protected  int | SELECT_OBJECTPrivate constant | 
| protected  int | SHOW_MENU | 
| protected  int | VALIDATE_OBJECT | 
| Fields inherited from class org.kaboum.KaboumOpMode | 
|---|
| mp | 
| Fields inherited from class java.awt.Component | 
|---|
| BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT | 
| Fields inherited from interface java.awt.image.ImageObserver | 
|---|
| ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH | 
| Constructor Summary | |
|---|---|
| KaboumGEOMETRYOpMode(Kaboum parent)Constructor | |
| KaboumGEOMETRYOpMode(Kaboum parent,
                     java.lang.String id)Constructor | |
| Method Summary | |
|---|---|
|  void | actionPerformed(java.awt.event.ActionEvent e)actionPerformed event e | 
| protected abstract  void | actionPerformedAddGeometryWithinCollection(java.awt.event.ActionEvent e)Add a geometry within this collection | 
| protected  void | actionPerformedAddHoleWithinGeometry(java.awt.event.ActionEvent e)Add a hole within this geometry. | 
|  void | actionPerformedAddPoint(java.awt.event.ActionEvent e)actionPerformed event e : AddPoint | 
| protected  void | actionPerformedCancelGeometry(java.awt.event.ActionEvent e)Return an alert box that indicate that the current Geometry is cancelled | 
| protected abstract  void | actionPerformedNewObject(java.awt.event.ActionEvent e)actionPerformed event e : NewObject | 
|  void | actionPerformedPreValidateObject(java.awt.event.ActionEvent e)ActionPerformed event e : PreValidateObject | 
| protected abstract  void | actionPerformedRemoveGeometryWithinCollection(java.awt.event.ActionEvent e)Remove a geometry within this collection | 
|  void | actionPerformedRemoveObject(java.awt.event.ActionEvent e)actionPerformed event e : RemoveObject | 
|  void | actionPerformedRemovePoint(java.awt.event.ActionEvent e)actionPerformed event e : RemovePoint | 
|  void | actionPerformedTopology(java.awt.event.ActionEvent e)actionPerformed event e : Topology | 
|  void | actionPerformedUndo(java.awt.event.ActionEvent e)actionPerformed event e : Undo | 
|  void | actionPerformedValidateObject(java.awt.event.ActionEvent e)actionPerformed event e : ValidateObject | 
| protected  void | addGenericMenu()Add the generic menu | 
| protected  void | addSeparatorMenu()Add a separator menu | 
| protected  void | addTopologicalMenu()Add the topological menu | 
|  void | destroyEvent() | 
| static java.lang.String[] | getParametersList() | 
|  boolean | insertCoordinate(KaboumCoordinate internal,
                 int position) | 
| protected  boolean | intersect(int tmpPointId)Intersection procedure. | 
| abstract  boolean | isValid(KaboumGeometryGlobalDescriptor ggd) | 
|  void | mouseClicked(java.awt.event.MouseEvent evt) | 
|  void | mouseDragged(java.awt.event.MouseEvent evt) | 
|  void | mouseMoved(java.awt.event.MouseEvent evt) | 
|  void | mousePressed(java.awt.event.MouseEvent evt) | 
|  void | mouseReleased(java.awt.event.MouseEvent evt) | 
| abstract  void | paint(java.awt.Graphics g) | 
|  boolean | removeCoordinateAt(int position) | 
|  boolean | removeLastCoordinate() | 
| protected  void | reset()Reset the current active geometry | 
| protected  void | resolveMouseAddPoint(java.awt.Point mouse,
                     int action)Resolve MOUSE LEFT CLICK action : Add a point | 
| protected  void | resolveMouseDragPoint(java.awt.Point mouse,
                      int action)Resolve MOUSE DRAG BUTTON action : Drag a point | 
| protected  void | resolveMouseEvent(java.awt.Point mouse,
                  int action)Resolve Mouse Event action | 
| protected  void | resolveMouseSelectObject(java.awt.Point mouse,
                         int action)Resolve MOUSE CONTROL CLICK action : Select an object | 
| protected  void | resolveMouseShowMenu(java.awt.Point mouse,
                     int action)Resolve MOUSE RIGHT OR MIDDLE CLICK action : Show menu | 
| protected  void | resolveMouseValidateObject(java.awt.Point mouse,
                           int action)Resolve MOUSE RIGHT BUTTON action : Validate object | 
| protected  void | saveCurrentCoordinates() | 
| protected  int | selectAbsoluteCoordinatePosition(java.awt.Point mouse)Select absolute coordinate position | 
| protected  int | selectAbsoluteCoordinatePosition(java.awt.Point mouse,
                                 KaboumCoordinate[] internals)Select absolute coordinate position | 
| protected  int | selectCoordinatePosition(java.awt.Point mouse)Return the position of a point in a coordinate list corresponding to a (x,y) mouse click within a box of w * h. | 
|  void | setActiveGGD(KaboumGeometryGlobalDescriptor ggd)Set the input geometry as the activeGGD | 
| Methods inherited from class org.kaboum.KaboumOpMode | 
|---|
| mouseEntered, mouseExited | 
| Methods inherited from class java.awt.Container | 
|---|
| add, add, add, add, add, addContainerListener, addImpl, addNotify, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, paramString, preferredSize, print, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, removeNotify, setComponentZOrder, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, setLayout, transferFocusBackward, transferFocusDownCycle, update, validate, validateTree | 
| Methods inherited from class java.awt.Component | 
|---|
| action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getAccessibleContext, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setName, setPreferredSize, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusUpCycle | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
| Field Detail | 
|---|
public static final java.lang.String PARAM_DRAGALLOWED
public static final java.lang.String PARAM_SUPPRESSIONALLOWED
public static final java.lang.String PARAM_PRECISION
public static final java.lang.String PARAM_DCTIME
public static final java.lang.String PARAM_PIXELPRECISION
public static final java.lang.String PARAM_MULTIALLOWED
public static final java.lang.String PARAM_HOLEALLOWED
public static final java.lang.String PARAM_SUPPRESSIONWITHINCOLLECTIONALLOWED
public static final java.lang.String PARAM_CANCELALLOWED
protected final int SELECT_OBJECT
protected final int ADD_POINT
protected final int SHOW_MENU
protected final int DRAG_POINT
protected final int VALIDATE_OBJECT
protected Kaboum parent
protected java.awt.PopupMenu pop
protected static KaboumGeometryGlobalDescriptor activeGGD
protected static KaboumGeometry activeSimpleGeometry
protected static KaboumCoordinate[] savedCoordinates
protected static int activePointClickedPosition
protected int dragPointPosition
protected java.awt.Point freezedMousePosition
protected java.awt.Point currentMousePosition
protected java.awt.event.MouseEvent pmc
protected int dctime
protected boolean isMenuOn
protected boolean dragStatus
protected boolean firstPointDragged
| Constructor Detail | 
|---|
public KaboumGEOMETRYOpMode(Kaboum parent)
parent - Parent reference
public KaboumGEOMETRYOpMode(Kaboum parent,
                            java.lang.String id)
parent - Parent referenceid - Pre-selected object| Method Detail | 
|---|
public static java.lang.String[] getParametersList()
public void setActiveGGD(KaboumGeometryGlobalDescriptor ggd)
protected void reset()
public void destroyEvent()
destroyEvent in class KaboumOpModepublic void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed in interface java.awt.event.ActionListeneractionPerformed in class KaboumOpModee - action to perform
protected void resolveMouseEvent(java.awt.Point mouse,
                                 int action)
mouse - mouse pointaction - action to resolvepublic void actionPerformedPreValidateObject(java.awt.event.ActionEvent e)
e - action to performpublic void actionPerformedUndo(java.awt.event.ActionEvent e)
e - action to performpublic void actionPerformedAddPoint(java.awt.event.ActionEvent e)
e - action to performpublic void actionPerformedRemovePoint(java.awt.event.ActionEvent e)
e - action to performpublic void actionPerformedValidateObject(java.awt.event.ActionEvent e)
e - action to performpublic void actionPerformedRemoveObject(java.awt.event.ActionEvent e)
e - action to performpublic void actionPerformedTopology(java.awt.event.ActionEvent e)
e - action to performprotected void addGenericMenu()
protected void addTopologicalMenu()
protected void addSeparatorMenu()
public void mouseDragged(java.awt.event.MouseEvent evt)
mouseDragged in interface java.awt.event.MouseMotionListenermouseDragged in class KaboumOpModepublic void mouseClicked(java.awt.event.MouseEvent evt)
mouseClicked in interface java.awt.event.MouseListenermouseClicked in class KaboumOpModepublic void mousePressed(java.awt.event.MouseEvent evt)
mousePressed in interface java.awt.event.MouseListenermousePressed in class KaboumOpModepublic void mouseReleased(java.awt.event.MouseEvent evt)
mouseReleased in interface java.awt.event.MouseListenermouseReleased in class KaboumOpModepublic void mouseMoved(java.awt.event.MouseEvent evt)
mouseMoved in interface java.awt.event.MouseMotionListenermouseMoved in class KaboumOpModeprotected boolean intersect(int tmpPointId)
tmpPointId - Point to usetype - Type of intersectionprotected void saveCurrentCoordinates()
protected void resolveMouseValidateObject(java.awt.Point mouse,
                                          int action)
mouse - mouse positionaction - action to resolve
protected void resolveMouseSelectObject(java.awt.Point mouse,
                                        int action)
mouse - mouse positionaction - action  to resolve
protected void resolveMouseShowMenu(java.awt.Point mouse,
                                    int action)
mouse - mouse positionaction - action to resolveprotected int selectCoordinatePosition(java.awt.Point mouse)
mouse - mouse position
protected int selectAbsoluteCoordinatePosition(java.awt.Point mouse,
                                               KaboumCoordinate[] internals)
protected int selectAbsoluteCoordinatePosition(java.awt.Point mouse)
protected void resolveMouseDragPoint(java.awt.Point mouse,
                                     int action)
mouse - mouse positionaction - action to resolve
protected void resolveMouseAddPoint(java.awt.Point mouse,
                                    int action)
mouse - mouse positionaction - action to resolvepublic boolean removeLastCoordinate()
public boolean removeCoordinateAt(int position)
public boolean insertCoordinate(KaboumCoordinate internal,
                                int position)
protected void actionPerformedAddHoleWithinGeometry(java.awt.event.ActionEvent e)
protected void actionPerformedCancelGeometry(java.awt.event.ActionEvent e)
protected abstract void actionPerformedAddGeometryWithinCollection(java.awt.event.ActionEvent e)
protected abstract void actionPerformedRemoveGeometryWithinCollection(java.awt.event.ActionEvent e)
protected abstract void actionPerformedNewObject(java.awt.event.ActionEvent e)
e - action to performpublic abstract boolean isValid(KaboumGeometryGlobalDescriptor ggd)
public abstract void paint(java.awt.Graphics g)
paint in class java.awt.Container| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||