Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.cybertivity.powerjournal.framework
Class ActionFactory  view ActionFactory download ActionFactory.java

java.lang.Object
  extended bycom.cybertivity.powerjournal.framework.ActionFactory

public class ActionFactory
extends java.lang.Object

Factory class to create Action instances.


Nested Class Summary
private  class ActionFactory.CancelAction
          DefaultAction for a "Cancel" button.
private  class ActionFactory.ClearAction
          DefaultAction for a "Clear" button or toolbar button.
private  class ActionFactory.CreateNewAction
          DefaultAction for a "Create New" button.
 class ActionFactory.DefaultAction
          AbstractAction extension which adds the ability to construct a JMenuItem or toolbar button with appropriate text, image etc.
private  class ActionFactory.DismissAction
          DefaultAction for a "Dismiss" button.
private  class ActionFactory.OkAction
          DefaultAction for an "Ok" button.
 class ActionFactory.ToggleAction
          A bi-state extension of ToggleAction.
 
Field Summary
protected  java.lang.String imagePath
           
 
Constructor Summary
ActionFactory(java.lang.String path)
          Construct an ActionFactory which will look for button images in the specified path.
 
Method Summary
 ActionFactory.DefaultAction createAction(java.lang.String command)
          Create and return a DefaultAction for the given command.
 ActionFactory.ToggleAction createToggleAction(java.lang.String command)
           
protected  javax.swing.ImageIcon getIcon(java.lang.String fileName)
          Get an ImageIcon from the given file name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

imagePath

protected java.lang.String imagePath
Constructor Detail

ActionFactory

public ActionFactory(java.lang.String path)
Construct an ActionFactory which will look for button images in the specified path.

Method Detail

createAction

public ActionFactory.DefaultAction createAction(java.lang.String command)
Create and return a DefaultAction for the given command.


createToggleAction

public ActionFactory.ToggleAction createToggleAction(java.lang.String command)

getIcon

protected javax.swing.ImageIcon getIcon(java.lang.String fileName)
Get an ImageIcon from the given file name.