Changeset 672


Ignore:
Timestamp:
Dec 30, 2015, 11:39:40 AM (4 years ago)
Author:
cito
Message:

Use consistent indentation in docs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/4.x/docs/pg.txt

    r671 r672  
    489489.. data:: version, __version__
    490490
    491    constants that give the current version
     491    constants that give the current version
    492492
    493493.. data:: INV_READ, INV_WRITE
    494494
    495    large objects access modes,
    496    used by :meth:`pgobject.locreate` and :meth:`pglarge.open`
     495    large objects access modes,
     496    used by :meth:`pgobject.locreate` and :meth:`pglarge.open`
    497497
    498498.. data:: SEEK_SET, SEEK_CUR, SEEK_END:
    499499
    500    positional flags, used by :meth:`pglarge.seek`
     500    positional flags, used by :meth:`pglarge.seek`
    501501
    502502
     
    512512.. note::
    513513
    514    Some methods give direct access to the connection socket.
    515    *Do not use them unless you really know what you are doing.*
    516    If you prefer disabling them,
    517    set the ``-DNO_DIRECT`` option in the Python setup file.
    518    These methods are specified by the tag [DA].
     514    Some methods give direct access to the connection socket.
     515    *Do not use them unless you really know what you are doing.*
     516    If you prefer disabling them,
     517    set the ``-DNO_DIRECT`` option in the Python setup file.
     518    These methods are specified by the tag [DA].
    519519
    520520.. note::
    521521
    522    Some other methods give access to large objects
    523    (refer to PostgreSQL user manual for more information about these).
    524    If you want to forbid access to these from the module,
    525    set the ``-DNO_LARGE`` option in the Python setup file.
    526    These methods are specified by the tag [LO].
     522    Some other methods give access to large objects
     523    (refer to PostgreSQL user manual for more information about these).
     524    If you want to forbid access to these from the module,
     525    set the ``-DNO_LARGE`` option in the Python setup file.
     526    These methods are specified by the tag [LO].
    527527
    528528query -- execute a SQL command string
     
    576576.. method:: pgobject.reset()
    577577
    578    Reset the :mod:`pg` connection
    579 
    580    :rtype: None
    581    :raises TypeError: too many (any) arguments
    582    :raises TypeError: invalid connection
     578    Reset the :mod:`pg` connection
     579
     580    :rtype: None
     581    :raises TypeError: too many (any) arguments
     582    :raises TypeError: invalid connection
    583583
    584584This method resets the current database connection.
     
    589589.. method:: pgobject.cancel()
    590590
    591    :rtype: None
    592    :raises TypeError: too many (any) arguments
    593    :raises TypeError: invalid connection
     591    :rtype: None
     592    :raises TypeError: too many (any) arguments
     593    :raises TypeError: invalid connection
    594594
    595595This method requests that the server abandon processing
     
    601601.. method:: pgobject.close()
    602602
    603    Close the :mod:`pg` connection
    604 
    605    :rtype: None
    606    :raises TypeError: too many (any) arguments
     603    Close the :mod:`pg` connection
     604
     605    :rtype: None
     606    :raises TypeError: too many (any) arguments
    607607
    608608This method closes the database connection. The connection will
     
    616616.. method:: pgobject.fileno()
    617617
    618    Return the socket used to connect to the database
    619 
    620    :returns: the socket id of the database connection
    621    :rtype: int
    622    :raises TypeError: too many (any) arguments
    623    :raises TypeError: invalid connection
     618    Return the socket used to connect to the database
     619
     620    :returns: the socket id of the database connection
     621    :rtype: int
     622    :raises TypeError: too many (any) arguments
     623    :raises TypeError: invalid connection
    624624
    625625This method returns the underlying socket id used to connect
     
    631631.. method:: pgobject.getnotify()
    632632
    633    Get the last notify from the server
    634 
    635    :returns: last notify from server
    636    :rtype: tuple, None
    637    :raises TypeError: too many parameters
    638    :raises TypeError: invalid connection
     633    Get the last notify from the server
     634
     635    :returns: last notify from server
     636    :rtype: tuple, None
     637    :raises TypeError: too many parameters
     638    :raises TypeError: invalid connection
    639639
    640640This method tries to get a notify from the server (from the SQL statement
     
    651651.. method:: pgobject.inserttable(table, values)
    652652
    653    Insert a Python list into a database table
    654 
    655    :param str table: the table name
    656    :param list values: list of rows values
    657    :rtype: None
    658    :raises TypeError: invalid connection, bad argument type, or too many arguments
    659    :raises MemoryError: insert buffer could not be allocated
    660    :raises ValueError: unsupported values
     653    Insert a Python list into a database table
     654
     655    :param str table: the table name
     656    :param list values: list of rows values
     657    :rtype: None
     658    :raises TypeError: invalid connection, bad argument type, or too many arguments
     659    :raises MemoryError: insert buffer could not be allocated
     660    :raises ValueError: unsupported values
    661661
    662662This method allows to *quickly* insert large blocks of data in a table:
     
    677677.. method:: pgobject.get_notice_receiver()
    678678
    679    Get the current notice receiver
    680 
    681    :returns: the current notice receiver callable
    682    :rtype: callable, None
    683    :raises TypeError: too many (any) arguments
     679    Get the current notice receiver
     680
     681    :returns: the current notice receiver callable
     682    :rtype: callable, None
     683    :raises TypeError: too many (any) arguments
    684684
    685685This method gets the custom notice receiver callback function that has
     
    689689.. method:: pgobject.set_notice_receiver(proc)
    690690
    691    Set a custom notice receiver
    692 
    693    :param proc: the custom notice receiver callback function
    694    :rtype: None
    695    :raises TypeError: the specified notice receiver is not callable
     691    Set a custom notice receiver
     692
     693    :param proc: the custom notice receiver callback function
     694    :rtype: None
     695    :raises TypeError: the specified notice receiver is not callable
    696696
    697697This method allows setting a custom notice receiver callback function.
Note: See TracChangeset for help on using the changeset viewer.