Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bbn.openmap.omGraphics
Class OMAction

    java.lang.Object
      com.bbn.openmap.omGraphics.OMAction

All Implemented Interfaces:
  OMGraphicConstants

public class OMAction
extends java.lang.Object
implements OMGraphicConstants

The OMAction class provides a way to describe one or more actions that should be performed on an OMGraphic. Each digit of the internal integer represents an action, and the action masks are defined in OMGraphicsConstances. The class holds the action value, and can respond to queries to check if certain masks are set, or can also set certain masks on the internal value. There are also static methods provided as a convenience.

Field Summary
`protected int` | `value` The internal value of the action, representing 0 or more actions to be performed on a graphic, depending on the bits set.

Fields inherited from interface com.bbn.openmap.omGraphics.OMGraphicConstants
`ADD_GRAPHIC_MASK, BASIC_STROKE, CHANGE_APPEARANCE, clear, DECIMAL_DEGREES, DECLUTTERTYPE_LINE, DECLUTTERTYPE_MOVE, DECLUTTERTYPE_NONE, DECLUTTERTYPE_SPACE, DEFAULT_ROTATIONANGLE, DELETE_GRAPHIC_MASK, DESELECT_GRAPHIC_MASK, DESELECTALL_GRAPHIC_MASK, GRAPHICTYPE_ARC, GRAPHICTYPE_BITMAP, GRAPHICTYPE_CIRCLE, GRAPHICTYPE_ELLIPSE, GRAPHICTYPE_GRAPHIC, GRAPHICTYPE_GRID, GRAPHICTYPE_LINE, GRAPHICTYPE_POINT, GRAPHICTYPE_POLY, GRAPHICTYPE_RASTER, GRAPHICTYPE_RECTANGLE, GRAPHICTYPE_TEXT, INFOLINE, LABEL, LINETYPE_GREATCIRCLE, LINETYPE_RHUMB, LINETYPE_STRAIGHT, LINETYPE_UNKNOWN, LOWER_GRAPHIC_MASK, LOWER_TO_BOTTOM_GRAPHIC_MASK, RADIANS, RAISE_GRAPHIC_MASK, RAISE_TO_TOP_GRAPHIC_MASK, REMOVABLE, RENDERTYPE_LATLON, RENDERTYPE_OFFSET, RENDERTYPE_UNKNOWN, RENDERTYPE_XY, SELECT_GRAPHIC_MASK, SORT_GRAPHICS_MASK, TOOLTIP, UPDATE_GRAPHIC_MASK`

Constructor Summary
`OMAction()` Create an OMAction that represents no action (No bits are set).
`OMAction(int value)` Create an OMAction with the provided actions.

Method Summary
`int` | `getValue()`
`boolean` | `isMask(int mask)` Return whether a mask value is set in the internal value.
`static boolean` | `isMask(int value, int mask)` Check to see if a mask bit is set in an integer.
`static void` | `main(java.lang.String[] argv)`
`int` | `setMask(int mask)` Set a particular mask bit in the internal value.
`static int` | `setMask(int value, int mask)` Set a particular mask bit in the provided integer.
`void` | `setValue(int value)`
`java.lang.String` | `toString()` Provide a String that describes what the Action is all about.
`int` | `unsetMask(int mask)` Unset a particular mask bit in the internal value.
`static int` | `unsetMask(int value, int mask)` Unset a particular mask bit in the provided integer.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### value

    protected int value

  The internal value of the action, representing 0 or more actions to be performed on a graphic, depending on the bits set.

Constructor Detail

### OMAction

    public OMAction()

  Create an OMAction that represents no action (No bits are set).

### OMAction

    public OMAction(int value)

  Create an OMAction with the provided actions.

Method Detail

### setValue

    public void setValue(int value)

### getValue

    public int getValue()

### setMask

    public int setMask(int mask)

  Set a particular mask bit in the internal value.

  Parameters:
    `mask` - an OMGraphicConstant mask constant.
  Returns:
    the changed integer value.

### unsetMask

    public int unsetMask(int mask)

  Unset a particular mask bit in the internal value.

  Parameters:
    `mask` - an OMGraphicConstant mask constant.
  Returns:
    the changed integer value.

### isMask

    public boolean isMask(int mask)

  Return whether a mask value is set in the internal value.

  Parameters:
    `mask` - an OMGraphicConstant mask constant.
  Returns:
    whether the value bit is set on the internal value.

### setMask

    public static int setMask(int value,
                              int mask)

  Set a particular mask bit in the provided integer.

  Parameters:
    `value` - the integer to set the value(bit) on.
    `mask` - an OMGraphicConstant mask constant.
  Returns:
    the changed integer value.

### unsetMask

    public static int unsetMask(int value,
                                int mask)

  Unset a particular mask bit in the provided integer.

  Parameters:
    `value` - the integer to unset the value(bit) on.
    `mask` - an OMGraphicConstant mask constant.
  Returns:
    the changed integer value.

### isMask

    public static boolean isMask(int value,
                                 int mask)

  Check to see if a mask bit is set in an integer.

  Parameters:
    `value` - the integer to check for the value(bit) on.
    `mask` - an OMGraphicConstant mask constant.
  Returns:
    whether the value bit is set.

### toString

    public java.lang.String toString()

  Provide a String that describes what the Action is all about.

### main

    public static final void main(java.lang.String[] argv)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright (C) BBNT Solutions LLC; See http://openmap.bbn.com/ for details