summaryrefslogtreecommitdiff
path: root/Doc/library/struct.rst
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2008-04-25 01:59:09 +0000
committerBenjamin Peterson <benjamin@python.org>2008-04-25 01:59:09 +0000
commit1d3227e5f9f7acf2275f31ba44dffaf60262b824 (patch)
tree83462006efe4ed692d231a1a48dc7e6068fcf594 /Doc/library/struct.rst
parentb908467e23de983449e97fc6d253b277101d01ef (diff)
downloadcpython-1d3227e5f9f7acf2275f31ba44dffaf60262b824.tar.gz
Merged revisions 62490 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r62490 | benjamin.peterson | 2008-04-24 20:29:10 -0500 (Thu, 24 Apr 2008) | 2 lines reformat some documentation of classes so methods and attributes are under the class directive ........
Diffstat (limited to 'Doc/library/struct.rst')
-rw-r--r--Doc/library/struct.rst34
1 files changed, 17 insertions, 17 deletions
diff --git a/Doc/library/struct.rst b/Doc/library/struct.rst
index 924cb606ea..a1832a14dc 100644
--- a/Doc/library/struct.rst
+++ b/Doc/library/struct.rst
@@ -242,37 +242,37 @@ The :mod:`struct` module also defines the following type:
since the format string only needs to be compiled once.
-Compiled Struct objects support the following methods and attributes:
+ Compiled Struct objects support the following methods and attributes:
-.. method:: Struct.pack(v1, v2, ...)
+ .. method:: pack(v1, v2, ...)
- Identical to the :func:`pack` function, using the compiled format.
- (``len(result)`` will equal :attr:`self.size`.)
+ Identical to the :func:`pack` function, using the compiled format.
+ (``len(result)`` will equal :attr:`self.size`.)
-.. method:: Struct.pack_into(buffer, offset, v1, v2, ...)
+ .. method:: pack_into(buffer, offset, v1, v2, ...)
- Identical to the :func:`pack_into` function, using the compiled format.
+ Identical to the :func:`pack_into` function, using the compiled format.
-.. method:: Struct.unpack(string)
+ .. method:: unpack(string)
- Identical to the :func:`unpack` function, using the compiled format.
- (``len(string)`` must equal :attr:`self.size`).
+ Identical to the :func:`unpack` function, using the compiled format.
+ (``len(string)`` must equal :attr:`self.size`).
-.. method:: Struct.unpack_from(buffer[, offset=0])
+ .. method:: unpack_from(buffer[, offset=0])
- Identical to the :func:`unpack_from` function, using the compiled format.
- (``len(buffer[offset:])`` must be at least :attr:`self.size`).
+ Identical to the :func:`unpack_from` function, using the compiled format.
+ (``len(buffer[offset:])`` must be at least :attr:`self.size`).
-.. attribute:: Struct.format
+ .. attribute:: format
- The format string used to construct this Struct object.
+ The format string used to construct this Struct object.
-.. attribute:: Struct.size
+ .. attribute:: size
- The calculated size of the struct (and hence of the string) corresponding
- to :attr:`format`.
+ The calculated size of the struct (and hence of the string) corresponding
+ to :attr:`format`.