c

olon.common

SimpleList

final case class SimpleList[T](underlying: List[T]) extends List[T] with Product with Serializable

An immutable singly linked list that uses the Scala List class as backing store, but is Java-friendly as a java.util.List. Note however that since it is immutable, you have to capture the results of addition/removal operations.

The typical mutating methods like add, set, clear, and remove are all unsupported, as are mutating methods on its iterators, since this collection is immutable.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. SimpleList
  2. Serializable
  3. Product
  4. Equals
  5. List
  6. Collection
  7. Iterable
  8. AnyRef
  9. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new SimpleList(jl: List[T])
  2. new SimpleList()

    Construct an empty list.

  3. new SimpleList(underlying: List[T])

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def add(after: Int, x: T): Unit
    Definition Classes
    SimpleList → List
  5. def add(x: T): Boolean
    Definition Classes
    SimpleList → List → Collection
  6. def addAll(index: Int, jc: Collection[_ <: T]): Boolean
    Definition Classes
    SimpleList → List
  7. def addAll(jc: Collection[_ <: T]): Boolean
    Definition Classes
    SimpleList → List → Collection
  8. def append(item: T): SimpleList[T]

    Append an item to this list.

    Append an item to this list. This operation is O(n) where n is the number of items in the underlying List, and returns the updated list.

  9. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  10. def clear(): Unit
    Definition Classes
    SimpleList → List → Collection
  11. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
  12. def contains(obj: AnyRef): Boolean

    Returns true if this list contains the given obj.

    Returns true if this list contains the given obj.

    Definition Classes
    SimpleList → List → Collection
  13. def containsAll(jc: Collection[_]): Boolean
    Definition Classes
    SimpleList → List → Collection
  14. def drop(n: Int): SimpleList[T]
  15. def dropRight(n: Int): SimpleList[T]
  16. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  17. def forEach(arg0: Consumer[_ >: T <: AnyRef]): Unit
    Definition Classes
    Iterable
  18. def get(pos: Int): T
    Definition Classes
    SimpleList → List
  19. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  20. def head(): T
  21. def headOption(): Option[T]
  22. def indexOf(obj: AnyRef): Int
    Definition Classes
    SimpleList → List
  23. def isEmpty(): Boolean
    Definition Classes
    SimpleList → List → Collection
  24. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  25. def iterator(): Iterator[T]
    Definition Classes
    SimpleList → List → Collection → Iterable
  26. def lastIndexOf(obj: AnyRef): Int
    Definition Classes
    SimpleList → List
  27. def listIterator(pos: Int): ListIterator[T]
    Definition Classes
    SimpleList → List
  28. def listIterator(): ListIterator[T]
    Definition Classes
    SimpleList → List
  29. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  30. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  31. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  32. def parallelStream(): Stream[T]
    Definition Classes
    Collection
  33. def prepend(item: T): SimpleList[T]

    Prepends an item to this list.

    Prepends an item to this list. This operation is O(1) and returns the updated list.

  34. def productElementNames: Iterator[String]
    Definition Classes
    Product
  35. def remove(obj: AnyRef): Boolean
    Definition Classes
    SimpleList → List → Collection
  36. def remove(pos: Int): T
    Definition Classes
    SimpleList → List
  37. def removeAll(jc: Collection[_]): Boolean
    Definition Classes
    SimpleList → List → Collection
  38. def removeIf(arg0: Predicate[_ >: T <: AnyRef]): Boolean
    Definition Classes
    Collection
  39. def replaceAll(arg0: UnaryOperator[T]): Unit
    Definition Classes
    List
  40. def retainAll(jc: Collection[_]): Boolean
    Definition Classes
    SimpleList → List → Collection
  41. def reverse(): SimpleList[T]
  42. def set(after: Int, x: T): T
    Definition Classes
    SimpleList → List
  43. def size(): Int
    Definition Classes
    SimpleList → List → Collection
  44. def sort(arg0: Comparator[_ >: T <: AnyRef]): Unit
    Definition Classes
    List
  45. def spliterator(): Spliterator[T]
    Definition Classes
    List → Collection → Iterable
  46. def stream(): Stream[T]
    Definition Classes
    Collection
  47. def subList(from: Int, to: Int): List[T]
    Definition Classes
    SimpleList → List
  48. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  49. def tail(): SimpleList[T]
  50. def take(n: Int): SimpleList[T]
  51. def takeRight(n: Int): SimpleList[T]
  52. def toArray[X](in: Array[X]): Array[X]
    Definition Classes
    SimpleList → List → Collection
  53. def toArray(): Array[AnyRef]
    Definition Classes
    SimpleList → List → Collection
  54. def toArray[T <: AnyRef](arg0: IntFunction[Array[T]]): Array[T]
    Definition Classes
    Collection
  55. val underlying: List[T]
  56. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  57. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  58. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from List[T]

Inherited from Collection[T]

Inherited from Iterable[T]

Inherited from AnyRef

Inherited from Any

Ungrouped