3 -export([cast_one2all/2
8 % Cast all messages to one destination
9 cast_all2one(_, []) -> ok;
10 cast_all2one(Server, [Msg | Msgs]) ->
11 ok = gen_server:cast(Server, Msg),
12 cast_all2one(Server, Msgs).
15 % Cast one message to all destinations
16 cast_one2all([], _) -> ok;
17 cast_one2all([Server | Servers], Msg) ->
18 ok = gen_server:cast(Server, Msg),
19 cast_one2all(Servers, Msg).