summaryrefslogtreecommitdiff
path: root/slixmpp/plugins/xep_0332
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2020-12-10 19:20:23 +0100
committermathieui <mathieui@mathieui.net>2020-12-10 19:22:40 +0100
commit95d40a3ca336a4e1b66c7ed287ec3f2ef92b201c (patch)
treeef3086be7313a8e61e51b7a3efed302d0e154cb0 /slixmpp/plugins/xep_0332
parent010bf6dd70a44d9e9087336bc955a591ab9248b3 (diff)
downloadslixmpp-95d40a3ca336a4e1b66c7ed287ec3f2ef92b201c.tar.gz
slixmpp-95d40a3ca336a4e1b66c7ed287ec3f2ef92b201c.tar.bz2
slixmpp-95d40a3ca336a4e1b66c7ed287ec3f2ef92b201c.tar.xz
slixmpp-95d40a3ca336a4e1b66c7ed287ec3f2ef92b201c.zip
docs: update docstrings for sphinx conformity
Remove most references to timeout/callback/ifrom/timeout_callbacks args
Diffstat (limited to 'slixmpp/plugins/xep_0332')
-rw-r--r--slixmpp/plugins/xep_0332/stanza/request.py52
-rw-r--r--slixmpp/plugins/xep_0332/stanza/response.py44
2 files changed, 50 insertions, 46 deletions
diff --git a/slixmpp/plugins/xep_0332/stanza/request.py b/slixmpp/plugins/xep_0332/stanza/request.py
index 1d4aa5b1..670e27b1 100644
--- a/slixmpp/plugins/xep_0332/stanza/request.py
+++ b/slixmpp/plugins/xep_0332/stanza/request.py
@@ -19,32 +19,34 @@ class HTTPRequest(ElementBase):
element to the server. Each `iq` stanza sent is of type `set`.
Examples:
- <iq type='set' from='a@b.com/browser' to='x@y.com' id='1'>
- <req xmlns='urn:xmpp:http'
- method='GET'
- resource='/api/users'
- version='1.1'>
- <headers xmlns='http://jabber.org/protocol/shim'>
- <header name='Host'>b.com</header>
- </headers>
- </req>
- </iq>
+ ::
- <iq type='set' from='a@b.com/browser' to='x@y.com' id='2'>
- <req xmlns='urn:xmpp:http'
- method='PUT'
- resource='/api/users'
- version='1.1'>
- <headers xmlns='http://jabber.org/protocol/shim'>
- <header name='Host'>b.com</header>
- <header name='Content-Type'>text/html</header>
- <header name='Content-Length'>...</header>
- </headers>
- <data>
- <text>...</text>
- </data>
- </req>
- </iq>
+ <iq type='set' from='a@b.com/browser' to='x@y.com' id='1'>
+ <req xmlns='urn:xmpp:http'
+ method='GET'
+ resource='/api/users'
+ version='1.1'>
+ <headers xmlns='http://jabber.org/protocol/shim'>
+ <header name='Host'>b.com</header>
+ </headers>
+ </req>
+ </iq>
+
+ <iq type='set' from='a@b.com/browser' to='x@y.com' id='2'>
+ <req xmlns='urn:xmpp:http'
+ method='PUT'
+ resource='/api/users'
+ version='1.1'>
+ <headers xmlns='http://jabber.org/protocol/shim'>
+ <header name='Host'>b.com</header>
+ <header name='Content-Type'>text/html</header>
+ <header name='Content-Length'>...</header>
+ </headers>
+ <data>
+ <text>...</text>
+ </data>
+ </req>
+ </iq>
"""
name = 'request'
diff --git a/slixmpp/plugins/xep_0332/stanza/response.py b/slixmpp/plugins/xep_0332/stanza/response.py
index 8f58f0c2..a25aa780 100644
--- a/slixmpp/plugins/xep_0332/stanza/response.py
+++ b/slixmpp/plugins/xep_0332/stanza/response.py
@@ -21,27 +21,29 @@ class HTTPResponse(ElementBase):
in which the original requests were made.
Examples:
- <iq type='result'
- from='httpserver@clayster.com'
- to='httpclient@clayster.com/browser' id='2'>
- <resp xmlns='urn:xmpp:http'
- version='1.1'
- statusCode='200'
- statusMessage='OK'>
- <headers xmlns='http://jabber.org/protocol/shim'>
- <header name='Date'>Fri, 03 May 2013 16:39:54GMT-4</header>
- <header name='Server'>Clayster</header>
- <header name='Content-Type'>text/turtle</header>
- <header name='Content-Length'>...</header>
- <header name='Connection'>Close</header>
- </headers>
- <data>
- <text>
- ...
- </text>
- </data>
- </resp>
- </iq>
+ ::
+
+ <iq type='result'
+ from='httpserver@clayster.com'
+ to='httpclient@clayster.com/browser' id='2'>
+ <resp xmlns='urn:xmpp:http'
+ version='1.1'
+ statusCode='200'
+ statusMessage='OK'>
+ <headers xmlns='http://jabber.org/protocol/shim'>
+ <header name='Date'>Fri, 03 May 2013 16:39:54GMT-4</header>
+ <header name='Server'>Clayster</header>
+ <header name='Content-Type'>text/turtle</header>
+ <header name='Content-Length'>...</header>
+ <header name='Connection'>Close</header>
+ </headers>
+ <data>
+ <text>
+ ...
+ </text>
+ </data>
+ </resp>
+ </iq>
"""
name = 'response'