mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-24 16:23:40 +01:00
exmpp in pubsub doc and retrocompatibility comments (thanks to Karim Gemayel)
SVN Revision: 2934
This commit is contained in:
parent
e4a6d20328
commit
887a65aa18
@ -120,6 +120,7 @@ process_iq_reply(From, To, #iq{id = ID} = IQ) ->
|
|||||||
nothing
|
nothing
|
||||||
end.
|
end.
|
||||||
|
|
||||||
|
%% #xmlelement{} used for retro-compatibility
|
||||||
route(FromOld, ToOld, #xmlelement{} = PacketOld) ->
|
route(FromOld, ToOld, #xmlelement{} = PacketOld) ->
|
||||||
catch throw(for_stacktrace), % To have a stacktrace.
|
catch throw(for_stacktrace), % To have a stacktrace.
|
||||||
io:format("~nLOCAL: old #xmlelement:~n~p~n~p~n~n",
|
io:format("~nLOCAL: old #xmlelement:~n~p~n~p~n~n",
|
||||||
@ -232,6 +233,8 @@ handle_cast(_Msg, State) ->
|
|||||||
%% {stop, Reason, State}
|
%% {stop, Reason, State}
|
||||||
%% Description: Handling all non call/cast messages
|
%% Description: Handling all non call/cast messages
|
||||||
%%--------------------------------------------------------------------
|
%%--------------------------------------------------------------------
|
||||||
|
|
||||||
|
%% #xmlelement{} used for retro-compatibility
|
||||||
handle_info({route, FromOld, ToOld, #xmlelement{} = PacketOld}, State) ->
|
handle_info({route, FromOld, ToOld, #xmlelement{} = PacketOld}, State) ->
|
||||||
catch throw(for_stacktrace), % To have a stacktrace.
|
catch throw(for_stacktrace), % To have a stacktrace.
|
||||||
io:format("~nLOCAL: old #xmlelement:~n~p~n~p~n~n",
|
io:format("~nLOCAL: old #xmlelement:~n~p~n~p~n~n",
|
||||||
|
@ -63,7 +63,7 @@
|
|||||||
start_link() ->
|
start_link() ->
|
||||||
gen_server:start_link({local, ?MODULE}, ?MODULE, [], []).
|
gen_server:start_link({local, ?MODULE}, ?MODULE, [], []).
|
||||||
|
|
||||||
|
%% #xmlelement{} used for retro-compatibility
|
||||||
route(FromOld, ToOld, #xmlelement{} = PacketOld) ->
|
route(FromOld, ToOld, #xmlelement{} = PacketOld) ->
|
||||||
catch throw(for_stacktrace), % To have a stacktrace.
|
catch throw(for_stacktrace), % To have a stacktrace.
|
||||||
io:format("~nROUTER: old #xmlelement:~n~p~n~p~n~n",
|
io:format("~nROUTER: old #xmlelement:~n~p~n~p~n~n",
|
||||||
@ -255,6 +255,7 @@ handle_cast(_Msg, State) ->
|
|||||||
%% {stop, Reason, State}
|
%% {stop, Reason, State}
|
||||||
%% Description: Handling all non call/cast messages
|
%% Description: Handling all non call/cast messages
|
||||||
%%--------------------------------------------------------------------
|
%%--------------------------------------------------------------------
|
||||||
|
%% #xmlelement{} used for retro-compatibility
|
||||||
handle_info({route, FromOld, ToOld, #xmlelement{} = PacketOld}, State) ->
|
handle_info({route, FromOld, ToOld, #xmlelement{} = PacketOld}, State) ->
|
||||||
catch throw(for_stacktrace), % To have a stacktrace.
|
catch throw(for_stacktrace), % To have a stacktrace.
|
||||||
io:format("~nROUTER: old #xmlelement:~n~p~n~p~n~n",
|
io:format("~nROUTER: old #xmlelement:~n~p~n~p~n~n",
|
||||||
|
@ -77,6 +77,7 @@
|
|||||||
start_link() ->
|
start_link() ->
|
||||||
gen_server:start_link({local, ?MODULE}, ?MODULE, [], []).
|
gen_server:start_link({local, ?MODULE}, ?MODULE, [], []).
|
||||||
|
|
||||||
|
%% #xmlelement{} used for retro-compatibility
|
||||||
route(FromOld, ToOld, #xmlelement{} = PacketOld) ->
|
route(FromOld, ToOld, #xmlelement{} = PacketOld) ->
|
||||||
catch throw(for_stacktrace), % To have a stacktrace.
|
catch throw(for_stacktrace), % To have a stacktrace.
|
||||||
io:format("~nS2S: old #xmlelement:~n~p~n~p~n~n",
|
io:format("~nS2S: old #xmlelement:~n~p~n~p~n~n",
|
||||||
@ -219,6 +220,7 @@ handle_cast(_Msg, State) ->
|
|||||||
handle_info({mnesia_system_event, {mnesia_down, Node}}, State) ->
|
handle_info({mnesia_system_event, {mnesia_down, Node}}, State) ->
|
||||||
clean_table_from_bad_node(Node),
|
clean_table_from_bad_node(Node),
|
||||||
{noreply, State};
|
{noreply, State};
|
||||||
|
%% #xmlelement{} used for retro-compatibility
|
||||||
handle_info({route, FromOld, ToOld, #xmlelement{} = PacketOld}, State) ->
|
handle_info({route, FromOld, ToOld, #xmlelement{} = PacketOld}, State) ->
|
||||||
catch throw(for_stacktrace), % To have a stacktrace.
|
catch throw(for_stacktrace), % To have a stacktrace.
|
||||||
io:format("~nS2S: old #xmlelement:~n~p~n~p~n~n",
|
io:format("~nS2S: old #xmlelement:~n~p~n~p~n~n",
|
||||||
|
@ -91,7 +91,7 @@
|
|||||||
%%--------------------------------------------------------------------
|
%%--------------------------------------------------------------------
|
||||||
start_link() ->
|
start_link() ->
|
||||||
gen_server:start_link({local, ?MODULE}, ?MODULE, [], []).
|
gen_server:start_link({local, ?MODULE}, ?MODULE, [], []).
|
||||||
|
%% #xmlelement{} used for retro-compatibility
|
||||||
route(FromOld, ToOld, #xmlelement{} = PacketOld) ->
|
route(FromOld, ToOld, #xmlelement{} = PacketOld) ->
|
||||||
catch throw(for_stacktrace), % To have a stacktrace.
|
catch throw(for_stacktrace), % To have a stacktrace.
|
||||||
io:format("~nSM: old #xmlelement:~n~p~n~p~n~n",
|
io:format("~nSM: old #xmlelement:~n~p~n~p~n~n",
|
||||||
@ -343,6 +343,7 @@ handle_cast(_Msg, State) ->
|
|||||||
%% {stop, Reason, State}
|
%% {stop, Reason, State}
|
||||||
%% Description: Handling all non call/cast messages
|
%% Description: Handling all non call/cast messages
|
||||||
%%--------------------------------------------------------------------
|
%%--------------------------------------------------------------------
|
||||||
|
%% #xmlelement{} used for retro-compatibility
|
||||||
handle_info({route, FromOld, ToOld, #xmlelement{} = PacketOld}, State) ->
|
handle_info({route, FromOld, ToOld, #xmlelement{} = PacketOld}, State) ->
|
||||||
catch throw(for_stacktrace), % To have a stacktrace.
|
catch throw(for_stacktrace), % To have a stacktrace.
|
||||||
io:format("~nSM: old #xmlelement:~n~p~n~p~n~n",
|
io:format("~nSM: old #xmlelement:~n~p~n~p~n~n",
|
||||||
|
@ -44,18 +44,34 @@
|
|||||||
%%% of the current node. For example:
|
%%% of the current node. For example:
|
||||||
%%% ```["home", "localhost", "cromain", "node1"]'''</p>
|
%%% ```["home", "localhost", "cromain", "node1"]'''</p>
|
||||||
|
|
||||||
%%% @type stanzaError() = #xmlelement{}.
|
%%% @type stanzaError() = #xmlel{}.
|
||||||
%%% Example:
|
%%% Example:
|
||||||
%%% ```{xmlelement, "error",
|
%%% ```#xmlel{name = 'error'
|
||||||
%%% [{"code", Code}, {"type", Type}],
|
%%% ns = ?NS_STANZAS,
|
||||||
%%% [{xmlelement, Condition, [{"xmlns", ?NS_STANZAS}], []}]}'''
|
%%% attrs = [
|
||||||
|
%%% #xmlattr{
|
||||||
|
%%% name = 'code',
|
||||||
|
%%% ns = ?NS_STANZAS,
|
||||||
|
%%% value = Code
|
||||||
|
%%% },
|
||||||
|
%%% attrs = [
|
||||||
|
%%% #xmlattr{
|
||||||
|
%%% name = 'type',
|
||||||
|
%%% ns = ?NS_STANZAS,
|
||||||
|
%%% value = Type
|
||||||
|
%%% }
|
||||||
|
%%% ]}'''
|
||||||
|
|
||||||
%%% @type pubsubIQResponse() = #xmlelement{}.
|
%%% @type pubsubIQResponse() = #xmlel{}.
|
||||||
%%% Example:
|
%%% Example:
|
||||||
%%% ```{xmlelement, "pubsub",
|
%%% ```#xmlel{name = 'pubsub',
|
||||||
%%% [{"xmlns", ?NS_PUBSUB_EVENT}],
|
%%% ns = ?NS_PUBSUB,
|
||||||
%%% [{xmlelement, "affiliations", [],
|
%%% children = [
|
||||||
%%% []}]}'''
|
%%% #xmlel{name = 'affiliations'
|
||||||
|
%%% ns = ?NS_PUBSUB
|
||||||
|
%%% }
|
||||||
|
%%% ]
|
||||||
|
%%% }'''
|
||||||
|
|
||||||
%%% @type nodeOption() = {Option::atom(), Value::term()}.
|
%%% @type nodeOption() = {Option::atom(), Value::term()}.
|
||||||
%%% Example:
|
%%% Example:
|
||||||
|
Loading…
Reference in New Issue
Block a user