bibliothek.gui.dock.util
Interface UIBridge<V,U extends UIValue<V>>

Type Parameters:
V - the type of resources that are transmitted to the UIValues.
U - the kind of UIValues this provider can manage
All Known Subinterfaces:
CColorBridge, ColorBridge, DockIconBridge, FontBridge, TextBridge
All Known Implementing Classes:
BasicButtonTitleTransmitter, BasicTabTransmitter, BasicTitleTransmitter, BubbleButtonTitleTransmitter, BubbleDisplayerTransmitter, BubbleTabTransmitter, BubbleTitleTransmitter, ButtonFontTransmitter, ColorTransmitter, EclipseTabTransmitter, ExtendedColorBridge, FlatTabTransmitter, FlatTitleTransmitter, FontTransmitter, ListFontTransmitter, MinimizedButtonColorTransmitter, MultiColorBridge, MultiFontBridge, MultiUIBridge, TabColorTransmitter, TabFontTransmitter, TabMenuOverflowIconBridge, TabTitleFontTransmitter, TitleColorTransmitter, TitleFontTransmitter, UITransmitter

public interface UIBridge<V,U extends UIValue<V>>

An UIBridge is a filter between the UIProperties and several UIValues. Each change of an UIValue by the UIProperties goes through an UIBridge. The bridge can modify each request of the UIProperties and change the resource that is transmitted to the UIValue. It is up to the bridge how, why and when a resource is changed. Each bridge handles only one kind (identified by a Path) of UIValue.

Author:
Benjamin Sigg

Method Summary
 void add(String id, U uiValue)
          Adds a new UIValue that gets its resource from this bridge.
 void remove(String id, U uiValue)
          Removes a value from this bridge.
 void set(String id, V value, U uiValue)
          Called by the UIProperties when one resource or UIValue has been exchanged.
 

Method Detail

add

void add(String id,
         U uiValue)
Adds a new UIValue that gets its resource from this bridge.

Parameters:
id - the id of the resource the new value needs
uiValue - a value that can be modified by this bride

remove

void remove(String id,
            U uiValue)
Removes a value from this bridge.

Parameters:
id - the id of the resource the value needed
uiValue - the value that is no longer in use

set

void set(String id,
         V value,
         U uiValue)
Called by the UIProperties when one resource or UIValue has been exchanged. Normally an UIBridge can just call UIValue.set(Object) with the argument value.
This method may also be called with an UIValue that was not added to this UIBridge.

Parameters:
id - the identifier of the resource
value - the new resource, can be null
uiValue - the value that is affected by the change