This repository has been archived on 2020-09-27. You can view files and clone it, but cannot push or open issues or pull requests.
2017-12-14 21:30:07 +01:00
|
|
|
package messages
|
|
|
|
|
|
|
|
import "encoding/xml"
|
|
|
|
|
|
|
|
type IQType string
|
|
|
|
|
|
|
|
const (
|
|
|
|
IQTypeGet IQType = "get"
|
|
|
|
IQTypeSet IQType = "set"
|
|
|
|
IQTypeResult IQType = "result"
|
|
|
|
IQTypeError IQType = "error"
|
|
|
|
)
|
|
|
|
|
|
|
|
// IQ element - info/query
|
2018-02-07 19:32:11 +01:00
|
|
|
type IQClient struct {
|
|
|
|
XMLName xml.Name `xml:"jabber:client iq"`
|
|
|
|
From string `xml:"from,attr"`
|
|
|
|
ID string `xml:"id,attr"`
|
|
|
|
To string `xml:"to,attr"`
|
|
|
|
Type IQType `xml:"type,attr"`
|
|
|
|
Error *ErrorClient `xml:"error"`
|
|
|
|
Bind Bind `xml:"bind"`
|
|
|
|
Body []byte `xml:",innerxml"`
|
2017-12-14 21:30:07 +01:00
|
|
|
// RosterRequest - better detection of iq's
|
|
|
|
}
|