Constructor and Description |
---|
TypedPropertyUIScheme(DockProperties properties)
Creates a new scheme
|
Modifier and Type | Method and Description |
---|---|
void |
addListener(UISchemeListener<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> listener)
Adds a listener to this scheme.
|
protected void |
fire(UISchemeEvent<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> event)
Forwards the event
event to all registered UIListener s. |
UIBridge<Object,UIValue<Object>> |
getBridge(Path name,
UIProperties<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> properties)
Creates the
UIBridge that handles resources of type name . |
Object |
getResource(String name,
UIProperties<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> properties)
Creates the resource with name
name . |
void |
install(UIProperties<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> properties)
Informs this scheme that it is now used by
properties . |
<V,A extends V> |
link(PropertyKey<A> source,
TypedUIProperties.Type<V> destinationType,
String destinationId)
Creates a link between the key
source and the resource destinationId . |
void |
removeListener(UISchemeListener<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> listener)
Removes a listener from this scheme.
|
void |
uninstall(UIProperties<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> properties)
Informs this scheme that it is no longer used by
properties . |
<V> void |
unlink(TypedUIProperties.Type<V> destinationType,
String destinationId)
Disables the connection leading to the resource
destinationId . |
public TypedPropertyUIScheme(DockProperties properties)
properties
- the source of all the information to read, not null
public <V,A extends V> void link(PropertyKey<A> source, TypedUIProperties.Type<V> destinationType, String destinationId)
source
and the resource destinationId
. If there is an
older link to the same id, then the older link is removed first.V
- the type to read from a DockProperties
A
- the type to write into a TypedUIProperties
source
- the key for the resourcedestinationType
- the type of the resourcedestinationId
- the identifier of the resourcepublic <V> void unlink(TypedUIProperties.Type<V> destinationType, String destinationId)
destinationId
.V
- the destinationType
destinationType
- the type of the resourcedestinationId
- the identifier of the resource that should no longer be managed by this schemepublic void addListener(UISchemeListener<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> listener)
UIScheme
public void removeListener(UISchemeListener<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> listener)
UIScheme
protected void fire(UISchemeEvent<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> event)
event
to all registered UIListener
s.event
- the event to forwardpublic UIBridge<Object,UIValue<Object>> getBridge(Path name, UIProperties<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> properties)
UIScheme
UIBridge
that handles resources of type name
.public Object getResource(String name, UIProperties<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> properties)
UIScheme
name
. This method may be called often
and should complete quickly.public void install(UIProperties<Object,UIValue<Object>,UIBridge<Object,UIValue<Object>>> properties)
UIScheme
properties
.