|
Eclipse Platform Release 3.6 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.core.databinding.property.value.ValueProperty
org.eclipse.core.databinding.property.value.SimpleValueProperty
org.eclipse.jface.databinding.swt.WidgetValueProperty
public abstract class WidgetValueProperty
Abstract value property implementation for Widget
properties. This
class implements some basic behavior that widget properties are generally
expected to have, namely:
observe(Object)
should create the observable on the
display realm of the widget, rather than the current default realm
observe()
methods should return an
ISWTObservableValue
untyped listener API
. Subclasses may pass one or more SWT
event type constants to the super constructor to indicate which events signal
a property change.
Constructor Summary | |
---|---|
protected |
WidgetValueProperty()
Constructs a WidgetValueProperty which does not listen for any SWT events. |
protected |
WidgetValueProperty(int changeEvent)
Constructs a WidgetValueProperty with the specified SWT event type |
protected |
WidgetValueProperty(int[] changeEvents)
Constructs a WidgetValueProperty with the specified SWT event type(s). |
|
WidgetValueProperty(int[] changeEvents,
int[] staleEvents)
Constructs a WidgetValueProperty with the specified SWT event types. |
Method Summary | |
---|---|
INativePropertyListener |
adaptListener(ISimplePropertyListener listener)
Returns a listener capable of adding or removing itself as a listener on a source object using the the source's "native" listener API. |
IObservableValue |
observe(Object source)
Returns an observable value observing this value property on the given property source. |
IObservableValue |
observe(Realm realm,
Object source)
Returns an observable value observing this value property on the given property source |
ISWTObservableValue |
observe(Widget widget)
Returns an ISWTObservableValue observing this value property on
the given widget |
ISWTObservableValue |
observeDelayed(int delay,
Widget widget)
Returns an ISWTObservableValue observing this value property on
the given widget, which delays notification of value changes until at
least delay milliseconds have elapsed since that last change
event, or until a FocusOut event is received from the widget (whichever
happens first). |
protected ISWTObservableValue |
wrapObservable(IObservableValue observable,
Widget widget)
|
Methods inherited from class org.eclipse.core.databinding.property.value.SimpleValueProperty |
---|
doGetValue, doSetValue, observeDetail, observeDetail, observeDetail |
Methods inherited from class org.eclipse.core.databinding.property.value.ValueProperty |
---|
getValue, list, map, observeDetail, set, setValue, value, valueFactory, valueFactory |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eclipse.core.databinding.property.value.IValueProperty |
---|
getValue, getValueType, list, map, observeDetail, observeDetail, observeDetail, observeDetail, set, setValue, value, valueFactory, valueFactory |
Constructor Detail |
---|
protected WidgetValueProperty()
protected WidgetValueProperty(int changeEvent)
changeEvent
- SWT event type constant of the event that signifies a property
change.protected WidgetValueProperty(int[] changeEvents)
changeEvents
- array of SWT event type constants of the events that signify a
property change.public WidgetValueProperty(int[] changeEvents, int[] staleEvents)
changeEvents
- array of SWT event type constants of the events that signify a
property change.staleEvents
- array of SWT event type constants of the events that signify a
property became stale.Method Detail |
---|
public INativePropertyListener adaptListener(ISimplePropertyListener listener)
SimpleValueProperty
This method returns null if the source object has no listener APIs for this property.
adaptListener
in class SimpleValueProperty
listener
- the property listener to receive events
public IObservableValue observe(Object source)
IValueProperty
observe
in interface IValueProperty
observe
in class ValueProperty
source
- the property source
public IObservableValue observe(Realm realm, Object source)
IValueProperty
observe
in interface IValueProperty
observe
in class SimpleValueProperty
realm
- the observable's realmsource
- the property source
protected ISWTObservableValue wrapObservable(IObservableValue observable, Widget widget)
public ISWTObservableValue observe(Widget widget)
IWidgetValueProperty
ISWTObservableValue
observing this value property on
the given widget
observe
in interface IWidgetValueProperty
widget
- the source widget
public ISWTObservableValue observeDelayed(int delay, Widget widget)
IWidgetValueProperty
ISWTObservableValue
observing this value property on
the given widget, which delays notification of value changes until at
least delay
milliseconds have elapsed since that last change
event, or until a FocusOut event is received from the widget (whichever
happens first).
This method is equivalent to
SWTObservables.observeDelayedValue(delay, observe(widget))
.
observeDelayed
in interface IWidgetValueProperty
delay
- the delay in milliseconds.widget
- the source widget
delay
milliseconds.
|
Eclipse Platform Release 3.6 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) Eclipse contributors and others 2000, 2010. All rights reserved.