Skip to content

Commit d36af71

Browse files
committed
docs.
1 parent 26e3c3a commit d36af71

File tree

12 files changed

+59
-39
lines changed

12 files changed

+59
-39
lines changed

doc/source/reference/auxproc.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
Auxiliary Processors
55
====================
66

7+
.. automodule:: spyne.auxproc
8+
79
AuxProcBase
810
-----------
911

doc/source/reference/interface.rst

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,19 @@ Interfaces
55
The `spyne.interface` package contains the implementations of various schema
66
definition standards.
77

8-
Interface Base Class
8+
Interface Class
99
--------------------
1010

11-
.. automodule:: spyne.interface._base
11+
.. autoclass:: spyne.interface.Interface
1212
:members:
13-
:inherited-members:
13+
:show-inheritance:
14+
15+
Interface Document Base Class
16+
-----------------------------
17+
18+
.. autoclass:: spyne.interface.InterfaceDocumentBase
19+
:members:
20+
:show-inheritance:
1421

1522
XML Schema
1623
----------

doc/source/reference/protocol/http.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ Http
77
.. automodule:: spyne.protocol.http
88
:members:
99
:show-inheritance:
10+
:undoc-members:

doc/source/reference/protocol/soap.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,5 @@ Soap 1.1
77
.. automodule:: spyne.protocol.soap.soap11
88
:members:
99
:show-inheritance:
10+
:undoc-members:
11+

spyne/interface/_base.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,6 @@
1717
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
1818
#
1919

20-
21-
"""This module contains the Interface and InterfaceDocumentBase class and its
22-
helper objects."""
23-
2420
import logging
2521
logger = logging.getLogger(__name__)
2622

@@ -38,7 +34,11 @@
3834

3935

4036
class Interface(object):
41-
"""The base class for all interface document generators."""
37+
"""The ``Interface`` class holds all information needed to build an
38+
interface document.
39+
40+
:param app: A :class:`spyne.application.Application` instance.
41+
"""
4242

4343
def __init__(self, app=None, import_base_namespaces=False):
4444
self.__ns_counter = 0

spyne/interface/wsdl/wsdl11.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,14 +124,16 @@ def _add_callbacks(service, root, types, service_name, url):
124124
return cb_port_type
125125

126126
class Wsdl11(XmlSchema):
127-
"""The implementation of the Wsdl 1.1 interface definition document standard.
127+
"""The implementation of the Wsdl 1.1 interface definition document
128+
standard which is avaible here: http://www.w3.org/TR/wsdl
128129
129130
:param app: The parent application.
130-
:param import_base_namespaces: Include imports for base namespaces like
131-
xsd, xsi, wsdl, etc.
132131
:param _with_partnerlink: Include the partnerLink tag in the wsdl.
133132
"""
134133

134+
#:param import_base_namespaces: Include imports for base namespaces like
135+
# xsd, xsi, wsdl, etc.
136+
135137
def __init__(self, interface=None, _with_partnerlink=False):
136138
XmlSchema.__init__(self, interface)
137139

spyne/protocol/_base.py

Lines changed: 8 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,7 @@
3434
from spyne.error import ResourceNotFoundError
3535
from spyne.error import RequestTooLongError
3636
from spyne.error import RequestNotAllowed
37-
from spyne.error import ValidationError
3837

39-
from spyne.model.binary import File
40-
from spyne.model.binary import ByteArray
4138
from spyne.model.complex import ComplexModelBase
4239

4340

@@ -93,16 +90,16 @@ class ProtocolBase(object):
9390
9491
The arguments the constructor takes are as follows:
9592
96-
:param app: The application this protocol belongs to.
97-
:param validator: The type of validation this protocol should do on
98-
incoming data.
99-
:param mime_type: The mime_type this protocol should set for transports
100-
that support this. This is a quick way to override the mime_type by
101-
default instead of subclassing the releavant protocol implementation.
102-
:param skip_depth: Number of wrapper classes to ignore. This is
93+
:param app: The application this protocol belongs to.
94+
:param validator: The type of validation this protocol should do on
95+
incoming data.
96+
:param mime_type: The mime_type this protocol should set for transports
97+
that support this. This is a quick way to override the mime_type by
98+
default instead of subclassing the releavant protocol implementation.
99+
:param skip_depth: Number of wrapper classes to ignore. This is
103100
typically one of (0, 1, 2) but higher numbers may also work for your
104101
case.
105-
"""
102+
"""
106103

107104
allowed_http_verbs = None
108105
mime_type = 'application/octet-stream'
@@ -124,10 +121,6 @@ def __init__(self, app=None, validator=None, mime_type=None, skip_depth=0):
124121

125122
@property
126123
def app(self):
127-
"""The :class:`spyne.application.Application` instance this protocol
128-
belongs to.
129-
"""
130-
131124
return self.__app
132125

133126
def set_app(self, value):

spyne/protocol/json/__init__.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
#
1919

2020
"""The ``spyne.protocol.json`` package contains the Json-related protocols.
21-
Currently, only :class:spyne.protocol.json.JsonObject is supported.
21+
Currently, only :class:`spyne.protocol.json.JsonObject` is supported.
2222
2323
Initially released in 2.8.0-rc.
2424
@@ -63,14 +63,14 @@
6363

6464

6565
class JsonObject(DictObject):
66-
"""An implementation of the json protocol that uses simplejson or json
67-
packages.
66+
"""An implementation of the json protocol that uses simplejson package when
67+
available, json package otherwise.
6868
"""
6969

7070
mime_type = 'application/json'
7171

7272
def create_in_document(self, ctx, in_string_encoding=None):
73-
"""Sets ``ctx.in_document``, using ``ctx.in_string``."""
73+
"""Sets ``ctx.in_document`` using ``ctx.in_string``."""
7474

7575
if in_string_encoding is None:
7676
in_string_encoding = 'UTF-8'
@@ -82,4 +82,5 @@ def create_in_document(self, ctx, in_string_encoding=None):
8282
raise Fault('Client.JsonDecodeError', repr(e))
8383

8484
def create_out_string(self, ctx, out_string_encoding='utf8'):
85+
"""Sets ``ctx.out_string`` using ``ctx.out_document``."""
8586
ctx.out_string = (json.dumps(o) for o in ctx.out_document)

spyne/protocol/xml/_base.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@
1717
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
1818
#
1919

20+
"""The ``spyne.protocol.xml`` package contains an xml-based protocol that
21+
serializes python objects to xml using Xml Schema conventions.
22+
"""
23+
2024
import logging
2125
logger = logging.getLogger('spyne.protocol.xml')
2226

@@ -73,13 +77,13 @@ def __init__(self, faultstring):
7377

7478

7579
class XmlObject(ProtocolBase):
76-
"""The protocol that serializes python objects to xml using schema
77-
conventions.
80+
"""The Xml Schema serialization protocol.
7881
7982
See the following material for more (much much more!) information.
80-
http://www.w3.org/TR/xmlschema-0/
81-
http://www.w3.org/TR/xmlschema-1/
82-
http://www.w3.org/TR/xmlschema-2/
83+
84+
* http://www.w3.org/TR/xmlschema-0/
85+
* http://www.w3.org/TR/xmlschema-1/
86+
* http://www.w3.org/TR/xmlschema-2/
8387
8488
:param app: The owner application instance.
8589
:param validator: One of (None, 'soft', 'lxml', 'schema',

spyne/server/null.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,12 +45,12 @@ class NullServer(ServerBase):
4545
It implicitly uses the 'sync' auxiliary processing mode.
4646
4747
Note that:
48-
1) **kwargs overwrite **args.
48+
1) ``**kwargs`` overwrite ``*args``.
4949
2) You can do: ::
5050
51-
logging.getLogger('spyne.server.null').setLevel(logging.CRITICAL)
51+
logging.getLogger('spyne.server.null').setLevel(logging.CRITICAL)
5252
53-
to hide context delimiters in logs.
53+
to hide context delimiters in logs.
5454
"""
5555

5656
transport = 'noconn://null.spyne'

0 commit comments

Comments
 (0)