Cizen v0.10.0 Cizen.EventBodyFilter behaviour View Source

A behaviour module to define an event filter.

Link to this section Summary

Link to this section Types

Link to this section Functions

Link to this macro defeventbodyfilter(module, key) View Source (macro)

Defines a event body filter.

Example

defmodule SomeEvent do
  defstruct [:key, :value]
  import Cizen.EventBodyFilter
  defeventbodyfilter KeyFilter, :key
  defeventbodyfilter ValueFilter, :value do
    @moduledoc "Some document"
  end
end
Link to this macro defeventbodyfilter(module, key, list) View Source (macro)
Link to this function test(filter, event_body) View Source
test(Cizen.EventBodyFilter.t(), Cizen.EventBody.t()) :: boolean()

Link to this section Callbacks

Link to this callback test(t, arg1) View Source
test(t(), Cizen.EventBody.t()) :: boolean()