Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse Platform
Release 3.5

org.eclipse.core.databinding.observable.value
Class DecoratingObservableValue


java.lang.Object
  extended by 

org.eclipse.core.databinding.observable.AbstractObservable
      extended by 

org.eclipse.core.databinding.observable.DecoratingObservable
          extended by 
org.eclipse.core.databinding.observable.value.DecoratingObservableValue
All Implemented Interfaces:
IDecoratingObservable, IObservable, IObservableValue
Direct Known Subclasses:
DecoratingVetoableValue

public class DecoratingObservableValue
extends DecoratingObservable
implements IObservableValue

An observable value which decorates another observable value.

Since:
1.2

Constructor Summary
DecoratingObservableValue ( IObservableValue decorated, boolean disposeDecoratedOnDispose)
          Constructs a DecoratingObservableValue which decorates the given observable.
 
Method Summary
protected  void addListener ( Object listenerType, IObservablesListener listener)
           
 void addValueChangeListener ( IValueChangeListener 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 diff)
           
protected  void firstListenerAdded ()
           
  Realm getRealm ()
           
  Object 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 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 listener)
           
 void setValue ( Object value)
          Sets the value.
 
Methods inherited from class org.eclipse.core.databinding.observable. DecoratingObservable
equals, getDecorated, getterCalled, handleStaleEvent, hashCode, isStale
 
Methods inherited from class org.eclipse.core.databinding.observable. AbstractObservable
addChangeListener, addDisposeListener, addStaleListener, checkRealm, fireStale, isDisposed, removeChangeListener, removeDisposeListener, removeStaleListener
 
Methods inherited from class java.lang. Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.core.databinding.observable. IObservable
addChangeListener, addDisposeListener, addStaleListener, getRealm, isDisposed, isStale, removeChangeListener, removeDisposeListener, removeStaleListener
 

Constructor Detail

DecoratingObservableValue

public DecoratingObservableValue(
IObservableValue decorated,
                                 boolean disposeDecoratedOnDispose)
Constructs a DecoratingObservableValue which decorates the given observable.

Parameters:
decorated - the observable value being decorated
disposeDecoratedOnDispose -
Method Detail

addValueChangeListener

public void addValueChangeListener(
IValueChangeListener listener)
Specified by:
addValueChangeListener in interface IObservableValue

removeValueChangeListener

public void removeValueChangeListener(
IValueChangeListener listener)
Specified by:
removeValueChangeListener in interface IObservableValue

fireValueChange

protected void fireValueChange(
ValueDiff diff)

fireChange

protected void fireChange()
Overrides:
fireChange in class AbstractObservable

firstListenerAdded

protected void firstListenerAdded()
Overrides:
firstListenerAdded in class DecoratingObservable

lastListenerRemoved

protected void lastListenerRemoved()
Overrides:
lastListenerRemoved in class DecoratingObservable

handleValueChange

protected void handleValueChange(
ValueChangeEvent event)
Called whenever a ValueChangeEvent is received from the decorated observable. By default, this method fires the value change event again, with the decorating observable as the event source. Subclasses may override to provide different behavior.

Parameters:
event - the change event received from the decorated observable

getValue

public 
Object getValue()
Description copied from interface: IObservableValue
Returns the value. Must be invoked in the Realm of the observable.

Specified by:
getValue in interface IObservableValue
Returns:
the current value

setValue

public void setValue(
Object value)
Description copied from interface: IObservableValue
Sets the value. Must be invoked in the Realm of the observable.

Specified by:
setValue in interface IObservableValue
Parameters:
value - the value to set

getValueType

public 
Object getValueType()
Description copied from interface: IObservableValue
The value type of this observable value, or null if this observable value is untyped.

Specified by:
getValueType in interface IObservableValue
Returns:
the value type, or null

dispose

public void dispose()
Description copied from interface: IObservable
Disposes of this observable object, removing all listeners registered with this object, and all listeners this object might have registered on other objects.

Specified by:
dispose in interface IObservable
Overrides:
dispose in class DecoratingObservable

addListener

protected void addListener(
Object listenerType,
                           
IObservablesListener listener)
Parameters:
listenerType -
listener -

removeListener

protected void removeListener(
Object listenerType,
                              
IObservablesListener listener)
Parameters:
listenerType -
listener -

hasListeners

protected boolean hasListeners()

fireEvent

protected void fireEvent(
ObservableEvent event)

getRealm

public 
Realm getRealm()
Returns:
Returns the realm.

clone

protected 
Object clone()
                throws 
CloneNotSupportedException
Overrides:
clone in class Object
Throws:
CloneNotSupportedException

Eclipse Platform
Release 3.5

Guidelines for using Eclipse APIs.

Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire