Cytoscape 2.3.1 (c) 2004 ISB, MSKCC, UCSD

cytoscape.util
Class CytoscapeMenuBar

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byjavax.swing.JComponent
              extended byjavax.swing.JMenuBar
                  extended bycytoscape.util.CytoscapeMenuBar
All Implemented Interfaces:
Accessible, ImageObserver, MenuContainer, MenuElement, Serializable

public class CytoscapeMenuBar
extends JMenuBar

See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
 
Field Summary
static String DEFAULT_MENU_SPECIFIER
           
 
Fields inherited from class javax.swing.JComponent
TOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
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
CytoscapeMenuBar()
          Default constructor.
 
Method Summary
 boolean addAction(Action action)
          If the given Action has a present and false inMenuBar property, return; otherwise delegate to addAction( String, Action ) with the value of its preferredMenu property, or null if it does not have that property.
 boolean addAction(Action action, int index)
           
 boolean addAction(String menu_name, Action action)
           
 JMenu createJMenu(String title)
          Factory method for instantiating objects of type JMenu
 boolean equals(Object other_object)
          CytoscapeMenuBars are unique -- this equals() method returns true iff the other object == this.
 String getDefaultMenuSpecifier()
           
 String getIdentifier()
           
 JMenu getMenu(String menu_string)
           
 JMenu getMenu(String menu_string, int parentPosition)
           
 boolean isReidentificationEnabled()
           
 boolean removeAction(Action action)
          If the given Action has a present and false inMenuBar property, return; otherwise if there's a menu item for the action, remove it.
 void setDefaultMenuSpecifier(String menu_name)
           
 void setIdentifier(String new_identifier)
           
 String toString()
          Delegates to getIdentifier().
 
Methods inherited from class javax.swing.JMenuBar
add, addNotify, getAccessibleContext, getComponent, getComponentAtIndex, getComponentIndex, getHelpMenu, getMargin, getMenu, getMenuCount, getSelectionModel, getSubElements, getUI, getUIClassID, isBorderPainted, isSelected, menuSelectionChanged, processKeyEvent, processMouseEvent, removeNotify, setBorderPainted, setHelpMenu, setMargin, setSelected, setSelectionModel, setUI, updateUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paint, paintImmediately, paintImmediately, print, printAll, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, remove, remove, removeAll, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setLayout, transferFocusBackward, transferFocusDownCycle, validate
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, createImage, createImage, createVolatileImage, createVolatileImage, dispatchEvent, enable, enableInputMethods, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DEFAULT_MENU_SPECIFIER

public static final String DEFAULT_MENU_SPECIFIER
See Also:
Constant Field Values
Constructor Detail

CytoscapeMenuBar

public CytoscapeMenuBar()
Default constructor. Calls initializeCytoscapeMenuBar.

Method Detail

setDefaultMenuSpecifier

public void setDefaultMenuSpecifier(String menu_name)

getDefaultMenuSpecifier

public String getDefaultMenuSpecifier()

addAction

public boolean addAction(Action action)
If the given Action has a present and false inMenuBar property, return; otherwise delegate to addAction( String, Action ) with the value of its preferredMenu property, or null if it does not have that property.


addAction

public boolean addAction(Action action,
                         int index)

addAction

public boolean addAction(String menu_name,
                         Action action)

removeAction

public boolean removeAction(Action action)
If the given Action has a present and false inMenuBar property, return; otherwise if there's a menu item for the action, remove it. Its menu is determined my its preferredMenu property if it is present; otherwise by defaultMenuSpecifier.


getMenu

public JMenu getMenu(String menu_string)

getMenu

public JMenu getMenu(String menu_string,
                     int parentPosition)
Returns:
the menu named in the given String. The String may contain multiple menu names, separated by dots ('.'). If any contained menu name does not correspond to an existing menu, then that menu will be created as a child of the menu preceeding the most recent dot or, if there is none, then as a child of this MenuBar.

equals

public boolean equals(Object other_object)
CytoscapeMenuBars are unique -- this equals() method returns true iff the other object == this.


getIdentifier

public String getIdentifier()

setIdentifier

public void setIdentifier(String new_identifier)

isReidentificationEnabled

public boolean isReidentificationEnabled()
Returns:
true (always)

toString

public String toString()
Delegates to getIdentifier().


createJMenu

public JMenu createJMenu(String title)
Factory method for instantiating objects of type JMenu


www.cytoscape.org