aboutsummaryrefslogtreecommitdiff
path: root/xmpp/extensions
diff options
context:
space:
mode:
Diffstat (limited to 'xmpp/extensions')
-rw-r--r--xmpp/extensions/extensions.go18
1 files changed, 18 insertions, 0 deletions
diff --git a/xmpp/extensions/extensions.go b/xmpp/extensions/extensions.go
index fac5e7b..ce27656 100644
--- a/xmpp/extensions/extensions.go
+++ b/xmpp/extensions/extensions.go
@@ -111,6 +111,13 @@ type IqVcardDesc struct {
Text string `xml:",chardata"`
}
+// Reply is from XEP-0461
+type Reply struct {
+ XMLName xml.Name `xml:"urn:xmpp:reply:0 reply"`
+ To string `xml:"to,attr"`
+ Id string `xml:"id,attr"`
+}
+
// Namespace is a namespace!
func (c PresenceNickExtension) Namespace() string {
return c.XMLName.Space
@@ -131,6 +138,11 @@ func (c IqVcardTemp) GetSet() *stanza.ResultSet {
return c.ResultSet
}
+// Namespace is a namespace!
+func (c Reply) Namespace() string {
+ return c.XMLName.Space
+}
+
func init() {
// presence nick
stanza.TypeRegistry.MapExtension(stanza.PKTPresence, xml.Name{
@@ -149,4 +161,10 @@ func init() {
"vcard-temp",
"vCard",
}, IqVcardTemp{})
+
+ // reply
+ stanza.TypeRegistry.MapExtension(stanza.PKTMessage, xml.Name{
+ "urn:xmpp:reply:0",
+ "reply",
+ }, Reply{})
}