Unindent overview docs.
This commit is contained in:
parent
8bb5c81347
commit
541db6d37c
|
|
@ -2,11 +2,11 @@
|
|||
Package for implementing XMPP clients and components.
|
||||
|
||||
The package is built around the concept of an XML stream - a pair of XML
|
||||
documents written to and read from a TCP connection. Top-level elements in
|
||||
the document form the messages processed by either end of the connection.
|
||||
documents written to and read from a TCP connection. Top-level elements in the
|
||||
document form the messages processed by either end of the connection.
|
||||
|
||||
An XML stream is then configured for an XMPP conversation, as either a
|
||||
client (chat, etc) or component (a sort of server plugin).
|
||||
An XML stream is then configured for an XMPP conversation, as either a client
|
||||
(chat, etc) or component (a sort of server plugin).
|
||||
|
||||
Create a client:
|
||||
|
||||
|
|
@ -27,14 +27,14 @@
|
|||
|
||||
X.Out <- xmpp.Presence{}
|
||||
|
||||
Incoming messages are handled by consuming the XMPP instance's In channel.
|
||||
The channel is sent all XMPP stanzas as well as terminating error (io.EOF
|
||||
for clean shutdown or any other error for something unexpected). The
|
||||
channel is also closed after an error.
|
||||
Incoming messages are handled by consuming the XMPP instance's In channel. The
|
||||
channel is sent all XMPP stanzas as well as terminating error (io.EOF for clean
|
||||
shutdown or any other error for something unexpected). The channel is also
|
||||
closed after an error.
|
||||
|
||||
XMPP defines four types of stanza: <error/>, <iq/>, <message/> and
|
||||
<presence/> represented by Error, Iq, Message (shown below) and Presence
|
||||
structs respectively.
|
||||
XMPP defines four types of stanza: <error/>, <iq/>, <message/> and <presence/>
|
||||
represented by Error, Iq, Message (shown below) and Presence structs
|
||||
respectively.
|
||||
|
||||
for i := range X.In {
|
||||
switch v := i.(type) {
|
||||
|
|
@ -47,8 +47,8 @@
|
|||
}
|
||||
}
|
||||
|
||||
Note: A "bound" JID is negotatiated during XMPP setup and may be different
|
||||
to the JID passed to the New(Client|Component)XMPP() call. Always
|
||||
use the XMPP instance's JID attribute in any stanzas.
|
||||
Note: A "bound" JID is negotatiated during XMPP setup and may be different to
|
||||
the JID passed to the New(Client|Component)XMPP() call. Always use the XMPP
|
||||
instance's JID attribute in any stanzas.
|
||||
*/
|
||||
package xmpp
|
||||
|
|
|
|||
Loading…
Reference in New Issue