Package pyxmpp
[hide private]

Package pyxmpp

source code

PyXMPP is object-oriented, most of its fetures are implemented via classes, defined in various pyxmpp modules. The API is very asynchronous -- often requested objects are not returned immediately, but instead a callback is called when the object is available or an event occurs.

As python is not a strongly-typed language so the parameter and attribute types shown in this documentation are not enforced, but those types are expected by the package and others may simply not work or stop working in future releases of PyXMPP.

Module hierarchy

Base XMPP features (RFC 3920, RFC 3921) are implemented in direct submodules of pyxmpp package. Most JSF defined extensions are defined in pyxmpp.jabber package and modules for server components are placed in pyxmpp.jabberd.

For convenience most important names (classes for application use) may be imported into pyxmpp, pyxmpp.jabber or pyxmpp.jabberd packages. To do that pyxmpp.all, pyxmpp.jabber.all or pyxmpp.jabberd.all must be imported. One doesn't have to remember any other module name then.

Constructors

Most of PyXMPP object constructors are polymorphic. That means they accept different types and number of arguments to create object from various input. Usually the first argument may be an XML node to parse/wrap into the object or parameters needed to create a new object from scratch. E.g. pyxmpp.stanza.Stanza constructor accepts single libxml2.xmlNode argument with XML stanza or set of keyword arguments (from_jid, to_jid, stanza_type, etc.) to create such XML stanza. Most of the constructors will also accept instance of their own class to create a copy of it.

Common methods

Most objects describing elements of the XMPP protocol or its extensions have method as_xml() providing their XML representations.

Submodules [hide private]

Variables [hide private]
  __package__ = None
hash(x)

Imports: jabberd, jabber, jid