Version: 1.0.0
postgresql_interface.h
Go to the documentation of this file.
1 #ifndef _WX_DATABASE_POSTGRESQL_INTERFACES_H_
2 #define _WX_DATABASE_POSTGRESQL_INTERFACES_H_
3 
4 #include "wx/database/wxprec.h"
5 #include <wx/dynlib.h>
6 
7 typedef ConnStatusType (*PQstatusType)(const PGconn*);
8 typedef PGconn* (*PQsetdbLoginType)(const char*, const char*,
9  const char*, const char*, const char*, const char*, const char*);
10 typedef char* (*PQerrorMessageType)(const PGconn*);
11 typedef int (*PQclientEncodingType)(const PGconn*);
12 typedef int (*PQsetClientEncodingType)(const PGconn*, const char*);
13 typedef const char* (*PQencodingToCharType)(int);
14 typedef void (*PQfinishType)(const PGconn*);
15 typedef PGresult* (*PQexecType)(const PGconn*, const char*);
16 typedef ExecStatusType (*PQresultStatusType)(const PGresult*);
17 typedef void (*PQclearType)(PGresult*);
18 typedef char* (*PQcmdTuplesType)(const PGresult*);
19 typedef PGresult* (*PQprepareType)(PGconn*, const char*, const char*, int, const Oid*);
20 typedef PGresult* (*PQexecPreparedType)(PGconn*, const char*, int, const char *const*,
21  const int*, const int*, int resultFormat);
22 typedef char* (*PQresultErrorMessageType)(const PGresult*);
23 typedef int (*PQntuplesType)(const PGresult*);
24 typedef int (*PQbinaryTuplesType)(const PGresult*);
25 typedef char* (*PQfnameType)(const PGresult*, int);
26 typedef int (*PQgetisnullType)(const PGresult*, int, int);
27 typedef char* (*PQgetvalueType)(const PGresult*, int, int);
28 typedef int (*PQgetlengthType)(const PGconn*);
29 typedef unsigned char* (*PQunescapeByteaType)(const unsigned char*, size_t*);
30 typedef void (*PQfreememType)(void*);
31 typedef Oid (*PQftypeType)(const PGresult*, int);
32 typedef int (*PQfsizeType)(const PGresult*, int);
33 typedef int (*PQnfieldsType)(const PGresult*);
34 
35 
36 //class PostgresInterface
38 {
39 public:
41  bool Init();
42 
68 
69 
70 private:
71  wxDynamicLibrary m_PostgresDLL;
72 
98 };
99 
100 #endif//_WX_DATABASE_POSTGRESQL_INTERFACES_H_
101 
PQencodingToCharType m_pPQencodingToChar
char *(* PQerrorMessageType)(const PGconn *)
PQclientEncodingType GetPQclientEncoding()
PQunescapeByteaType GetPQunescapeBytea()
PQsetClientEncodingType GetPQsetClientEncoding()
int(* PQclientEncodingType)(const PGconn *)
PQsetdbLoginType GetPQsetdbLogin()
PQencodingToCharType GetPQencodingToChar()
int(* PQbinaryTuplesType)(const PGresult *)
char *(* PQresultErrorMessageType)(const PGresult *)
char *(* PQgetvalueType)(const PGresult *, int, int)
PQbinaryTuplesType GetPQbinaryTuples()
int(* PQsetClientEncodingType)(const PGconn *, const char *)
int(* PQgetlengthType)(const PGconn *)
void(* PQfreememType)(void *)
PGconn *(* PQsetdbLoginType)(const char *, const char *, const char *, const char *, const char *, const char *, const char *)
void(* PQclearType)(PGresult *)
PQsetClientEncodingType m_pPQsetClientEncoding
PQexecPreparedType m_pPQexecPrepared
PQresultErrorMessageType GetPQresultErrorMessage()
char *(* PQfnameType)(const PGresult *, int)
int(* PQntuplesType)(const PGresult *)
int(* PQfsizeType)(const PGresult *, int)
int(* PQnfieldsType)(const PGresult *)
PQerrorMessageType m_pPQerrorMessage
PQunescapeByteaType m_pPQunescapeBytea
PGresult *(* PQexecType)(const PGconn *, const char *)
PQexecPreparedType GetPQexecPrepared()
char *(* PQcmdTuplesType)(const PGresult *)
void(* PQfinishType)(const PGconn *)
unsigned char *(* PQunescapeByteaType)(const unsigned char *, size_t *)
PQresultStatusType GetPQresultStatus()
PGresult *(* PQprepareType)(PGconn *, const char *, const char *, int, const Oid *)
int(* PQgetisnullType)(const PGresult *, int, int)
PQresultStatusType m_pPQresultStatus
PQbinaryTuplesType m_pPQbinaryTuples
Oid(* PQftypeType)(const PGresult *, int)
const char *(* PQencodingToCharType)(int)
PGresult *(* PQexecPreparedType)(PGconn *, const char *, int, const char *const *, const int *, const int *, int resultFormat)
PQerrorMessageType GetPQerrorMessage()
PQclientEncodingType m_pPQclientEncoding
ConnStatusType(* PQstatusType)(const PGconn *)
PQresultErrorMessageType m_pPQresultErrorMessage
ExecStatusType(* PQresultStatusType)(const PGresult *)