Adjusted structures to support multiple XMPP error types.
Updated documentation in some places.