mirror of https://github.com/python/cpython
Fix markup, punctuation and whitespaces in _winreg.rst.
This commit is contained in:
parent
c0deec1839
commit
01fa86a0bd
|
@ -39,7 +39,7 @@ This module offers the following functions:
|
||||||
.. function:: ConnectRegistry(computer_name, key)
|
.. function:: ConnectRegistry(computer_name, key)
|
||||||
|
|
||||||
Establishes a connection to a predefined registry handle on another computer,
|
Establishes a connection to a predefined registry handle on another computer,
|
||||||
and returns a :dfn:`handle object`
|
and returns a :ref:`handle object <handle-object>`.
|
||||||
|
|
||||||
*computer_name* is the name of the remote computer, of the form
|
*computer_name* is the name of the remote computer, of the form
|
||||||
``r"\\computername"``. If ``None``, the local computer is used.
|
``r"\\computername"``. If ``None``, the local computer is used.
|
||||||
|
@ -52,7 +52,8 @@ This module offers the following functions:
|
||||||
|
|
||||||
.. function:: CreateKey(key, sub_key)
|
.. function:: CreateKey(key, sub_key)
|
||||||
|
|
||||||
Creates or opens the specified key, returning a :dfn:`handle object`
|
Creates or opens the specified key, returning a
|
||||||
|
:ref:`handle object <handle-object>`.
|
||||||
|
|
||||||
*key* is an already open key, or one of the predefined :const:`HKEY_\*`
|
*key* is an already open key, or one of the predefined :const:`HKEY_\*`
|
||||||
constants.
|
constants.
|
||||||
|
@ -68,9 +69,10 @@ This module offers the following functions:
|
||||||
:exc:`WindowsError` exception is raised.
|
:exc:`WindowsError` exception is raised.
|
||||||
|
|
||||||
|
|
||||||
.. function:: CreateKeyEx(key, sub_key[, res=0[, sam=KEY_ALL_ACCESS]])
|
.. function:: CreateKeyEx(key, sub_key, res=0, sam=KEY_ALL_ACCESS)
|
||||||
|
|
||||||
Creates or opens the specified key, returning a :dfn:`handle object`
|
Creates or opens the specified key, returning a
|
||||||
|
:ref:`handle object <handle-object>`.
|
||||||
|
|
||||||
*key* is an already open key, or one of the predefined :const:`HKEY_\*`
|
*key* is an already open key, or one of the predefined :const:`HKEY_\*`
|
||||||
constants.
|
constants.
|
||||||
|
@ -109,7 +111,7 @@ This module offers the following functions:
|
||||||
If the method fails, a :exc:`WindowsError` exception is raised.
|
If the method fails, a :exc:`WindowsError` exception is raised.
|
||||||
|
|
||||||
|
|
||||||
.. function:: DeleteKeyEx(key, sub_key[, sam=KEY_WOW64_64KEY[, res=0]])
|
.. function:: DeleteKeyEx(key, sub_key, sam=KEY_WOW64_64KEY, res=0)
|
||||||
|
|
||||||
Deletes the specified key.
|
Deletes the specified key.
|
||||||
|
|
||||||
|
@ -239,7 +241,7 @@ This module offers the following functions:
|
||||||
|
|
||||||
A call to LoadKey() fails if the calling process does not have the
|
A call to LoadKey() fails if the calling process does not have the
|
||||||
:const:`SE_RESTORE_PRIVILEGE` privilege. Note that privileges are different than
|
:const:`SE_RESTORE_PRIVILEGE` privilege. Note that privileges are different than
|
||||||
permissions - see the Win32 documentation for more details.
|
permissions -- see the Win32 documentation for more details.
|
||||||
|
|
||||||
If *key* is a handle returned by :func:`ConnectRegistry`, then the path
|
If *key* is a handle returned by :func:`ConnectRegistry`, then the path
|
||||||
specified in *fileName* is relative to the remote computer.
|
specified in *fileName* is relative to the remote computer.
|
||||||
|
@ -248,9 +250,9 @@ This module offers the following functions:
|
||||||
:const:`HKEY_LOCAL_MACHINE` tree. This may or may not be true.
|
:const:`HKEY_LOCAL_MACHINE` tree. This may or may not be true.
|
||||||
|
|
||||||
|
|
||||||
.. function:: OpenKey(key, sub_key[, res=0][, sam=KEY_READ])
|
.. function:: OpenKey(key, sub_key, res=0, sam=KEY_READ)
|
||||||
|
|
||||||
Opens the specified key, returning a :dfn:`handle object`
|
Opens the specified key, returning a :ref:`handle object <handle-object>`.
|
||||||
|
|
||||||
*key* is an already open key, or any one of the predefined :const:`HKEY_\*`
|
*key* is an already open key, or any one of the predefined :const:`HKEY_\*`
|
||||||
constants.
|
constants.
|
||||||
|
@ -269,8 +271,8 @@ This module offers the following functions:
|
||||||
|
|
||||||
.. function:: OpenKeyEx()
|
.. function:: OpenKeyEx()
|
||||||
|
|
||||||
The functionality of :func:`OpenKeyEx` is provided via :func:`OpenKey`, by the
|
The functionality of :func:`OpenKeyEx` is provided via :func:`OpenKey`,
|
||||||
use of default arguments.
|
by the use of default arguments.
|
||||||
|
|
||||||
|
|
||||||
.. function:: QueryInfoKey(key)
|
.. function:: QueryInfoKey(key)
|
||||||
|
@ -299,7 +301,7 @@ This module offers the following functions:
|
||||||
|
|
||||||
.. function:: QueryValue(key, sub_key)
|
.. function:: QueryValue(key, sub_key)
|
||||||
|
|
||||||
Retrieves the unnamed value for a key, as a string
|
Retrieves the unnamed value for a key, as a string.
|
||||||
|
|
||||||
*key* is an already open key, or one of the predefined :const:`HKEY_\*`
|
*key* is an already open key, or one of the predefined :const:`HKEY_\*`
|
||||||
constants.
|
constants.
|
||||||
|
@ -316,8 +318,8 @@ This module offers the following functions:
|
||||||
|
|
||||||
.. function:: QueryValueEx(key, value_name)
|
.. function:: QueryValueEx(key, value_name)
|
||||||
|
|
||||||
Retrieves the type and data for a specified value name associated with an open
|
Retrieves the type and data for a specified value name associated with
|
||||||
registry key.
|
an open registry key.
|
||||||
|
|
||||||
*key* is an already open key, or one of the predefined :const:`HKEY_\*`
|
*key* is an already open key, or one of the predefined :const:`HKEY_\*`
|
||||||
constants.
|
constants.
|
||||||
|
@ -351,7 +353,7 @@ This module offers the following functions:
|
||||||
If *key* represents a key on a remote computer, the path described by
|
If *key* represents a key on a remote computer, the path described by
|
||||||
*file_name* is relative to the remote computer. The caller of this method must
|
*file_name* is relative to the remote computer. The caller of this method must
|
||||||
possess the :const:`SeBackupPrivilege` security privilege. Note that
|
possess the :const:`SeBackupPrivilege` security privilege. Note that
|
||||||
privileges are different than permissions - see the Win32 documentation for
|
privileges are different than permissions -- see the Win32 documentation for
|
||||||
more details.
|
more details.
|
||||||
|
|
||||||
This function passes NULL for *security_attributes* to the API.
|
This function passes NULL for *security_attributes* to the API.
|
||||||
|
@ -424,7 +426,7 @@ This module offers the following functions:
|
||||||
| :const:`REG_SZ` | A null-terminated string. |
|
| :const:`REG_SZ` | A null-terminated string. |
|
||||||
+----------------------------------+---------------------------------------------+
|
+----------------------------------+---------------------------------------------+
|
||||||
|
|
||||||
*reserved* can be anything - zero is always passed to the API.
|
*reserved* can be anything -- zero is always passed to the API.
|
||||||
|
|
||||||
*value* is a string that specifies the new value.
|
*value* is a string that specifies the new value.
|
||||||
|
|
||||||
|
@ -495,7 +497,7 @@ All registry functions in this module return one of these objects.
|
||||||
All registry functions in this module which accept a handle object also accept
|
All registry functions in this module which accept a handle object also accept
|
||||||
an integer, however, use of the handle object is encouraged.
|
an integer, however, use of the handle object is encouraged.
|
||||||
|
|
||||||
Handle objects provide semantics for :meth:`__nonzero__` - thus ::
|
Handle objects provide semantics for :meth:`__nonzero__` -- thus::
|
||||||
|
|
||||||
if handle:
|
if handle:
|
||||||
print "Yes"
|
print "Yes"
|
||||||
|
|
Loading…
Reference in New Issue