pgator.db.pq.api

This module defines high-level wrapper around libpq bindings. * The major goals: <ul> <li>Get more control over library errors (by converting to exceptions)</li> <li>Create layer that can be mocked in purpose of unittesting</li> </ul> *

Members

Classes

PGEscapeException
class PGEscapeException

The exception is thrown when postgres ran in problem with parameters escaping.

PGException
class PGException

All exceptions thrown by postgres api is inherited from this exception.

PGMemoryLackException
class PGMemoryLackException

The exception is thrown when libpq ran in out of memory problems.

PGParamNotExistException
class PGParamNotExistException

The exception is thrown when postgres ran in problem with query processing.

PGQueryException
class PGQueryException

The exception is thrown when postgres ran in problem with query processing.

PGReconnectException
class PGReconnectException

The exception is thrown when PGconn has a problem with reconnecting process.

Interfaces

IPGconn
interface IPGconn

Prototype: PGconn

IPGresult
interface IPGresult

Prototype: PGResult

IPostgreSQL
interface IPostgreSQL

OOP styled libpq wrapper to automatically handle library loading/unloading and to provide mockable layer for unittests.

Meta

Authors

NCrashed <ncrashed@gmail.com>

License

Subject to the terms of the MIT license, as written in the included LICENSE file.