Packages

  • package root
    Definition Classes
    root
  • package sigma

    The following implicit values are used as type descriptors of all the predefined Sigma types.

    The following implicit values are used as type descriptors of all the predefined Sigma types.

    Definition Classes
    root
    See also

    RType class

  • package ast
    Definition Classes
    sigma
  • package crypto
    Definition Classes
    sigma
  • package data

    Contains cores definitions which serves as a basis for sigma package implementations.

    Contains cores definitions which serves as a basis for sigma package implementations.

    Definition Classes
    sigma
  • package eval
    Definition Classes
    sigma
  • package exceptions
    Definition Classes
    sigma
  • package impl
    Definition Classes
    sigma
  • package interpreter
    Definition Classes
    sigma
  • package kiama

    Kiama is a Scala library for language processing.

    Kiama is a Scala library for language processing. It is a project of the Programming Languages Research Group at Macquarie University. For full project details see the web site http://github.com/inkytonik/kiama.

    Kiama's main components address tree decoration via attribute grammars (package attribution), tree transformation via strategic term rewriting (package rewriting), dynamic semantics (package machine) and pretty-printing (package output).

    The util package contains support modules for parsing, input/output, read-eval-print loops (REPLs) and pattern matching.

    The examples package (available as part of the Kiama tests) contains many examples of using Kiama to solve small to medium language processing problems.

    Definition Classes
    sigma
  • package reflection

    Contains the Sigma Reflection API.

    Contains the Sigma Reflection API. Sigma reflection is a mechanism for obtaining metadata about classes, methods, fields, etc. at runtime. It is used by kiama to rewrite ErgoTree expressions. It is also used by the ErgoTree interpreter to implement MethodCall nodes.

    The Sigma Reflection API has two implementations: 1) based on the Java Reflection API 2) based on Sigma Reflection metadata declared in the StaticImpl.scala file

    Definition Classes
    sigma
  • package serialization
    Definition Classes
    sigma
  • package util
    Definition Classes
    sigma
  • package utils
    Definition Classes
    sigma
  • package validation
    Definition Classes
    sigma
  • package wrappers
    Definition Classes
    sigma
  • AnyValue
  • AvlTree
  • BigInt
  • Box
  • Coll
  • CollBuilder
  • Colls
  • CollsModule
  • Context
  • Environment
  • Evaluation
  • Extensions
  • GroupElement
  • Header
  • PairColl
  • Platform
  • PreHeader
  • RuntimePlatform
  • SigmaContract
  • SigmaDataReflection
  • SigmaDsl
  • SigmaDslBuilder
  • SigmaDslModule
  • SigmaException
  • SigmaProp
  • VersionContext
t

sigma

PairColl

trait PairColl[L, R] extends Coll[(L, R)]

Base trait for specialized (Structure-Of-Arrays) representation of collection of pairs (i.e. Coll[(A, B)]). Some instances of Coll[(A, B)] may be instances of this trait, but it is NOT guaranteed, since some of them may be instances of CollOverArray[(A, B)].

Linear Supertypes
Coll[(L, R)], AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. PairColl
  2. Coll
  3. AnyRef
  4. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Abstract Value Members

  1. abstract def append(other: Coll[(L, R)]): Coll[(L, R)]

    Puts the elements of other collection after the elements of this collection (concatenation of 2 collections)

    Puts the elements of other collection after the elements of this collection (concatenation of 2 collections)

    Definition Classes
    Coll
  2. abstract def apply(i: Int): (L, R)

    The element at given index.

    The element at given index. Indices start at 0; xs.apply(0) is the first element of collection xs. Note the indexing syntax xs(i) is a shorthand for xs.apply(i).

    i

    the index

    returns

    the element at the given index

    Definition Classes
    Coll
    Exceptions thrown

    ArrayIndexOutOfBoundsException if i < 0 or length <= i

  3. abstract def builder: CollBuilder
    Definition Classes
    Coll
  4. abstract def exists(p: ((L, R)) => Boolean): Boolean

    Tests whether a predicate holds for at least one element of this collection.

    Tests whether a predicate holds for at least one element of this collection.

    p

    the predicate used to test elements.

    returns

    true if the given predicate p is satisfied by at least one element of this collection, otherwise false

    Definition Classes
    Coll
  5. abstract def filter(p: ((L, R)) => Boolean): Coll[(L, R)]

    Selects all elements of this collection which satisfy a predicate.

    Selects all elements of this collection which satisfy a predicate.

    p

    the predicate used to test elements.

    returns

    a new collection consisting of all elements of this collection that satisfy the given predicate p. The order of the elements is preserved.

    Definition Classes
    Coll
    Since

    2.0

  6. abstract def flatMap[B](f: ((L, R)) => Coll[B])(implicit arg0: RType[B]): Coll[B]

    Builds a new collection by applying a function to all elements of this collection and using the elements of the resulting collections.

    Builds a new collection by applying a function to all elements of this collection and using the elements of the resulting collections.

    Function f is constrained to be of the form x => x.someProperty, otherwise it is illegal.

    B

    the element type of the returned collection.

    f

    the function to apply to each element.

    returns

    a new collection of type Coll[B] resulting from applying the given collection-valued function f to each element of this collection and concatenating the results.

    Definition Classes
    Coll
    Since

    2.0

  7. abstract def foldLeft[B](zero: B, op: ((B, (L, R))) => B): B

    Applies a binary operator to a start value and all elements of this collection, going left to right.

    Applies a binary operator to a start value and all elements of this collection, going left to right.

    B

    the result type of the binary operator.

    zero

    the start value.

    op

    the binary operator.

    returns

    the result of inserting op between consecutive elements of this collection, going left to right with the start value z on the left:

    op(...op(z, x_1), x_2, ..., x_n)

    where x_1, ..., x_n are the elements of this collection. Returns z if this collection is empty.

    Definition Classes
    Coll
  8. abstract def forall(p: ((L, R)) => Boolean): Boolean

    Tests whether a predicate holds for all elements of this collection.

    Tests whether a predicate holds for all elements of this collection.

    p

    the predicate used to test elements.

    returns

    true if this collection is empty or the given predicate p holds for all elements of this collection, otherwise false.

    Definition Classes
    Coll
  9. abstract def getOrElse(index: Int, default: (L, R)): (L, R)

    The element of the collection or default value.

    The element of the collection or default value. If an index is out of bounds (i < 0 || i >= length) then default value is returned.

    returns

    the element at the given index or default value if index is out or bounds

    Definition Classes
    Coll
    Since

    2.0

  10. abstract def indexWhere(p: ((L, R)) => Boolean, from: Int): Int

    Finds index of the first element satisfying some predicate after or at some start index.

    Finds index of the first element satisfying some predicate after or at some start index.

    p

    the predicate used to test elements.

    from

    the start index

    returns

    the index >= from of the first element of this collection that satisfies the predicate p, or -1, if none exists.

    Definition Classes
    Coll
    Since

    2.0

  11. abstract def indices: Coll[Int]

    Produces the range of all indices of this collection as a new collection containing [0 ..

    Produces the range of all indices of this collection as a new collection containing [0 .. length-1] values.

    Definition Classes
    Coll
    Since

    2.0

  12. abstract def isDefinedAt(idx: Int): Boolean

    Tests whether this collection contains given index.

    Tests whether this collection contains given index.

    The implementations of methods apply and isDefinedAt turn a Coll[A] into a PartialFunction[Int, A].

    idx

    the index to test

    returns

    true if this collection contains an element at position idx, false otherwise.

    Definition Classes
    Coll
  13. abstract def isEmpty: Boolean

    Tests whether the collection is empty.

    Tests whether the collection is empty.

    returns

    true if the collection contains no elements, false otherwise.

    Definition Classes
    Coll
  14. abstract def lastIndexWhere(p: ((L, R)) => Boolean, end: Int): Int

    Finds index of last element satisfying some predicate before or at given end index.

    Finds index of last element satisfying some predicate before or at given end index.

    p

    the predicate used to test elements.

    returns

    the index <= end of the last element of this collection that satisfies the predicate p, or -1, if none exists.

    Definition Classes
    Coll
    Since

    2.0

  15. abstract def length: Int

    The length of the collection.

    The length of the collection.

    Definition Classes
    Coll
  16. abstract def ls: Coll[L]
  17. abstract def map[B](f: ((L, R)) => B)(implicit arg0: RType[B]): Coll[B]

    Builds a new collection by applying a function to all elements of this collection.

    Builds a new collection by applying a function to all elements of this collection.

    B

    the element type of the returned collection.

    f

    the function to apply to each element.

    returns

    a new collection of type Coll[B] resulting from applying the given function f to each element of this collection and collecting the results.

    Definition Classes
    Coll
  18. abstract def mapFirst[T1](f: (L) => T1)(implicit arg0: RType[T1]): Coll[(T1, R)]
  19. abstract def mapSecond[T1](f: (R) => T1)(implicit arg0: RType[T1]): Coll[(L, T1)]
  20. abstract def nonEmpty: Boolean

    Tests whether the collection is not empty.

    Tests whether the collection is not empty.

    returns

    true if the collection contains at least one element, false otherwise.

    Definition Classes
    Coll
  21. abstract def patch(from: Int, patch: Coll[(L, R)], replaced: Int): Coll[(L, R)]

    Produces a new collection where a slice of elements in this collection is replaced by another sequence.

    Produces a new collection where a slice of elements in this collection is replaced by another sequence.

    from

    the index of the first replaced element

    patch

    the replacement sequence

    replaced

    the number of elements to drop in the original collection

    returns

    a new collection consisting of all elements of this collection except that replaced elements starting from from are replaced by patch.

    Definition Classes
    Coll
    Since

    2.0

  22. abstract def reverse: Coll[(L, R)]

    Returns new collection with elements in reversed order.

    Returns new collection with elements in reversed order.

    returns

    A new collection with all elements of this collection in reversed order.

    Definition Classes
    Coll
  23. abstract def rs: Coll[R]
  24. abstract def segmentLength(p: ((L, R)) => Boolean, from: Int): Int

    Computes length of longest segment whose elements all satisfy some predicate.

    Computes length of longest segment whose elements all satisfy some predicate.

    p

    the predicate used to test elements.

    from

    the index where the search starts.

    returns

    the length of the longest segment of this collection starting from index from such that every element of the segment satisfies the predicate p.

    Definition Classes
    Coll
    Since

    2.0

  25. abstract def slice(from: Int, until: Int): Coll[(L, R)]

    Selects an interval of elements.

    Selects an interval of elements. The returned collection is made up of all elements x which satisfy the invariant:

    from <= indexOf(x) < until
    from

    the lowest index to include from this collection.

    until

    the lowest index to EXCLUDE from this collection.

    Definition Classes
    Coll
  26. implicit abstract def tItem: RType[(L, R)]
    Definition Classes
    Coll
  27. abstract def take(n: Int): Coll[(L, R)]

    Selects first n elements.

    Selects first n elements.

    n

    the number of elements to take from this collection.

    returns

    a collection consisting only of the first n elements of this collection, or else the whole collection, if it has less than n elements. If n is negative, returns an empty collection.

    Definition Classes
    Coll
  28. abstract def toArray: Array[(L, R)]
    Definition Classes
    Coll
  29. abstract def unionSet(that: Coll[(L, R)]): Coll[(L, R)]

    Produces a new collection which contains all distinct elements of this collection and also all elements of a given collection that are not in this collection.

    Produces a new collection which contains all distinct elements of this collection and also all elements of a given collection that are not in this collection. This is order preserving operation considering only first occurrences of each distinct elements. Any collection xs can be transformed to a sequence with distinct elements by using xs.unionSet(Col()).

    NOTE: Use append if you don't need set semantics.

    that

    the collection to add.

    Definition Classes
    Coll
    Since

    2.0

  30. abstract def updateMany(indexes: Coll[Int], values: Coll[(L, R)]): Coll[(L, R)]

    Returns a copy of this collection where elements at indexes are replaced with values.

    Returns a copy of this collection where elements at indexes are replaced with values.

    Definition Classes
    Coll
    Since

    2.0

  31. abstract def updated(index: Int, elem: (L, R)): Coll[(L, R)]

    A copy of this collection with one single replaced element.

    A copy of this collection with one single replaced element.

    index

    the position of the replacement

    elem

    the replacing element

    returns

    a new collection which is a copy of this collection with the element at position index replaced by elem.

    Definition Classes
    Coll
    Since

    2.0

    Exceptions thrown

    IndexOutOfBoundsException if index does not satisfy 0 <= index < length.

  32. abstract def zip[B](ys: Coll[B]): Coll[((L, R), B)]

    For this collection (x0, ..., xN) and other collection (y0, ..., yM) produces a collection ((x0, y0), ..., (xK, yK)) where K = min(N, M)

    For this collection (x0, ..., xN) and other collection (y0, ..., yM) produces a collection ((x0, y0), ..., (xK, yK)) where K = min(N, M)

    Definition Classes
    Coll

Concrete 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. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  6. def diff(that: Coll[(L, R)]): Coll[(L, R)]

    Computes the multiset difference between this collection and another sequence.

    Computes the multiset difference between this collection and another sequence.

    that

    the sequence of elements to remove

    returns

    a new collection which contains all elements of this collection except some of occurrences of elements that also appear in that. If an element value x appears n times in that, then the first n occurrences of x will not form part of the result, but any following occurrences will.

    Definition Classes
    Coll
    Since

    2.0

  7. def distinct: Coll[(L, R)]

    Builds a new collection from this collection without any duplicate elements.

    Builds a new collection from this collection without any duplicate elements.

    returns

    A new collection which contains the first occurrence of every element of this collection.

    Definition Classes
    Coll
  8. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  9. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  10. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  11. def find(p: ((L, R)) => Boolean): Option[(L, R)]

    Finds the first element of the collection satisfying a predicate, if any.

    Finds the first element of the collection satisfying a predicate, if any.

    p

    the predicate used to test elements.

    returns

    an option value containing the first element in the collection that satisfies p, or None if none exists.

    Definition Classes
    Coll
    Since

    2.0

  12. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  13. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  14. def indexOf(elem: (L, R), from: Int): Int

    Finds index of first occurrence of some value in this collection after or at some start index.

    Finds index of first occurrence of some value in this collection after or at some start index.

    elem

    the element value to search for.

    from

    the start index

    returns

    the index >= from of the first element of this collection that is equal (as determined by ==) to elem, or -1, if none exists.

    Definition Classes
    Coll
    Since

    2.0

  15. def intersect(that: Coll[(L, R)]): Coll[(L, R)]

    Computes the multiset intersection between this collection and another sequence.

    Computes the multiset intersection between this collection and another sequence.

    that

    the sequence of elements to intersect with.

    returns

    a new collection which contains all elements of this collection which also appear in that. If an element value x appears n times in that, then the first n occurrences of x will be retained in the result, but any following occurrences will be omitted.

    Definition Classes
    Coll
    Since

    2.0

  16. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  17. final def isValidIndex(i: Int): Boolean

    Returns true if the index in the valid range.

    Returns true if the index in the valid range.

    i

    index of an element of this collection

    Definition Classes
    Coll
  18. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  19. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  20. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  21. def size: Int

    The size of the collection in elements.

    The size of the collection in elements.

    Definition Classes
    Coll
  22. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  23. def toString(): String
    Definition Classes
    Coll → AnyRef → Any
  24. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  25. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  26. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()

Inherited from Coll[(L, R)]

Inherited from AnyRef

Inherited from Any

Ungrouped