|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.AbstractAction
edu.stanford.smi.protegex.owl.ui.resourceselection.ResourceSelectionAction
An Action that requires the selection of an RDFResource from a List. This Action generalizes this behavior and separates selection from action, so that the selection can be made either through a conventional resource picking dialog or through a ResourceSelectionComboBox.
Nested Class Summary |
Nested classes inherited from class javax.swing.AbstractAction |
|
Field Summary | |
static boolean |
activated
A ugly global flag that can be used to deactivate the right-click popup when working with huge ontologies (such as in database backend) for performance reasons. |
private boolean |
multipleSelection
|
private boolean |
showHiddenResources
|
Fields inherited from class javax.swing.AbstractAction |
changeSupport, enabled |
Fields inherited from interface javax.swing.Action |
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, SMALL_ICON |
Constructor Summary | |
ResourceSelectionAction(String name,
Icon icon)
Constructs a new ResourceSelectionAction. |
|
ResourceSelectionAction(String name,
Icon icon,
boolean multipleSelection)
Constructs a new ResourceSelectionAction. |
Method Summary | |
void |
actionPerformed(ActionEvent e)
Shows the frame picker dialog from pickFrame and then calls
resourceSelected on the selected Frame. |
void |
activateComboBox(JButton button)
Activates the right mouse click on a given JButton. |
ListCellRenderer |
getRenderer()
|
abstract Collection |
getSelectableResources()
|
boolean |
getShowHiddenResources()
|
RDFResource |
pickResource()
This method is used when single selection is allowed for this Action. |
Collection |
pickResources()
This method is only used when multiple selection is allowed for this Action. |
static void |
setActivated(boolean value)
|
void |
setShowHiddenResources(boolean value)
|
Methods inherited from class javax.swing.AbstractAction |
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface edu.stanford.smi.protegex.owl.ui.resourceselection.ResourceSelectionListener |
resourceSelected |
Field Detail |
public static boolean activated
private boolean multipleSelection
private boolean showHiddenResources
Constructor Detail |
public ResourceSelectionAction(String name, Icon icon)
name
- the name of the Actionicon
- the Iconpublic ResourceSelectionAction(String name, Icon icon, boolean multipleSelection)
name
- the name of the Actionicon
- the IconmultipleSelection
- true to allow multiple selection of FramesMethod Detail |
public void actionPerformed(ActionEvent e)
pickFrame
and then calls
resourceSelected
on the selected Frame.
actionPerformed
in interface ActionListener
e
- ignoredpublic void activateComboBox(JButton button)
button
- public ListCellRenderer getRenderer()
public abstract Collection getSelectableResources()
public boolean getShowHiddenResources()
public RDFResource pickResource()
public Collection pickResources()
pickFrame
.
public static void setActivated(boolean value)
public void setShowHiddenResources(boolean value)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |