EventBroker.FilterAgent (Anoma v0.25.0)

I am a Filter Agent module.

I implement the base server behavior of the spawned filter agent. In general, I monitor subscribers of an individual filtering agent and send whichever events I receive to them.

Summary

Types

t()

I am the type of the Filter Agent.

Functions

Returns a specification to start this module under a supervisor.

Callback implementation for GenServer.init/1.

Types

@type t() :: %EventBroker.FilterAgent{spec: struct(), subscribers: MapSet.t(pid())}

I am the type of the Filter Agent.

I contain the minimal info for a filter to work, namely the filter specification to aplly to incoming messages and subscribers to send filtered messages to.

Fields

  • :spec - The filter specification. This is a structure of a module
          with a public filter API for the agent to call.
  • :subscribers - The list of subscribers to send filtered messages to.
                 Default: MapSet.new()

Functions

Link to this function

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

Link to this function

init(filter_params)

Callback implementation for GenServer.init/1.

Link to this function

start_link(filter_params)