|
Eclipse Platform Kepler (4.3) |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.AbstractMap
org.eclipse.core.databinding.observable.map.AbstractObservableMap
org.eclipse.core.databinding.observable.map.ComputedObservableMap
public abstract class ComputedObservableMap
Maps objects to one of their attributes. Tracks changes to the underlying observable set of objects (keys), as well as changes to attribute values.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.util.AbstractMap |
---|
java.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V> |
Nested classes/interfaces inherited from interface java.util.Map |
---|
java.util.Map.Entry<K,V> |
Constructor Summary | |
---|---|
ComputedObservableMap(IObservableSet keySet)
|
|
ComputedObservableMap(IObservableSet keySet,
java.lang.Object valueType)
|
Method Summary | |
---|---|
boolean |
containsKey(java.lang.Object key)
|
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 abstract java.lang.Object |
doGet(java.lang.Object key)
|
protected abstract java.lang.Object |
doPut(java.lang.Object key,
java.lang.Object value)
|
java.util.Set |
entrySet()
|
protected void |
fireSingleChange(java.lang.Object key,
java.lang.Object oldValue,
java.lang.Object newValue)
|
protected void |
firstListenerAdded()
|
java.lang.Object |
get(java.lang.Object key)
|
java.lang.Object |
getKeyType()
Returns the element type for the keyset of this
observable map, or null if the keyset is untyped. |
java.lang.Object |
getValueType()
Returns the element type for the values of this
observable map, or null if the values collection is untyped. |
protected abstract void |
hookListener(java.lang.Object addedKey)
|
protected void |
init()
Deprecated. Subclasses are no longer required to call this method. |
boolean |
isStale()
Returns whether the state of this observable is stale and is expected to change soon. |
java.util.Set |
keySet()
|
protected void |
lastListenerRemoved()
|
java.lang.Object |
put(java.lang.Object key,
java.lang.Object value)
|
java.lang.Object |
remove(java.lang.Object key)
|
protected abstract void |
unhookListener(java.lang.Object removedKey)
|
Methods inherited from class org.eclipse.core.databinding.observable.map.AbstractObservableMap |
---|
addChangeListener, addDisposeListener, addMapChangeListener, addStaleListener, checkRealm, fireChange, fireMapChange, fireStale, getRealm, hasListeners, isDisposed, removeChangeListener, removeDisposeListener, removeMapChangeListener, removeStaleListener, setStale |
Methods inherited from class java.util.AbstractMap |
---|
clear, clone, containsValue, equals, hashCode, isEmpty, putAll, size, toString, values |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.eclipse.core.databinding.observable.map.IObservableMap |
---|
containsValue, equals, hashCode, isEmpty, size, values |
Methods inherited from interface java.util.Map |
---|
clear, putAll |
Constructor Detail |
---|
public ComputedObservableMap(IObservableSet keySet)
keySet
- public ComputedObservableMap(IObservableSet keySet, java.lang.Object valueType)
keySet
- valueType
- Method Detail |
---|
protected void init()
protected void firstListenerAdded()
firstListenerAdded
in class AbstractObservableMap
protected void lastListenerRemoved()
lastListenerRemoved
in class AbstractObservableMap
protected final void fireSingleChange(java.lang.Object key, java.lang.Object oldValue, java.lang.Object newValue)
public java.lang.Object getKeyType()
IObservableMap
keyset
of this
observable map, or null
if the keyset is untyped.
getKeyType
in interface IObservableMap
getKeyType
in class AbstractObservableMap
keyset
of this
observable map, or null
if the keyset is untyped.public java.lang.Object getValueType()
IObservableMap
values
of this
observable map, or null
if the values collection is untyped.
getValueType
in interface IObservableMap
getValueType
in class AbstractObservableMap
values
of this
observable map, or null
if the values collection is
untyped.public java.lang.Object remove(java.lang.Object key)
remove
in interface java.util.Map
remove
in interface IObservableMap
remove
in class java.util.AbstractMap
public boolean containsKey(java.lang.Object key)
containsKey
in interface java.util.Map
containsKey
in interface IObservableMap
containsKey
in class java.util.AbstractMap
public java.util.Set entrySet()
entrySet
in interface java.util.Map
entrySet
in interface IObservableMap
entrySet
in class java.util.AbstractMap
public java.util.Set keySet()
keySet
in interface java.util.Map
keySet
in interface IObservableMap
keySet
in class java.util.AbstractMap
public final java.lang.Object get(java.lang.Object key)
get
in interface java.util.Map
get
in interface IObservableMap
get
in class java.util.AbstractMap
public final java.lang.Object put(java.lang.Object key, java.lang.Object value)
put
in interface java.util.Map
put
in interface IObservableMap
put
in class java.util.AbstractMap
protected abstract void unhookListener(java.lang.Object removedKey)
removedKey
- protected abstract void hookListener(java.lang.Object addedKey)
addedKey
- protected abstract java.lang.Object doGet(java.lang.Object key)
key
-
protected abstract java.lang.Object doPut(java.lang.Object key, java.lang.Object value)
key
- value
-
public boolean isStale()
IObservable
isStale
in interface IObservable
isStale
in class AbstractObservableMap
public void dispose()
IObservable
dispose
in interface IObservable
dispose
in class AbstractObservableMap
|
Eclipse Platform Kepler (4.3) |
|||||||||
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, 2012. All rights reserved.