summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/mattn/go-xmpp/xmpp_subscription.go
diff options
context:
space:
mode:
authorWim <wim@42.be>2016-07-13 21:04:28 +0200
committerWim <wim@42.be>2016-08-14 22:40:25 +0200
commit46faad8b57c7c02e2ec158fe7462f751ba63c3be (patch)
tree277ab2e74b4b95cef8b93550994c627a110dfcf1 /vendor/github.com/mattn/go-xmpp/xmpp_subscription.go
parent30f30364d587994d40fc1b8eaae4d2404a4329ad (diff)
downloadmatterbridge-msglm-46faad8b57c7c02e2ec158fe7462f751ba63c3be.tar.gz
matterbridge-msglm-46faad8b57c7c02e2ec158fe7462f751ba63c3be.tar.bz2
matterbridge-msglm-46faad8b57c7c02e2ec158fe7462f751ba63c3be.zip
Vendor go-xmpp
Diffstat (limited to 'vendor/github.com/mattn/go-xmpp/xmpp_subscription.go')
-rw-r--r--vendor/github.com/mattn/go-xmpp/xmpp_subscription.go20
1 files changed, 20 insertions, 0 deletions
diff --git a/vendor/github.com/mattn/go-xmpp/xmpp_subscription.go b/vendor/github.com/mattn/go-xmpp/xmpp_subscription.go
new file mode 100644
index 00000000..eb293141
--- /dev/null
+++ b/vendor/github.com/mattn/go-xmpp/xmpp_subscription.go
@@ -0,0 +1,20 @@
+package xmpp
+
+import (
+ "fmt"
+)
+
+func (c *Client) ApproveSubscription(jid string) {
+ fmt.Fprintf(c.conn, "<presence to='%s' type='subscribed'/>",
+ xmlEscape(jid))
+}
+
+func (c *Client) RevokeSubscription(jid string) {
+ fmt.Fprintf(c.conn, "<presence to='%s' type='unsubscribed'/>",
+ xmlEscape(jid))
+}
+
+func (c *Client) RequestSubscription(jid string) {
+ fmt.Fprintf(c.conn, "<presence to='%s' type='subscribe'/>",
+ xmlEscape(jid))
+}