net.sf.doolin.gui.action.swing
Class JToolBarBuilder

java.lang.Object
  extended by net.sf.doolin.gui.action.swing.AbstractMenuBuilder
      extended by net.sf.doolin.gui.action.swing.JToolBarBuilder
All Implemented Interfaces:
MenuBuilder

public class JToolBarBuilder
extends AbstractMenuBuilder

Tool bar builder

Author:
Damien Coraboeuf

Constructor Summary
JToolBarBuilder(JToolBar toolBar)
          Constructor.
 
Method Summary
 void add(JComponent component)
          Adds a direct component in this menu
 void add(SubscriberValidator subscriberValidator, Action swingAction)
          Adds a single action to the builder
 void clear()
          Removes all entries from the underlying component
protected  void createSeparator()
          This method is called when a sub-class must create a separator.
 MenuBuilder createSubMenu(String name, String label)
          Creates a sub-menu builder from this builder
 
Methods inherited from class net.sf.doolin.gui.action.swing.AbstractMenuBuilder
addSeparator, noSeparator
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JToolBarBuilder

public JToolBarBuilder(JToolBar toolBar)
Constructor.

Parameters:
toolBar - Tool bar to build
Method Detail

createSeparator

protected void createSeparator()
Description copied from class: AbstractMenuBuilder
This method is called when a sub-class must create a separator.

Specified by:
createSeparator in class AbstractMenuBuilder

add

public void add(JComponent component)
Description copied from interface: MenuBuilder
Adds a direct component in this menu

Specified by:
add in interface MenuBuilder
Overrides:
add in class AbstractMenuBuilder
Parameters:
component - Component to add

add

public void add(SubscriberValidator subscriberValidator,
                Action swingAction)
Description copied from interface: MenuBuilder
Adds a single action to the builder

Parameters:
subscriberValidator - Validator for any subscription on the Bus *
swingAction - Action to add

createSubMenu

public MenuBuilder createSubMenu(String name,
                                 String label)
Description copied from interface: MenuBuilder
Creates a sub-menu builder from this builder

Parameters:
name - Identifier for the sub-menu
label - Label for the sub-menu
Returns:
Builder for the sub-menu

clear

public void clear()
Description copied from interface: MenuBuilder
Removes all entries from the underlying component



Copyright © 2011. All Rights Reserved.