net.infonode.docking.action
Class DockingWindowAction

java.lang.Object
  extended by net.infonode.docking.action.DockingWindowAction
All Implemented Interfaces:
java.io.Serializable, IconProvider
Direct Known Subclasses:
CloseOthersWindowAction, CloseWindowAction, CloseWithAbortWindowAction, DockWindowAction, DockWithAbortWindowAction, MaximizeWindowAction, MaximizeWithAbortWindowAction, MinimizeWithAbortWindowAction, NullWindowAction, RestoreFocusWindowAction, RestoreParentWindowAction, RestoreParentWithAbortWindowAction, RestoreViewWithAbortTitleBarAction, RestoreWithAbortWindowAction, StateDependentWindowAction, UndockWindowAction, UndockWithAbortWindowAction

public abstract class DockingWindowAction
extends java.lang.Object
implements java.io.Serializable, IconProvider

An action that can be performed on a DockingWindow. It has a name and an optional icon.

Since:
IDW 1.3.0
Version:
$Revision: 1.4 $
Author:
$Author: jesper $
See Also:
Serialized Form

Field Summary
private static long serialVersionUID
           
 
Constructor Summary
DockingWindowAction()
           
 
Method Summary
 SimpleAction getAction(DockingWindow window)
          Creates a simple action that performs this action on a window.
 javax.swing.Icon getIcon()
          Returns the optional icon of this action.
abstract  java.lang.String getName()
          Returns the name of this action.
abstract  boolean isPerformable(DockingWindow window)
          Returns true if this action is performable on a window.
abstract  void perform(DockingWindow window)
          Performs this action on a window.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values
Constructor Detail

DockingWindowAction

public DockingWindowAction()
Method Detail

getName

public abstract java.lang.String getName()
Returns the name of this action.

Returns:
the name of this action

perform

public abstract void perform(DockingWindow window)
Performs this action on a window.

Parameters:
window - the window on which to perform the action

isPerformable

public abstract boolean isPerformable(DockingWindow window)
Returns true if this action is performable on a window.

Parameters:
window - the window on which the action will be performed
Returns:
true if this action is performable on the window

getAction

public SimpleAction getAction(DockingWindow window)
Creates a simple action that performs this action on a window.

Parameters:
window - the window on which to perform the action
Returns:
the action that performs this action on a window.

getIcon

public javax.swing.Icon getIcon()
Returns the optional icon of this action.

Specified by:
getIcon in interface IconProvider
Returns:
the optional icon of this action, null if there is no icon

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object