bibliothek.gui.dock.common.intern
Class DefaultCommonDockable

java.lang.Object
  extended by bibliothek.gui.dock.dockable.AbstractDockable
      extended by bibliothek.gui.dock.DefaultDockable
          extended by bibliothek.gui.dock.common.intern.DefaultCommonDockable
All Implemented Interfaces:
CommonDockable, DockElement, DockElementRepresentative, Dockable

public class DefaultCommonDockable
extends DefaultDockable
implements CommonDockable

A default implementation of CommonDockable, based on a DefaultDockable.

Author:
Benjamin Sigg

Constructor Summary
DefaultCommonDockable(CDockable dockable, DockActionSource close)
          Creates a new dockable
 
Method Summary
 DefaultDockActionSource getActions()
           
 DockActionSource getClose()
          Gets the DockActionSource which shows the close-action.
 CDockable getDockable()
          Gets the model of this dockable.
 DockTitle getDockTitle(DockTitleVersion version)
          Invoked to get a graphical representation of a title for this Dockable.
 CStation getStation()
          Gets the model of this dockable as station.
 
Methods inherited from class bibliothek.gui.dock.DefaultDockable
add, add, asDockStation, getComponent, getContentPane, getFactoryID, remove, setFactoryID, setLayout
 
Methods inherited from class bibliothek.gui.dock.dockable.AbstractDockable
accept, accept, addDockableListener, addDockHierarchyListener, addMouseInputListener, asDockable, bind, configureDisplayerHints, fireTitleBound, fireTitleExchanged, fireTitleExchanged, fireTitleIconChanged, fireTitleTextChanged, fireTitleTooltipChanged, fireTitleUnbound, getConfigurableDisplayerHints, getController, getDockParent, getElement, getGlobalActionOffers, getLocalActionOffers, getPopupLocation, getTitleIcon, getTitleText, getTitleToolTip, isUsedAsTitle, listBoundTitles, removeDockableListener, removeDockHierarchyListener, removeMouseInputListener, setActionOffers, setController, setDockParent, setTitleIcon, setTitleText, setTitleToolTip, unbind
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface bibliothek.gui.dock.common.intern.CommonDockable
getFactoryID
 
Methods inherited from interface bibliothek.gui.Dockable
accept, accept, addDockableListener, addDockHierarchyListener, addMouseInputListener, bind, configureDisplayerHints, getComponent, getController, getDockParent, getGlobalActionOffers, getLocalActionOffers, getTitleIcon, getTitleText, getTitleToolTip, listBoundTitles, removeDockableListener, removeDockHierarchyListener, removeMouseInputListener, setController, setDockParent, unbind
 
Methods inherited from interface bibliothek.gui.dock.DockElement
asDockable, asDockStation
 
Methods inherited from interface bibliothek.gui.dock.DockElementRepresentative
getElement, getPopupLocation, isUsedAsTitle
 

Constructor Detail

DefaultCommonDockable

public DefaultCommonDockable(CDockable dockable,
                             DockActionSource close)
Creates a new dockable

Parameters:
dockable - the model of this element
close - action source which shows the close action
Method Detail

getActions

public DefaultDockActionSource getActions()

getDockable

public CDockable getDockable()
Description copied from interface: CommonDockable
Gets the model of this dockable.

Specified by:
getDockable in interface CommonDockable
Returns:
the model

getStation

public CStation getStation()
Description copied from interface: CommonDockable
Gets the model of this dockable as station.

Specified by:
getStation in interface CommonDockable
Returns:
the model, may be null

getClose

public DockActionSource getClose()
Description copied from interface: CommonDockable
Gets the DockActionSource which shows the close-action.

Specified by:
getClose in interface CommonDockable
Returns:
the action source

getDockTitle

public DockTitle getDockTitle(DockTitleVersion version)
Description copied from interface: Dockable
Invoked to get a graphical representation of a title for this Dockable.
There are several requirements to the title and the caller:

Specified by:
getDockTitle in interface Dockable
Overrides:
getDockTitle in class AbstractDockable
Parameters:
version - which title is required. If this Dockable does not have a special rule for the given version, it can return the result of DockTitleVersion.createDockable(Dockable).
Returns:
The title, can be null if no title should be shown. Note that not all clients can handle a null-title, if in doubt, return a title.