T - the type of value being observedpublic class DecoratingObservableValue<T> extends DecoratingObservable implements IObservableValue<T>
| Constructor and Description |
|---|
DecoratingObservableValue(IObservableValue<T> decorated,
boolean disposeDecoratedOnDispose)
Constructs a DecoratingObservableValue which decorates the given
observable.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
addListener(Object listenerType,
IObservablesListener listener) |
void |
addValueChangeListener(IValueChangeListener<? super T> listener) |
protected Object |
clone() |
void |
dispose()
Disposes of this observable object, removing all listeners registered
with this object, and all listeners this object might have registered on
other objects.
|
protected void |
fireChange() |
protected void |
fireEvent(ObservableEvent event) |
protected void |
fireValueChange(ValueDiff<T> diff) |
protected void |
firstListenerAdded() |
Realm |
getRealm() |
T |
getValue()
Returns the value.
|
Object |
getValueType()
The value type of this observable value, or
null if this
observable value is untyped. |
protected void |
handleValueChange(ValueChangeEvent<? extends T> event)
Called whenever a ValueChangeEvent is received from the decorated
observable.
|
protected boolean |
hasListeners() |
protected void |
lastListenerRemoved() |
protected void |
removeListener(Object listenerType,
IObservablesListener listener) |
void |
removeValueChangeListener(IValueChangeListener<? super T> listener) |
void |
setValue(T value)
Sets the value.
|
equals, getDecorated, getterCalled, handleStaleEvent, hashCode, isStaleaddChangeListener, addDisposeListener, addStaleListener, checkRealm, fireStale, isDisposed, removeChangeListener, removeDisposeListener, removeStaleListenerfinalize, getClass, notify, notifyAll, toString, wait, wait, waitaddChangeListener, addDisposeListener, addStaleListener, getRealm, isDisposed, isStale, removeChangeListener, removeDisposeListener, removeStaleListenerpublic DecoratingObservableValue(IObservableValue<T> decorated, boolean disposeDecoratedOnDispose)
decorated - the observable value being decorateddisposeDecoratedOnDispose - public void addValueChangeListener(IValueChangeListener<? super T> listener)
addValueChangeListener in interface IObservableValue<T>public void removeValueChangeListener(IValueChangeListener<? super T> listener)
removeValueChangeListener in interface IObservableValue<T>protected void fireChange()
fireChange in class AbstractObservableprotected void firstListenerAdded()
firstListenerAdded in class DecoratingObservableprotected void lastListenerRemoved()
lastListenerRemoved in class DecoratingObservableprotected void handleValueChange(ValueChangeEvent<? extends T> event)
event - the change event received from the decorated observablepublic T getValue()
IObservableValueRealm of the
observable.getValue in interface IObservableValue<T>public void setValue(T value)
IObservableValueRealm of the observable.setValue in interface IObservableValue<T>value - the value to setpublic Object getValueType()
IObservableValuenull if this
observable value is untyped.getValueType in interface IObservableValue<T>nullpublic void dispose()
IObservabledispose in interface IObservabledispose in class DecoratingObservableprotected void addListener(Object listenerType, IObservablesListener listener)
listenerType - listener - protected void removeListener(Object listenerType, IObservablesListener listener)
listenerType - listener - protected boolean hasListeners()
protected void fireEvent(ObservableEvent event)
public Realm getRealm()
protected Object clone() throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedException
Copyright (c) 2000, 2016 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.