Petal.Worker (petal v0.2.0) View Source
Handles the bulk of the Bloom filter operations.
The general gist is to hash the payload, then modulo the number against the number of bits in the filter, then set that bit.
Link to this section Summary
Functions
Add an item
to the filter.
Check for the existance of item
in the filter.
Returns a specification to start this module under a supervisor.
Callback implementation for GenServer.init/1
.
Inspect the current bloom filter contents.
Link to this section Functions
Specs
add(item :: String.t()) :: :ok
Add an item
to the filter.
Specs
Check for the existance of item
in the filter.
Returns a specification to start this module under a supervisor.
See Supervisor
.
Callback implementation for GenServer.init/1
.
Specs
inspect() :: String.t()
Inspect the current bloom filter contents.