asobi_presence (asobi v0.35.4)

View Source

Summary

Functions

disconnect(PlayerId, Reason)

-spec disconnect(binary(), binary()) -> ok.

get_status(PlayerId)

-spec get_status(binary()) -> online | offline.

handle_call(Request, From, State)

-spec handle_call(term(), gen_server:from(), map()) -> {reply, term(), map()}.

handle_cast(Msg, State)

-spec handle_cast(term(), map()) -> {noreply, map()}.

handle_info(Info, State)

-spec handle_info(term(), map()) -> {noreply, map()}.

init(_)

-spec init([]) -> {ok, #{}}.

online_count()

-spec online_count() -> non_neg_integer().

revoke_session(PlayerId, Reason)

-spec revoke_session(binary(), binary()) -> ok.

send(PlayerId, Message)

-spec send(binary(), term()) -> ok.

start_link()

-spec start_link() -> gen_server:start_ret().

track(PlayerId, Pid)

-spec track(binary(), pid()) -> ok.

untrack(PlayerId)

-spec untrack(binary()) -> ok.

update(PlayerId, Status)

-spec update(binary(), map()) -> ok.