Packages

final case class BloomFilter[A](numHashes: Int, width: Int)(implicit hash: Hash128[A]) extends Product with Serializable

Bloom Filter - a probabilistic data structure to test presence of an element.

Operations 1) insert: hash the value k times, updating the bitfield at the index equal to each hashed value 2) query: hash the value k times. If there are k collisions, then return true; otherwise false.

http://en.wikipedia.org/wiki/Bloom_filter

Self Type
BloomFilter[A]
Linear Supertypes
Serializable, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. BloomFilter
  2. Serializable
  3. Product
  4. Equals
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new BloomFilter(numHashes: Int, width: Int)(implicit hash: Hash128[A])

Type Members

  1. sealed abstract class Hash extends Serializable

    Bloom Filter data structure

  2. case class Instance(bits: BitSet) extends Hash with Product with Serializable
  3. case class Item(item: A) extends Hash with Product with Serializable

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. val aggregator: MonoidAggregator[A, Hash, Hash]
  5. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  6. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  7. def create(data: Iterator[A]): Hash

    Create a bloom filter with multiple items from an iterator

  8. def create(data: A*): Hash

    Create a bloom filter with multiple items.

  9. def create(item: A): Hash

    Create a bloom filter with one item.

  10. val empty: Hash
  11. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. implicit val equiv: Equiv[Hash]
  13. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  14. def fromBitSet(bitSet: BitSet): Try[Hash]

    Attempts to create a new BloomFilter instance from a BitSet.

    Attempts to create a new BloomFilter instance from a BitSet. Failure might occur if the BitSet has a maximum entry behond the BloomFilter expected size.

    This method will be helpfull on BloomFilter desirialization. Serialization is achieved through the serialization of the underlying BitSet.

  15. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  16. implicit val hash: Hash128[A]
  17. def hashToArray(s: A): Array[Int]

    Hash the value numHashes times and return an array of indices of true bits in the BitSet.

  18. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  19. implicit val monoid: Monoid[Hash] with BoundedSemilattice[Hash]
  20. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  21. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  22. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  23. val numHashes: Int
  24. def productElementNames: Iterator[String]
    Definition Classes
    Product
  25. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  26. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  27. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  28. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  29. val width: Int
  30. case object Empty extends Hash with Product with Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped