c

org.parboiled2

ValueStack

class ValueStack extends Iterable[Any]

A mutable untyped stack of values. In most cases you won't have to access its API directly since parboiled2's DSL should allow you a safer and easier way to interact with the stack. However, in some cases, when you know what you are doing, direct access can be helpful.

Linear Supertypes
Iterable[Any], IterableFactoryDefaults[Any, Iterable], IterableOps[Any, Iterable, Iterable[Any]], IterableOnceOps[Any, Iterable, Iterable[Any]], IterableOnce[Any], AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ValueStack
  2. Iterable
  3. IterableFactoryDefaults
  4. IterableOps
  5. IterableOnceOps
  6. IterableOnce
  7. AnyRef
  8. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ++[B >: Any](suffix: IterableOnce[B]): Iterable[B]
    Definition Classes
    IterableOps
    Annotations
    @inline()
  4. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  5. final def addString(b: StringBuilder): b.type
    Definition Classes
    IterableOnceOps
    Annotations
    @inline()
  6. final def addString(b: StringBuilder, sep: String): b.type
    Definition Classes
    IterableOnceOps
    Annotations
    @inline()
  7. def addString(b: StringBuilder, start: String, sep: String, end: String): b.type
    Definition Classes
    IterableOnceOps
  8. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  9. def className: String
    Attributes
    protected[this]
    Definition Classes
    Iterable
  10. def clear(): Unit

    Removes all elements from the stack.

  11. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  12. final def coll: ValueStack.this.type
    Attributes
    protected
    Definition Classes
    Iterable → IterableOps
  13. def collect[B](pf: PartialFunction[Any, B]): Iterable[B]
    Definition Classes
    IterableOps → IterableOnceOps
  14. def collectFirst[B](pf: PartialFunction[Any, B]): Option[B]
    Definition Classes
    IterableOnceOps
  15. def concat[B >: Any](suffix: IterableOnce[B]): Iterable[B]
    Definition Classes
    IterableOps
  16. def copyToArray[B >: Any](xs: Array[B], start: Int, len: Int): Int
    Definition Classes
    IterableOnceOps
  17. def copyToArray[B >: Any](xs: Array[B], start: Int): Int
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecatedOverriding()
  18. def copyToArray[B >: Any](xs: Array[B]): Int
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecatedOverriding()
  19. def corresponds[B](that: IterableOnce[B])(p: (Any, B) => Boolean): Boolean
    Definition Classes
    IterableOnceOps
  20. def count(p: (Any) => Boolean): Int
    Definition Classes
    IterableOnceOps
  21. def drop(n: Int): Iterable[Any]
    Definition Classes
    IterableOps → IterableOnceOps
  22. def dropRight(n: Int): Iterable[Any]
    Definition Classes
    IterableOps
  23. def dropWhile(p: (Any) => Boolean): Iterable[Any]
    Definition Classes
    IterableOps → IterableOnceOps
  24. def empty: Iterable[Any]
    Definition Classes
    IterableFactoryDefaults → IterableOps
  25. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  26. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  27. def exists(p: (Any) => Boolean): Boolean
    Definition Classes
    IterableOnceOps
  28. def filter(pred: (Any) => Boolean): Iterable[Any]
    Definition Classes
    IterableOps → IterableOnceOps
  29. def filterNot(pred: (Any) => Boolean): Iterable[Any]
    Definition Classes
    IterableOps → IterableOnceOps
  30. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  31. def find(p: (Any) => Boolean): Option[Any]
    Definition Classes
    IterableOnceOps
  32. def flatMap[B](f: (Any) => IterableOnce[B]): Iterable[B]
    Definition Classes
    IterableOps → IterableOnceOps
  33. def flatten[B](implicit asIterable: (Any) => IterableOnce[B]): Iterable[B]
    Definition Classes
    IterableOps → IterableOnceOps
  34. def fold[A1 >: Any](z: A1)(op: (A1, A1) => A1): A1
    Definition Classes
    IterableOnceOps
  35. def foldLeft[B](z: B)(op: (B, Any) => B): B
    Definition Classes
    IterableOnceOps
  36. def foldRight[B](z: B)(op: (Any, B) => B): B
    Definition Classes
    IterableOnceOps
  37. def forall(p: (Any) => Boolean): Boolean
    Definition Classes
    IterableOnceOps
  38. def foreach[U](f: (Any) => U): Unit
    Definition Classes
    IterableOnceOps
  39. def fromSpecific(coll: IterableOnce[Any]): Iterable[Any]
    Attributes
    protected
    Definition Classes
    IterableFactoryDefaults → IterableOps
  40. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  41. def groupBy[K](f: (Any) => K): Map[K, Iterable[Any]]
    Definition Classes
    IterableOps
  42. def groupMap[K, B](key: (Any) => K)(f: (Any) => B): Map[K, Iterable[B]]
    Definition Classes
    IterableOps
  43. def groupMapReduce[K, B](key: (Any) => K)(f: (Any) => B)(reduce: (B, B) => B): Map[K, B]
    Definition Classes
    IterableOps
  44. def grouped(size: Int): Iterator[Iterable[Any]]
    Definition Classes
    IterableOps
  45. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  46. def head: Any
    Definition Classes
    IterableOps
  47. def headOption: Option[Any]
    Definition Classes
    IterableOps
  48. def init: Iterable[Any]
    Definition Classes
    IterableOps
  49. def inits: Iterator[Iterable[Any]]
    Definition Classes
    IterableOps
  50. def insert(down: Int, value: Any): Unit

    Inserts the given value into the stack down elements below the current top element.

    Inserts the given value into the stack down elements below the current top element. insert(0, 'x') is therefore equal to push('x'). Throws a ValueStackOverflowException if the stack has no more space available. Throws a ValueStackUnderflowException if down > size. Throws an IllegalArgumentException is down is negative.

  51. def isEmpty: Boolean

    True if no elements are currently on the stack.

    True if no elements are currently on the stack.

    Definition Classes
    ValueStack → IterableOnceOps
  52. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  53. def isTraversableAgain: Boolean
    Definition Classes
    IterableOps → IterableOnceOps
  54. def iterableFactory: IterableFactory[Iterable]
    Definition Classes
    Iterable → IterableOps
  55. def iterator: Iterator[Any]

    Returns an iterator that iterates over a *snapshot* of the stack elements at the time of this method call.

    Returns an iterator that iterates over a *snapshot* of the stack elements at the time of this method call. I.e. subsequent mutations are not visible to the iterator.

    Definition Classes
    ValueStack → IterableOnce
  56. def knownSize: Int
    Definition Classes
    IterableOnce
  57. def last: Any
    Definition Classes
    IterableOps
  58. def lastOption: Option[Any]
    Definition Classes
    IterableOps
  59. def lazyZip[B](that: Iterable[B]): LazyZip2[Any, B, ValueStack.this.type]
    Definition Classes
    Iterable
  60. def map[B](f: (Any) => B): Iterable[B]
    Definition Classes
    IterableOps → IterableOnceOps
  61. def max[B >: Any](implicit ord: Ordering[B]): Any
    Definition Classes
    IterableOnceOps
  62. def maxBy[B](f: (Any) => B)(implicit cmp: Ordering[B]): Any
    Definition Classes
    IterableOnceOps
  63. def maxByOption[B](f: (Any) => B)(implicit cmp: Ordering[B]): Option[Any]
    Definition Classes
    IterableOnceOps
  64. def maxOption[B >: Any](implicit ord: Ordering[B]): Option[Any]
    Definition Classes
    IterableOnceOps
  65. def min[B >: Any](implicit ord: Ordering[B]): Any
    Definition Classes
    IterableOnceOps
  66. def minBy[B](f: (Any) => B)(implicit cmp: Ordering[B]): Any
    Definition Classes
    IterableOnceOps
  67. def minByOption[B](f: (Any) => B)(implicit cmp: Ordering[B]): Option[Any]
    Definition Classes
    IterableOnceOps
  68. def minOption[B >: Any](implicit ord: Ordering[B]): Option[Any]
    Definition Classes
    IterableOnceOps
  69. final def mkString: String
    Definition Classes
    IterableOnceOps
    Annotations
    @inline()
  70. final def mkString(sep: String): String
    Definition Classes
    IterableOnceOps
    Annotations
    @inline()
  71. final def mkString(start: String, sep: String, end: String): String
    Definition Classes
    IterableOnceOps
  72. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  73. def newSpecificBuilder: Builder[Any, Iterable[Any]]
    Attributes
    protected
    Definition Classes
    IterableFactoryDefaults → IterableOps
  74. def nonEmpty: Boolean
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecatedOverriding()
  75. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  76. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  77. def partition(p: (Any) => Boolean): (Iterable[Any], Iterable[Any])
    Definition Classes
    IterableOps
  78. def partitionMap[A1, A2](f: (Any) => Either[A1, A2]): (Iterable[A1], Iterable[A2])
    Definition Classes
    IterableOps
  79. def peek(down: Int): Any

    Returns the element down elements below the current top element without removing it.

    Returns the element down elements below the current top element without removing it. peek(0) is therefore equal to peek(). Throws a ValueStackUnderflowException if down >= size. Throws an IllegalArgumentException is down is negative.

  80. def peek: Any

    Returns the top element without removing it.

    Returns the top element without removing it. Throws a ValueStackUnderflowException if the stack is empty.

  81. def poke(down: Int, value: Any): Unit

    Replaces the element down elements below the current top element with the given one.

    Replaces the element down elements below the current top element with the given one. Throws a ValueStackUnderflowException if down >= size. Throws an IllegalArgumentException if down is negative.

  82. def pop(): Any

    Removes the top element from the stack and returns it.

    Removes the top element from the stack and returns it. Throws a ValueStackUnderflowException if the stack is empty.

  83. def product[B >: Any](implicit num: Numeric[B]): B
    Definition Classes
    IterableOnceOps
  84. def pullOut(down: Int): Any

    Removes the element down elements below the current top element from the stack and returns it.

    Removes the element down elements below the current top element from the stack and returns it. pullOut(0) is therefore equal to pop(). Throws a ValueStackUnderflowException if down >= size. Throws an IllegalArgumentException is down is negative.

  85. def push(value: Any): Unit

    Puts the given value onto the stack.

    Puts the given value onto the stack. Throws a ValueStackOverflowException if the stack has no more space available.

  86. final def pushAll(hlist: HList): Unit

    Puts the given HList of values onto the stack.

    Puts the given HList of values onto the stack. Throws a ValueStackOverflowException if the stack has no more space available.

    Annotations
    @tailrec()
  87. def reduce[B >: Any](op: (B, B) => B): B
    Definition Classes
    IterableOnceOps
  88. def reduceLeft[B >: Any](op: (B, Any) => B): B
    Definition Classes
    IterableOnceOps
  89. def reduceLeftOption[B >: Any](op: (B, Any) => B): Option[B]
    Definition Classes
    IterableOnceOps
  90. def reduceOption[B >: Any](op: (B, B) => B): Option[B]
    Definition Classes
    IterableOnceOps
  91. def reduceRight[B >: Any](op: (Any, B) => B): B
    Definition Classes
    IterableOnceOps
  92. def reduceRightOption[B >: Any](op: (Any, B) => B): Option[B]
    Definition Classes
    IterableOnceOps
  93. def reversed: Iterable[Any]
    Attributes
    protected
    Definition Classes
    IterableOnceOps
  94. def scan[B >: Any](z: B)(op: (B, B) => B): Iterable[B]
    Definition Classes
    IterableOps
  95. def scanLeft[B](z: B)(op: (B, Any) => B): Iterable[B]
    Definition Classes
    IterableOps → IterableOnceOps
  96. def scanRight[B](z: B)(op: (Any, B) => B): Iterable[B]
    Definition Classes
    IterableOps
  97. def show: String

    Creates a string representation of the current value stack contents.

    Creates a string representation of the current value stack contents. Mostly useful for debugging.

  98. def size: Int

    The number of elements currently on the stack.

    The number of elements currently on the stack.

    Definition Classes
    ValueStack → IterableOnceOps
  99. def sizeCompare(that: Iterable[_]): Int
    Definition Classes
    IterableOps
  100. def sizeCompare(otherSize: Int): Int
    Definition Classes
    IterableOps
  101. final def sizeIs: SizeCompareOps
    Definition Classes
    IterableOps
    Annotations
    @inline()
  102. def slice(from: Int, until: Int): Iterable[Any]
    Definition Classes
    IterableOps → IterableOnceOps
  103. def sliding(size: Int, step: Int): Iterator[Iterable[Any]]
    Definition Classes
    IterableOps
  104. def sliding(size: Int): Iterator[Iterable[Any]]
    Definition Classes
    IterableOps
  105. def span(p: (Any) => Boolean): (Iterable[Any], Iterable[Any])
    Definition Classes
    IterableOps → IterableOnceOps
  106. def splitAt(n: Int): (Iterable[Any], Iterable[Any])
    Definition Classes
    IterableOps → IterableOnceOps
  107. def stepper[S <: Stepper[_]](implicit shape: StepperShape[Any, S]): S
    Definition Classes
    IterableOnce
  108. def stringPrefix: String
    Attributes
    protected[this]
    Definition Classes
    Iterable
    Annotations
    @deprecatedOverriding()
  109. def sum[B >: Any](implicit num: Numeric[B]): B
    Definition Classes
    IterableOnceOps
  110. def swap(): Unit

    Swaps the top 2 stack elements.

    Swaps the top 2 stack elements. Throws a ValueStackUnderflowException if size < 2.

  111. def swap3(): Unit

    Swaps the top 3 stack elements.

    Swaps the top 3 stack elements. Throws a ValueStackUnderflowException if size < 3.

  112. def swap4(): Unit

    Swaps the top 4 stack elements.

    Swaps the top 4 stack elements. Throws a ValueStackUnderflowException if size < 4.

  113. def swap5(): Unit

    Swaps the top 5 stack elements.

    Swaps the top 5 stack elements. Throws a ValueStackUnderflowException if size < 5.

  114. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  115. def tail: Iterable[Any]
    Definition Classes
    IterableOps
  116. def tails: Iterator[Iterable[Any]]
    Definition Classes
    IterableOps
  117. def take(n: Int): Iterable[Any]
    Definition Classes
    IterableOps → IterableOnceOps
  118. def takeRight(n: Int): Iterable[Any]
    Definition Classes
    IterableOps
  119. def takeWhile(p: (Any) => Boolean): Iterable[Any]
    Definition Classes
    IterableOps → IterableOnceOps
  120. def tapEach[U](f: (Any) => U): Iterable[Any]
    Definition Classes
    IterableOps → IterableOnceOps
  121. def to[C1](factory: Factory[Any, C1]): C1
    Definition Classes
    IterableOnceOps
  122. def toArray: Array[Any]

    Returns all current stack elements as a new array.

  123. def toArray[B >: Any](implicit arg0: ClassTag[B]): Array[B]
    Definition Classes
    IterableOnceOps
  124. final def toBuffer[B >: Any]: Buffer[B]
    Definition Classes
    IterableOnceOps
    Annotations
    @inline()
  125. final def toHList[L <: HList](start: Int = 0, end: Int = _size, prependTo: HList = HNil): L

    Copies all elements between the given start (inclusive) and end (exclusive) indices into an HList that is prepended to the given tail.

    Copies all elements between the given start (inclusive) and end (exclusive) indices into an HList that is prepended to the given tail. Throws an IllegalArgumentException if start < 0 || start > end. Throws a ValueStackUnderflowException if end > size.

    Annotations
    @tailrec()
  126. def toIndexedSeq: IndexedSeq[Any]
    Definition Classes
    IterableOnceOps
  127. def toList: List[Any]
    Definition Classes
    IterableOnceOps
  128. def toMap[K, V](implicit ev: <:<[Any, (K, V)]): Map[K, V]
    Definition Classes
    IterableOnceOps
  129. def toSeq: Seq[Any]
    Definition Classes
    IterableOnceOps
  130. def toSet[B >: Any]: Set[B]
    Definition Classes
    IterableOnceOps
  131. def toString(): String
    Definition Classes
    Iterable → AnyRef → Any
  132. def toVector: Vector[Any]
    Definition Classes
    IterableOnceOps
  133. def transpose[B](implicit asIterable: (Any) => Iterable[B]): Iterable[Iterable[B]]
    Definition Classes
    IterableOps
  134. def unzip[A1, A2](implicit asPair: (Any) => (A1, A2)): (Iterable[A1], Iterable[A2])
    Definition Classes
    IterableOps
  135. def unzip3[A1, A2, A3](implicit asTriple: (Any) => (A1, A2, A3)): (Iterable[A1], Iterable[A2], Iterable[A3])
    Definition Classes
    IterableOps
  136. def view: View[Any]
    Definition Classes
    IterableOps
  137. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  138. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  139. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  140. def withFilter(p: (Any) => Boolean): WithFilter[Any, Iterable]
    Definition Classes
    IterableOps
  141. def zip[B](that: IterableOnce[B]): Iterable[(Any, B)]
    Definition Classes
    IterableOps
  142. def zipAll[A1 >: Any, B](that: Iterable[B], thisElem: A1, thatElem: B): Iterable[(A1, B)]
    Definition Classes
    IterableOps
  143. def zipWithIndex: Iterable[(Any, Int)]
    Definition Classes
    IterableOps → IterableOnceOps

Deprecated Value Members

  1. def ++:[B >: Any](that: IterableOnce[B]): Iterable[B]
    Definition Classes
    IterableOps
    Annotations
    @deprecated
    Deprecated

    (Since version 2.13.0) Use ++ instead of ++: for collections of type Iterable

  2. final def /:[B](z: B)(op: (B, Any) => B): B
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecated @inline()
    Deprecated

    (Since version 2.13.0) Use foldLeft instead of /:

  3. final def :\[B](z: B)(op: (Any, B) => B): B
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecated @inline()
    Deprecated

    (Since version 2.13.0) Use foldRight instead of :\

  4. def aggregate[B](z: => B)(seqop: (B, Any) => B, combop: (B, B) => B): B
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecated
    Deprecated

    (Since version 2.13.0) aggregate is not relevant for sequential collections. Use foldLeft(z)(seqop) instead.

  5. def companion: IterableFactory[Iterable]
    Definition Classes
    IterableOps
    Annotations
    @deprecated @deprecatedOverriding() @inline()
    Deprecated

    (Since version 2.13.0) Use iterableFactory instead

  6. final def copyToBuffer[B >: Any](dest: Buffer[B]): Unit
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecated @inline()
    Deprecated

    (Since version 2.13.0) Use dest ++= coll instead

  7. def hasDefiniteSize: Boolean
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecated
    Deprecated

    (Since version 2.13.0) Check .knownSize instead of .hasDefiniteSize for more actionable information (see scaladoc for details)

  8. final def repr: Iterable[Any]
    Definition Classes
    IterableOps
    Annotations
    @deprecated
    Deprecated

    (Since version 2.13.0) Use coll instead of repr in a collection implementation, use the collection value itself from the outside

  9. def seq: ValueStack.this.type
    Definition Classes
    Iterable
    Annotations
    @deprecated
    Deprecated

    (Since version 2.13.0) Iterable.seq always returns the iterable itself

  10. final def toIterable: ValueStack.this.type
    Definition Classes
    Iterable → IterableOps
    Annotations
    @deprecated
    Deprecated

    (Since version 2.13.7) toIterable is internal and will be made protected; its name is similar to toList or toSeq, but it doesn't copy non-immutable collections

  11. final def toIterator: Iterator[Any]
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecated @inline()
    Deprecated

    (Since version 2.13.0) Use .iterator instead of .toIterator

  12. final def toStream: Stream[Any]
    Definition Classes
    IterableOnceOps
    Annotations
    @deprecated @inline()
    Deprecated

    (Since version 2.13.0) Use .to(LazyList) instead of .toStream

  13. final def toTraversable: Traversable[Any]
    Definition Classes
    IterableOps
    Annotations
    @deprecated
    Deprecated

    (Since version 2.13.0) toTraversable is internal and will be made protected; its name is similar to toList or toSeq, but it doesn't copy non-immutable collections

  14. def view(from: Int, until: Int): View[Any]
    Definition Classes
    IterableOps
    Annotations
    @deprecated
    Deprecated

    (Since version 2.13.0) Use .view.slice(from, until) instead of .view(from, until)

Inherited from Iterable[Any]

Inherited from IterableFactoryDefaults[Any, Iterable]

Inherited from IterableOps[Any, Iterable, Iterable[Any]]

Inherited from IterableOnceOps[Any, Iterable, Iterable[Any]]

Inherited from IterableOnce[Any]

Inherited from AnyRef

Inherited from Any

Ungrouped