Package org.jfree.ui.action
Class ActionConcentrator
java.lang.Object
org.jfree.ui.action.ActionConcentrator
This class is used to collect actions to be enabled or disabled
by a sinle call.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdds the action to this concentrator.booleanReturns, whether all actions are disabled.voidRemoves the action from this concentrator.voidsetEnabled(boolean b) Defines the state for all actions.
-
Field Details
-
actions
The collection used to store the actions of this concentrator.
-
-
Constructor Details
-
ActionConcentrator
public ActionConcentrator()DefaultConstructor.
-
-
Method Details
-
addAction
Adds the action to this concentrator.- Parameters:
a- the action to be added.
-
removeAction
Removes the action from this concentrator.- Parameters:
a- the action to be removed.
-
setEnabled
public void setEnabled(boolean b) Defines the state for all actions.- Parameters:
b- the new state for all actions.
-
isEnabled
public boolean isEnabled()Returns, whether all actions are disabled. If one action is enabled, then this method will return true.- Returns:
- true, if at least one action is enabled, false otherwise.
-