|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectbibliothek.gui.dock.util.UIProperties<V,U,B>
V - The kind of values this map containsU - The kind of observers used to read values from this mapB - The kind of bridges used to transfer values V to observers U@Todo(compatibility=BREAK_MINOR,
priority=MAJOR,
target=VERSION_1_1_0,
description="Use typesafe keys instead of Path")
public class UIProperties<V,U extends UIValue<V>,B extends UIBridge<V,U>>A map containing which contains some string-values pairs and so called bridges to modify these values when reading them out.
| Constructor Summary | |
|---|---|
UIProperties(DockController controller)
Creates a new map. |
|
| Method Summary | |
|---|---|
void |
add(String id,
Path path,
U value)
Installs a new UIValue. |
void |
clear(Priority priority)
Removes all values that stored under the given priority. |
V |
get(String id)
Gets a resource. |
protected B |
getBridgeFor(Path path)
Searches a bridge that can be used for path. |
DockController |
getController()
Gets the controller in whose realm this map is used. |
void |
lockUpdate()
Tells this manager to stall all updates. |
void |
publish(Priority priority,
Path path,
B bridge)
Adds a new bridge between this UIProperties and a set of
UIValues that have a certain type. |
void |
put(Priority priority,
String id,
V resource)
Sets a new resource and informs all UIValue that are observing
id about the change. |
void |
remove(U value)
Uninstalls an observer of a resource |
void |
unlockUpdate()
Tells this manager no longer to stall updates. |
void |
unpublish(Priority priority,
B bridge)
Searches for all occurrences of bridge and removes them. |
void |
unpublish(Priority priority,
Path path)
Removes the bridge that handles the UIValues of kind path. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public UIProperties(DockController controller)
controller - the owner of this map| Method Detail |
|---|
public DockController getController()
nullpublic void lockUpdate()
UIValue will
be informed when a color or provider changes.
public void unlockUpdate()
UIValues.
public void publish(Priority priority,
Path path,
B bridge)
UIProperties and a set of
UIValues that have a certain type.
priority - the importance of the new providerpath - the path for which this bridge should be used.bridge - the new bridge
public void unpublish(Priority priority,
Path path)
UIValues of kind path.
priority - the importance of the bridgepath - the path of the bridge
public void unpublish(Priority priority,
B bridge)
bridge and removes them.
All UIValues that used bridge are redistributed.
priority - the importance of the bridgebridge - the bridge to remove
public void add(String id,
Path path,
U value)
UIValue. The value will be informed about
any change in the resource id.
id - the id of the resource that value will monitorpath - the kind of the valuevalue - the new valuepublic void remove(U value)
value - the observer to removeprotected B getBridgeFor(Path path)
path.
path - the kind of bridge that is searched. First a bridge for
path will be searched, then for the parent of path,
and so on...
null
public void put(Priority priority,
String id,
V resource)
UIValue that are observing
id about the change.
priority - the importance of this valueid - the id of the colorresource - the new resourcepublic V get(String id)
id - the id of the resource
nullput(Priority, String, Object)public void clear(Priority priority)
priority - the priority whose elements should be removed
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||