dotty.tools.dotc.core.Decorators

ListDecorator

Related Doc: package Decorators

implicit final class ListDecorator[T] extends AnyVal

Implements filterConserve, zipWithConserve methods on lists that avoid duplication of list nodes where feasible.

Linear Supertypes
AnyVal, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. ListDecorator
  2. AnyVal
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new ListDecorator(xs: List[T])

Value Members

  1. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  2. final def ##(): Int

    Definition Classes
    Any
  3. def &(ys: List[T]): List[T]

    Intersection on lists seen as sets

  4. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  5. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  6. def filterConserve(p: (T) ⇒ Boolean): List[T]

    Like xs filter p but returns list xs itself - instead of a copy - if p is true for all elements and xs is not longer than MaxFilterRecursions.

  7. def foldRightBN[U](z: ⇒ U)(op: (T, ⇒ U) ⇒ U): U

  8. def getClass(): Class[_ <: AnyVal]

    Definition Classes
    AnyVal → Any
  9. final def hasSameLengthAs[U](ys: List[U]): Boolean

  10. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  11. final def mapconserve[U](f: (T) ⇒ U): List[U]

  12. def toString(): String

    Definition Classes
    Any
  13. val xs: List[T]

  14. def zipWithConserve[U](ys: List[U])(f: (T, U) ⇒ T): List[T]

    Like (xs, ys).zipped.map(f), but returns list xs itself

    Like (xs, ys).zipped.map(f), but returns list xs itself

    • instead of a copy - if function f maps all elements of xs to themselves. Also, it is required that ys is at least as long as xs.
  15. def |(ys: List[T]): List[T]

    Union on lists seen as sets

Inherited from AnyVal

Inherited from Any

Ungrouped