1AnyEvent::XMPP::NamespaUcseesr(3C)ontributed Perl DocumeAnntyaEtvieonnt::XMPP::Namespaces(3)
2
3
4
6 AnyEvent::XMPP::Namespaces - XMPP namespace collection and aliasing
7 class
8
10 use AnyEvent::XMPP::Namespaces qw/xmpp_ns set_xmpp_ns_alias/;
11
12 set_xmpp_ns_alias (stanzas => 'urn:ietf:params:xml:ns:xmpp-stanzas');
13
15 This module represents a simple namespaces aliasing mechanism to ease
16 handling of namespaces when traversing AnyEvent::XMPP::Node objects and
17 writing XML with AnyEvent::XMPP::Writer.
18
20 There are already some aliases defined for the XMPP XML namespaces
21 which make handling of namepsaces a bit easier:
22
23 stream => http://etherx.jabber.org/streams
24 xml => http://www.w3.org/XML/1998/namespace
25
26 streams => urn:ietf:params:xml:ns:xmpp-streams
27 session => urn:ietf:params:xml:ns:xmpp-session
28 stanzas => urn:ietf:params:xml:ns:xmpp-stanzas
29 sasl => urn:ietf:params:xml:ns:xmpp-sasl
30 bind => urn:ietf:params:xml:ns:xmpp-bind
31 tls => urn:ietf:params:xml:ns:xmpp-tls
32
33 client => jabber:client
34 roster => jabber:iq:roster
35 version => jabber:iq:version
36 auth => jabber:iq:auth
37
38 iq_oob => jabber:iq:oob
39 x_oob => jabber:x:oob
40
41 disco_info => http://jabber.org/protocol/disco#info
42 disco_items => http://jabber.org/protocol/disco#items
43
44 register => http://jabber.org/features/iq-register
45 iqauth => http://jabber.org/features/iq-auth
46 data_form => jabber:x:data
47
48 ping => urn:xmpp:ping
49
50 vcard => vcard-temp
51
52 pubsub => http://jabber.org/protocol/pubsub
53 pubsub_own => http://jabber.org/protocol/pubsub#owner
54 pubsub_ev => http://jabber.org/protocol/pubsub#event
55
57 xmpp_ns ($alias)
58 Returns am uri for the registered $alias or undef if none exists.
59
60 xmpp_ns_maybe ($alias_or_namespace_uri)
61 This method tries to find whether there is a alias
62 $alias_or_namespace_uri registered and if not it returns
63 $alias_or_namespace_uri.
64
65 set_xmpp_ns_alias ($alias, $namespace_uri)
66 Sets an $alias for the $namespace_uri.
67
69 Robin Redeker, "<elmex at ta-sa.org>", JID: "<elmex at jabber.org>"
70
72 Copyright 2007, 2008 Robin Redeker, all rights reserved.
73
74 This program is free software; you can redistribute it and/or modify it
75 under the same terms as Perl itself.
76
77
78
79perl v5.28.1 2012-12-25 AnyEvent::XMPP::Namespaces(3)