bibliothek.gui.dock.themes
Class StationThemeItemValue<V>

java.lang.Object
  extended by bibliothek.gui.dock.themes.StationThemeItemValue<V>
Type Parameters:
V - the kind of value this UIValue handles
All Implemented Interfaces:
UIValue<V>
Direct Known Subclasses:
DefaultDisplayerFactoryValue, DefaultStationPaintValue, StationCombinerValue

public class StationThemeItemValue<V>
extends java.lang.Object
implements UIValue<V>

A default implementation of an UIValue that reads a item from a ThemeManager.

Author:
Benjamin Sigg

Constructor Summary
StationThemeItemValue(java.lang.String id, Path kind, TypedUIProperties.Type<V> type, DockStation station)
          Creates a new object.
 
Method Summary
 V get()
          Gets the resource that is currently used.
 V getDelegate()
          Gets the delegate of this wrapper.
 DockStation getStation()
          Gets the station that owns this UIValue.
 void set(V value)
          Called when the underlying resource of this UIValue changes.
 void setController(DockController controller)
          Allows this UIValue to register itself on controller to read the current value.
 void setDelegate(V delegate)
          Sets the delegate of this wrapper.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StationThemeItemValue

public StationThemeItemValue(java.lang.String id,
                             Path kind,
                             TypedUIProperties.Type<V> type,
                             DockStation station)
Creates a new object.

Parameters:
id - the identifier used for retrieving a resource of ThemeManager
kind - what kind of UIValue this is
type - what kind of value this UIValue handles
station - the owner of this object, not null
Method Detail

getStation

public DockStation getStation()
Gets the station that owns this UIValue.

Returns:
the owner

getDelegate

public V getDelegate()
Gets the delegate of this wrapper.

Returns:
the delegate, may be null

setController

public void setController(DockController controller)
Allows this UIValue to register itself on controller to read the current value.

Parameters:
controller - the controller to observer, can be null

setDelegate

public void setDelegate(V delegate)
Sets the delegate of this wrapper.

Parameters:
delegate - the delegate or null

set

public void set(V value)
Description copied from interface: UIValue
Called when the underlying resource of this UIValue changes.

Specified by:
set in interface UIValue<V>
Parameters:
value - the new value

get

public V get()
Gets the resource that is currently used.

Returns:
the current factory