Able.Add

trait Add[A]

Generic Add

Adding elements to some target container

Source
Add.scala
class java.lang.Object
trait scala.Matchable
class Any

Def

@scala.annotation.targetName("_addAll")
def ++=(v: ~[A]): Able.Add[A]

Alias for addAll

Alias for addAll

Calls addAll and returns container

 // Generic example
 val x =  Idx.M(1, 2, 3)

 x ++= (4 <> 6) ++= ~~(7, 8, 9)

 x.~.tp // ~~(1, 2, 3, 4, 5, 6, 7, 8, 9)
Source
Add.scala
@scala.annotation.targetName("_addOpt")
def ++=(v: Opt[A]): Able.Add[A]

Alias for addAll

Alias for addAll

Generally Opt could be added as a stream.

This overload is sligtly more efficient, but it also required for mapped Opt expressions, where Opt type is harder to resolve and it would not compile.

Source
Add.scala
@scala.annotation.targetName("_add")
def +=(v: A): Able.Add[A]

Alias for add

Alias for add

Calls add and returns container

 // Generic example
 val x =  Idx.M(1, 2, 3)

  x += 4 += 5 += 6

  x.~.tp // Prints ~(1, 2, 3, 4, 5, 6)
Source
Add.scala
def add(v: A): Unit

Add

Add

Adds given value to target container

 // Generic example
 val x =  Idx.M(1, 2, 3)

  x.add(4)
  x.add(5)
  x.add(6)

  x.~.tp // Prints ~(1, 2, 3, 4, 5, 6)
Source
Add.scala
def addAll(v: ~[A]): Unit

Add many

Add many

Adds given stream of elements to target container

 // Generic example
 val x =  Idx.M(1, 2, 3)

  x.addAll(4 <> 6)
  x.addAll( ~~(7,8,9))

  x.~.tp // ~(1, 2, 3, 4, 5, 6, 7, 8, 9)
Source
Add.scala