scala.collection.mutable
trait ObservableSet

[source: `scala/collection/mutable/ObservableSet.scala`]

`` `trait` ObservableSet[A, This <: ObservableSet[A, This]]
  `extends` Set[A]`with` Publisher[Message[A]`with` Undoable, This]

  This class is typically used as a mixin. It adds a subscription mechanism to the `Set` class into which this abstract class is mixed in. Class `ObservableSet` publishes events of the type `Message`.

Author
  Matthias Zenger
Version
  1.0, 08/07/2003

Method Summary
`def` | += (elem : A) : Unit Add a new element to the set.
`def` | -= (elem : A) : Unit Removes a single element from a set.
`def` | clear : Unit Removes all elements from the set. After this operation is completed, the set will be empty.

Methods inherited from Publisher
subscribe, subscribe, suspendSubscription, activateSubscription, removeSubscription, removeSubscriptions, publish

Methods inherited from Set
update, +=, ++=, ++=, +, +, ++, ++, incl, -=, --=, --=, -, -, --, --, excl, intersect, retain, <<, clone, readOnly

Methods inherited from Set
size (abstract), contains (abstract), apply, isEmpty, subsetOf, equals, hashCode, toArray

Methods inherited from Collection
toString, stringPrefix, equalWith

Methods inherited from Iterable
elements (abstract), concat, ++, map, flatMap, filter, takeWhile, dropWhile, take, drop, foreach, forall, exists, find, findIndexOf, indexOf, foldLeft, foldRight, /:, :\, reduceLeft, reduceRight, copyToBuffer, sameElements, toList, mkString, mkString, addString, addString, copyToArray, projection, hasDefiniteSize

Methods inherited from Function1
compose, andThen

Methods inherited from AnyRef
getClass, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized

Methods inherited from Any
==, !=, isInstanceOf, asInstanceOf

Method Details

`` `def` +=(elem : A) : Unit

  Add a new element to the set.

Parameters
  `elem -` the element to be added

Overrides
  Set.+=

`` `def` -=(elem : A) : Unit

  Removes a single element from a set.

Parameters
  `elem -` The element to be removed.

Overrides
  Set.-=

`` `def` clear : Unit

  Removes all elements from the set. After this operation is completed, the set will be empty.

Overrides
  Set.clear