Def
Alias for removeAll
Alias for removeAll
Removes all collection elements, which are equal to those in given stream
Returns the collection itself
- Inherited from
- Mutable
- Source
- Mutable.scala
Alias for remove
Alias for remove
Removes all collection elements, which are equal to the given value
Returns the collection itself
- Inherited from
- Mutable
- Source
- Mutable.scala
Remove everything
Remove everything
Discards all elements, so the colection size will become 0
- Inherited from
- Mutable
- Source
- Mutable.scala
On element add
On element add
Subscribes given function to element add event
val co: Collection.ObservableMutable[Int] = Collection.OM[Int]()
co.onAdd("Added: "+ _ tp())
co ++= 1 <> 3
// Output
Added: 1
Added: 2
Added: 3
- Inherited from
- Observable
- Source
- Observable.scala
On element remove
On element remove
Subscribes given function to element remove event
val co: Collection.ObservableMutable[Int] = Collection.OM[Int]()
co.onRemove("Removed: "+ _ tp())
co ++= 1 <> 10
co --= 5 <> 7
// Output
Removed: 7
Removed: 6
Removed: 5
- Inherited from
- Observable
- Source
- Observable.scala
Remove element
Remove element
Removes all collection elements, which are equal to the given value
Returns count of removed elements, which can be 0, 1, or many
- Inherited from
- Mutable
- Source
- Mutable.scala
Remove all streamed
Remove all streamed
Removes all collection elements, which are equal to those in given stream
Returns count of removed elements, which can be 0, 1, or many
- Inherited from
- Mutable
- Source
- Mutable.scala
Replace everything
Replace everything
Discards all old elements and adds all provided elements
- Inherited from
- Mutable
- Source
- Mutable.scala
Stream elements
Stream elements
Returns a stream of all collection elements
Unless specifically defined, the order must be assumed as random
val c = Collection(1,3,5,7)
c.stream.tp
// Output
Stream(1, 3, 5, 7)
- Inherited from
- Collection
- Source
- __.scala