Options
All
  • Public
  • Public/Protected
  • All
Menu

A cell is an internal datastructure of an InvertibleBloomFilter. It is composed of an idSum (the XOR of all element inserted in that cell), a hashSum (the XOR of all hashed element in that cell) and a counter (the number of elements inserted in that cell).

author

Arnaud Grall

author

Thomas Minier

Hierarchy

Index

Methods

  • [inspect](): string
  • equals(cell: Cell): boolean
  • Test if another Cell is equals to this one

    Parameters

    • cell: Cell

      The cell to compare with

    Returns boolean

    True if the two Cells are equals, False otherwise

  • fromJSON(json: JSON): any
  • Load an Object from a provided JSON object

    Parameters

    • json: JSON

      the JSON object to load

    Returns any

    Return the Object loaded from the provided JSON object

  • isEmpty(): boolean
  • Test if the Cell is empty

    Returns boolean

    True if the Cell is empty, False otherwise

  • isPure(): boolean
  • Test if the cell is "Pure". A pure cell is a cell with a counter equal to 1 or -1, and with a hash sum equal to the id sum

    Returns boolean

    True if the cell ius pure, False otherwise

  • nextInt32(): number
  • saveAsJSON(): any
  • Perform the XOR operation between this Cell and another one and returns a resulting Cell. A XOR between two cells is the XOR between their id sum and hash sum, and the difference between their count.

    Parameters

    • cell: Cell

      Cell to perform XOR with

    Returns Cell

    A new Cell, resulting from the XOR operation

Properties

_count: number
_hashSum: <internal>.Buffer
_hashing: Hashing
_rng: PRNG
_seed: number

Constructors

Accessors

  • get count(): number
  • Get a function used to draw random number

    Returns PRNG

    A factory function used to draw random integer

  • get seed(): number
  • set seed(seed: number): void
  • Get the seed used in this structure

    Returns number

  • Set the seed for this structure

    Parameters

    • seed: number

      the new seed that will be used in this structure

    Returns void

Generated using TypeDoc