E - the type of the elements in this setpublic abstract class AbstractObservableSet<E> extends AbstractObservable implements IObservableSet<E>
IObservableSet.
This class is thread safe. All state accessing methods must be invoked from
the current realm. Methods for adding and removing
listeners may be invoked from any thread.
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractObservableSet() |
protected |
AbstractObservableSet(Realm realm) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(E o) |
boolean |
addAll(java.util.Collection<? extends E> c) |
protected void |
addListener(java.lang.Object listenerType,
IObservablesListener listener) |
void |
addSetChangeListener(ISetChangeListener<? super E> listener) |
void |
clear() |
protected java.lang.Object |
clone() |
boolean |
contains(java.lang.Object o) |
boolean |
containsAll(java.util.Collection<?> c) |
boolean |
equals(java.lang.Object o) |
protected void |
fireChange() |
protected void |
fireEvent(ObservableEvent event) |
protected void |
fireSetChange(SetDiff<E> diff) |
protected void |
firstListenerAdded() |
Realm |
getRealm() |
protected void |
getterCalled() |
protected abstract java.util.Set<E> |
getWrappedSet() |
int |
hashCode() |
protected boolean |
hasListeners() |
boolean |
isEmpty() |
boolean |
isStale()
Returns whether the state of this observable is stale and is expected to
change soon.
|
java.util.Iterator<E> |
iterator() |
protected void |
lastListenerRemoved() |
boolean |
remove(java.lang.Object o) |
boolean |
removeAll(java.util.Collection<?> c) |
protected void |
removeListener(java.lang.Object listenerType,
IObservablesListener listener) |
void |
removeSetChangeListener(ISetChangeListener<? super E> listener) |
boolean |
retainAll(java.util.Collection<?> c) |
void |
setStale(boolean stale) |
int |
size() |
java.lang.Object[] |
toArray() |
<T> T[] |
toArray(T[] a) |
java.lang.String |
toString() |
addChangeListener, addDisposeListener, addStaleListener, checkRealm, dispose, fireStale, isDisposed, removeChangeListener, removeDisposeListener, removeStaleListenerfinalize, getClass, notify, notifyAll, wait, wait, waitgetElementTypeaddChangeListener, addDisposeListener, addStaleListener, dispose, getRealm, isDisposed, removeChangeListener, removeDisposeListener, removeStaleListenerprotected AbstractObservableSet()
protected AbstractObservableSet(Realm realm)
protected void firstListenerAdded()
protected void lastListenerRemoved()
public void addSetChangeListener(ISetChangeListener<? super E> listener)
addSetChangeListener in interface IObservableSet<E>public void removeSetChangeListener(ISetChangeListener<? super E> listener)
removeSetChangeListener in interface IObservableSet<E>protected abstract java.util.Set<E> getWrappedSet()
public boolean contains(java.lang.Object o)
contains in interface java.util.Collection<E>contains in interface java.util.Set<E>contains in interface IObservableSet<E>public boolean containsAll(java.util.Collection<?> c)
containsAll in interface java.util.Collection<E>containsAll in interface java.util.Set<E>containsAll in interface IObservableSet<E>public boolean equals(java.lang.Object o)
equals in interface java.util.Collection<E>equals in interface java.util.Set<E>equals in interface IObservableSet<E>equals in class java.lang.Objectpublic int hashCode()
hashCode in interface java.util.Collection<E>hashCode in interface java.util.Set<E>hashCode in interface IObservableSet<E>hashCode in class java.lang.Objectpublic boolean isEmpty()
isEmpty in interface java.util.Collection<E>isEmpty in interface java.util.Set<E>isEmpty in interface IObservableSet<E>public java.util.Iterator<E> iterator()
public int size()
size in interface java.util.Collection<E>size in interface java.util.Set<E>size in interface IObservableSet<E>public java.lang.Object[] toArray()
toArray in interface java.util.Collection<E>toArray in interface java.util.Set<E>toArray in interface IObservableSet<E>public <T> T[] toArray(T[] a)
toArray in interface java.util.Collection<E>toArray in interface java.util.Set<E>toArray in interface IObservableSet<E>public java.lang.String toString()
toString in class java.lang.Objectprotected void getterCalled()
public boolean add(E o)
add in interface java.util.Collection<E>add in interface java.util.Set<E>add in interface IObservableSet<E>public boolean addAll(java.util.Collection<? extends E> c)
addAll in interface java.util.Collection<E>addAll in interface java.util.Set<E>addAll in interface IObservableSet<E>public boolean remove(java.lang.Object o)
remove in interface java.util.Collection<E>remove in interface java.util.Set<E>remove in interface IObservableSet<E>public boolean removeAll(java.util.Collection<?> c)
removeAll in interface java.util.Collection<E>removeAll in interface java.util.Set<E>removeAll in interface IObservableSet<E>public boolean retainAll(java.util.Collection<?> c)
retainAll in interface java.util.Collection<E>retainAll in interface java.util.Set<E>retainAll in interface IObservableSet<E>public void clear()
public boolean isStale()
IObservableisStale in interface IObservablepublic void setStale(boolean stale)
stale - The stale state to set. This will fire a stale event if the
given boolean is true and this observable set was not already
stale.protected void fireChange()
fireChange in class AbstractObservableprotected void addListener(java.lang.Object listenerType,
IObservablesListener listener)
listenerType - listener - protected void removeListener(java.lang.Object listenerType,
IObservablesListener listener)
listenerType - listener - protected boolean hasListeners()
protected void fireEvent(ObservableEvent event)
public Realm getRealm()
protected java.lang.Object clone()
throws java.lang.CloneNotSupportedException
clone in class java.lang.Objectjava.lang.CloneNotSupportedException
Copyright (c) 2000, 2018 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.