Packages

t

scala.collection

ExtSetMethods

trait ExtSetMethods[A] extends FilterableSet[A]

Self Type
ExtSetMethods[A] with Set[A]
Linear Supertypes
Type Hierarchy
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ExtSetMethods
  2. FilterableSet
  3. AnyRef
  4. Any
Implicitly
  1. by any2stringadd
  2. by StringFormat
  3. by Ensuring
  4. by ArrowAssoc
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Abstract Value Members

  1. abstract def draw(random: Random): A

    Returns a random element of the set if it is nonEmpty otherwise throws IllegalArgumentException.

    Returns a random element of the set if it is nonEmpty otherwise throws IllegalArgumentException. Note that currently a near- but no true-uniform distribution is granted to allow for O(1) implementation.

    random

    a random generator; it is essential that random be instantiated by the caller just once for any sequence of calls

  2. abstract def findElem[B](toMatch: B, correspond: (A, B) => Boolean): A

    Finds an entry in the collection based on toMatch's hashCode and a correspondence function but not on the argument type.

    Finds an entry in the collection based on toMatch's hashCode and a correspondence function but not on the argument type.

    toMatch

    a value not necessarily of type A; the entry to be searched for must have the same hashCode and be equal to this argument

    correspond

    function returning whether a given entry corresponds to other

    returns

    the entry corresponding to toMatch or null if not contained

Concrete Value Members

  1. def findElem(elem: A): Option[A]
  2. def withSetFilter(p: (A) => Boolean): immutable.Set[A] with FilterableSet[A]
    Definition Classes
    FilterableSet