public class ToolBarFactory extends ResourceManager
ToolBar = Item1 Item2 - Item3 ... See ButtonFactory.java for details about the items ... '-' represents a separatorAll entries are optional.
bundle
Constructor and Description |
---|
ToolBarFactory(ResourceBundle rb,
ActionMap am)
Creates a new tool bar factory
|
Modifier and Type | Method and Description |
---|---|
JButton |
createJButton(String name)
Creates and returns a new swing button
|
JToolBar |
createJToolBar(String name)
Creates a tool bar
|
getBoolean, getCharacter, getInteger, getString, getStringList, getStringList, getStringList
public ToolBarFactory(ResourceBundle rb, ActionMap am)
rb
- the resource bundle that contains the menu bar
description.am
- the actions to add to menu itemspublic JToolBar createJToolBar(String name) throws MissingResourceException, ResourceFormatException, MissingListenerException
name
- the name of the menu bar in the resource bundleMissingResourceException
- if one of the keys that compose the
tool bar is missing.
It is not thrown if the action key is missing.ResourceFormatException
- if a boolean is malformedMissingListenerException
- if an item action is not found in the
action map.public JButton createJButton(String name) throws MissingResourceException, ResourceFormatException, MissingListenerException
name
- the name of the button in the resource bundleMissingResourceException
- if key is not the name of a button.
It is not thrown if the mnemonic and the action keys are missingResourceFormatException
- if the mnemonic is not a single
characterMissingListenerException
- if the button action is not found in
the action map.Copyright © 2000–2023 Apache Software Foundation. All rights reserved.