diff options
author | Lance Stout <lancestout@gmail.com> | 2011-01-09 10:04:09 -0500 |
---|---|---|
committer | Lance Stout <lancestout@gmail.com> | 2011-01-09 10:04:09 -0500 |
commit | 23e499998fc36b377e3adb77d3d59f885d94f21d (patch) | |
tree | 3dcef998633c65ea320cd2acfdaadb394e4ee773 /sleekxmpp/plugins/xep_0092/stanza.py | |
parent | c156a4f723073e1e6394803b5bb1613227947266 (diff) | |
parent | acdf9e2d22dd604578f50d0a9b67c47e001da69f (diff) | |
download | slixmpp-23e499998fc36b377e3adb77d3d59f885d94f21d.tar.gz slixmpp-23e499998fc36b377e3adb77d3d59f885d94f21d.tar.bz2 slixmpp-23e499998fc36b377e3adb77d3d59f885d94f21d.tar.xz slixmpp-23e499998fc36b377e3adb77d3d59f885d94f21d.zip |
Merge branch 'develop' into roster
Diffstat (limited to 'sleekxmpp/plugins/xep_0092/stanza.py')
-rw-r--r-- | sleekxmpp/plugins/xep_0092/stanza.py | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/sleekxmpp/plugins/xep_0092/stanza.py b/sleekxmpp/plugins/xep_0092/stanza.py new file mode 100644 index 00000000..77654e37 --- /dev/null +++ b/sleekxmpp/plugins/xep_0092/stanza.py @@ -0,0 +1,42 @@ +""" + SleekXMPP: The Sleek XMPP Library + Copyright (C) 2010 Nathanael C. Fritz + This file is part of SleekXMPP. + + See the file LICENSE for copying permission. +""" + +from sleekxmpp.xmlstream import ElementBase, ET + + +class Version(ElementBase): + + """ + XMPP allows for an agent to advertise the name and version of the + underlying software libraries, as well as the operating system + that the agent is running on. + + Example version stanzas: + <iq type="get"> + <query xmlns="jabber:iq:version" /> + </iq> + + <iq type="result"> + <query xmlns="jabber:iq:version"> + <name>SleekXMPP</name> + <version>1.0</version> + <os>Linux</os> + </query> + </iq> + + Stanza Interface: + name -- The human readable name of the software. + version -- The specific version of the software. + os -- The name of the operating system running the program. + """ + + name = 'query' + namespace = 'jabber:iq:version' + plugin_attrib = 'software_version' + interfaces = set(('name', 'version', 'os')) + sub_interfaces = interfaces |