org.eclipse.gef.common.beans.binding

## Class MultisetExpressionHelper<E>

- java.lang.Object
- - org.eclipse.gef.common.collections.MultisetListenerHelper<E>
  - - org.eclipse.gef.common.beans.binding.MultisetExpressionHelper<E>

Type Parameters:
  `E` - The element type of the `ObservableMultiset`.

    public class MultisetExpressionHelper<E>
    extends MultisetListenerHelper<E>

A utility class to support change notifications for an `ObservableMultiset`.

### Nested Class Summary

### Nested classes/interfaces inherited from class org.eclipse.gef.common.collections.MultisetListenerHelper

`MultisetListenerHelper.AtomicChange<E>, MultisetListenerHelper.ElementarySubChange<E>`

### Constructor Summary

Constructors
Constructor and Description
`MultisetExpressionHelper(ObservableMultisetValue<E> observableValue)` Constructs a new `MultisetExpressionHelper` for the given source `ObservableMultisetValue`.

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `addListener(ChangeListener<? super ObservableMultiset<E>> listener)` Adds a new `ChangeListener` to this `MultisetExpressionHelper`.
`void` `fireValueChangedEvent()` Fires notifications to all attached `InvalidationListeners`, `ChangeListeners`, and `MultisetChangeListeners`.
`void` `fireValueChangedEvent(MultisetChangeListener.Change<? extends E> change)` Fires notifications to all attached `InvalidationListeners`, and `MultisetChangeListeners`.
`void` `removeListener(ChangeListener<? super ObservableMultiset<E>> listener)` Removes the given `ChangeListener` from this `MultisetChangeListener`.

### Methods inherited from class org.eclipse.gef.common.collections.MultisetListenerHelper

`addListener, addListener, getSource, notifyInvalidationListeners, notifyMultisetChangeListeners, removeListener, removeListener`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### MultisetExpressionHelper

    public MultisetExpressionHelper(ObservableMultisetValue<E> observableValue)

Constructs a new `MultisetExpressionHelper` for the given source `ObservableMultisetValue`.

Parameters:
  `observableValue` - The observableValue `ObservableMultiset`, which is used in change notifications.

### Method Detail

#### addListener

    public void addListener(ChangeListener<? super ObservableMultiset<E>> listener)

Adds a new `ChangeListener` to this `MultisetExpressionHelper`. If the same listener is added more than once, it will be registered more than once and will receive multiple change events.

Parameters:
  `listener` - The listener to add.

#### fireValueChangedEvent

    public void fireValueChangedEvent()

Fires notifications to all attached `InvalidationListeners`, `ChangeListeners`, and `MultisetChangeListeners`.

#### fireValueChangedEvent

    public void fireValueChangedEvent(MultisetChangeListener.Change<? extends E> change)

Fires notifications to all attached `InvalidationListeners`, and `MultisetChangeListeners`.

Overrides:
  `fireValueChangedEvent` in class `MultisetListenerHelper<E>`
Parameters:
  `change` - The change that needs to be propagated.

#### removeListener

    public void removeListener(ChangeListener<? super ObservableMultiset<E>> listener)

Removes the given `ChangeListener` from this `MultisetChangeListener`. If it was registered more than once, removes only one occurrence.

Parameters:
  `listener` - The `ChangeListener` to remove.