envio v0.7.0 Envio.IOBackend.Handler View Source

Link to this section Summary

Functions

Returns a specification to start this module under a supervisor.

Default implementation of the callback invoked when the message is received.

Helper generated by the Envio.Subscriber scaffold. This pub_sub GenServer might be started by invoking Elixir.Envio.IOBackend.Handler.start_link.

Subscribes to the channel(s) given in a runtime.

Link to this section Functions

Returns a specification to start this module under a supervisor.

See Supervisor.

Link to this function

handle_envio(message, state)

View Source

Default implementation of the callback invoked when the message is received.

Link to this function

start_link(opts \\ [])

View Source
start_link(list()) ::
  {:ok, pid()} | :ignore | {:error, {:already_started, pid()} | term()}

Helper generated by the Envio.Subscriber scaffold. This pub_sub GenServer might be started by invoking Elixir.Envio.IOBackend.Handler.start_link.

Link to this function

subscribe(channel)

View Source
subscribe(
  channel ::
    %Envio.Channel{name: term(), source: term()}
    | [%Envio.Channel{name: term(), source: term()}]
) ::
  {:ok, %Envio.State{messages: term(), options: term(), subscriptions: term()}}

Subscribes to the channel(s) given in a runtime.