smppex v0.1.1 SMPPEX.ESME behaviour

Summary

Types

request :: term
send_pdu_result :: :ok | {:error, term}
state :: term

Functions

call(esme, request, timeout \\ 5000)

Specs

call(pid, term, timeout) :: term
cast(esme, request)

Specs

cast(pid, term) :: :ok
handle_pdu(esme, pdu)

Specs

handle_pdu(pid, SMPPEX.Pdu.t) :: :ok
handle_send_pdu_result(esme, pdu, send_pdu_result)

Specs

handle_send_pdu_result(pid, SMPPEX.Pdu.t, send_pdu_result) :: :ok
handle_stop(esme)

Specs

handle_stop(pid) :: :ok
reply(esme, pdu, reply_pdu)

Specs

reply(pid, SMPPEX.Pdu.t, SMPPEX.Pdu.t) :: :ok
send_pdu(esme, pdu)

Specs

send_pdu(pid, SMPPEX.Pdu.t) :: :ok
start_link(host, port, arg, opts \\ [])

Specs

start_link(term, non_neg_integer, {module, term}, Keyword.t) :: GenServer.on_start
stop(esme)

Specs

stop(pid) :: :ok
with_session(esme, fun)

Specs

with_session(pid, (pid -> any)) :: :ok

Callbacks

handle_call(request, arg1, state)

Specs

handle_call(request, GenServer.from, state) ::
  {:reply, reply :: term, state} |
  {:noreply, state}
handle_cast(request, state)

Specs

handle_cast(request, state) :: state
handle_info(request, state)

Specs

handle_info(request, state) :: state
handle_pdu(arg0, state)

Specs

handle_pdu(SMPPEX.Pdu.t, state) :: state
handle_resp(arg0, arg1, state)

Specs

handle_resp(SMPPEX.Pdu.t, SMPPEX.Pdu.t, state) :: state
handle_resp_timeout(arg0, state)

Specs

handle_resp_timeout(SMPPEX.Pdu.t, state) :: state
handle_send_pdu_result(arg0, arg1, state)

Specs

handle_stop(state)

Specs

handle_stop(state) :: any
init(args)

Specs

init(args :: term) ::
  {:ok, state} |
  {:stop, reason :: term}