Module ImportFrom alias alias alias alias ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults vararg body Expr Str If CompareEq NameLoad TupleLoad NameLoad NameLoad NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr orelse Expr Call AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults vararg body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr decorator_list decorator_list
N/A __future__ absolute_import division print_function unicode_literals CursorContextManager N/A object N/A N/A Instantiated once per :py:func:`~postgres.Postgres.get_cursor`
    call.

    :param pool: a :py:class:`psycopg2.pool.*ConnectionPool`

    The return value of :py:func:`CursorContextManager.__enter__` is a
    :py:mod:`psycopg2` cursor. Any positional and keyword arguments to our
    constructor are passed through to the cursor constructor.

    When the block starts, a connection is checked out of the connection pool
    and :py:attr:`autocommit` is set to :py:const:`False`. Then a cursor is
    constructed, and the :py:meth:`one` and :py:meth:`all` methods are scabbed
    on (this allows us to provide our simple API no matter the
    :py:attr:`cursor_factory`). The cursor is returned to the :py:attr:`with`
    statement. If the block raises an exception, the connection is rolled back.
    Otherwise, it's committed. In either case, the cursor is closed,
    :py:attr:`autocommit` is reset to :py:class:`False` (just in case) and the
    connection is put back in the pool.

     __init__ N/A N/A self pool N/A a kw N/A N/A N/A self pool pool N/A N/A self a a N/A N/A self kw kw N/A N/A self conn None N/A __enter__ N/A N/A self N/A N/A N/A Get a connection from the pool.
         N/A N/A self conn N/A N/A N/A self pool getconn N/A N/A N/A self conn autocommit False N/A N/A self cursor N/A N/A N/A self conn cursor N/A self a N/A self kw N/A N/A self cursor N/A __exit__ N/A N/A self N/A exc_info N/A N/A Put our connection back in the pool.
         N/A N/A exc_info N/A None None None N/A N/A N/A N/A N/A self conn commit N/A N/A N/A N/A N/A self conn rollback N/A N/A N/A N/A self cursor close N/A N/A N/A self conn autocommit False N/A N/A N/A N/A self pool putconn N/A self conn N/A N/A ConnectionContextManager N/A object N/A N/A Instantiated once per :py:func:`~postgres.Postgres.get_connection` call.

    :param pool: a :py:class:`psycopg2.pool.*ConnectionPool`

    The return value of :py:func:`ConnectionContextManager.__enter__` is a
    :py:class:`postgres.Connection`. When the block starts, a
    :py:class:`~postgres.Connection` is checked out of the connection pool and
    :py:attr:`autocommit` is set to :py:const:`False`. When the block ends, the
    :py:class:`~postgres.Connection` is rolled back before being put back in
    the pool.

     __init__ N/A N/A self pool N/A N/A N/A N/A self pool pool N/A N/A self conn None N/A __enter__ N/A N/A self N/A N/A N/A Get a connection from the pool.
         N/A N/A self conn N/A N/A N/A self pool getconn N/A N/A N/A self conn autocommit False N/A N/A self conn N/A __exit__ N/A N/A self N/A exc_info N/A N/A Put our connection back in the pool.
         N/A N/A N/A N/A self conn rollback N/A N/A N/A self conn autocommit False N/A N/A N/A N/A self pool putconn N/A self conn N/A N/A