annotate src/postgresql.h @ 774:703228f54913

[xemacs-hg @ 2002-03-14 03:54:10 by stephent] Ville Skytta's auto-mode additions <1016058402.2852.39.camel@bobcat.ods.org> ChangeLog placeholders <87it7zu7wj.fsf@tleepslib.sk.tsukuba.ac.jp>
author stephent
date Thu, 14 Mar 2002 03:54:28 +0000
parents b39c14581166
children e38acbeb1cae
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
442
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
1 /*
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
2 postgresql.h -- Emacs Lisp binding to libpq.so
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
3 Copyright (C) 2000 Electrotechnical Laboratory, JAPAN.
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
4 Licensed to the Free Software Foundation.
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
5
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
6 Author: SL Baur <steve@beopen.com>
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
7 Maintainer: SL Baur <steve@beopen.com>
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
8
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
9 Please send patches to this file to me first before submitting them to
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
10 xemacs-patches.
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
11 */
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
12
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
13 #ifndef INCLUDED_postgresql_h_
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
14 #define INCLUDED_postgresql_h_ 1
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
15
647
b39c14581166 [xemacs-hg @ 2001-08-13 04:45:47 by ben]
ben
parents: 617
diff changeset
16 #define message message_ /* Yuck */
442
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
17 #include LIBPQ_FE_H_FILE /* main PostgreSQL header file */
647
b39c14581166 [xemacs-hg @ 2001-08-13 04:45:47 by ben]
ben
parents: 617
diff changeset
18 #undef message
442
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
19
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
20 #define BLCKSZ 8192 /* size of a default Postgres disk block */
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
21 /*
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
22 This file contains the GCC bug workaround code for the private
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
23 LRECORD types.
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
24 */
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
25
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
26 /* PGconn is an opaque object and we need to be able to store them in
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
27 Lisp code because libpq supports multiple connections.
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
28 */
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
29 struct Lisp_PGconn
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
30 {
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
31 struct lcrecord_header header;
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
32 PGconn *pgconn;
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
33 };
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
34 typedef struct Lisp_PGconn Lisp_PGconn;
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
35
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
36 DECLARE_LRECORD (pgconn, Lisp_PGconn);
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
37
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
38 #define XPGCONN(x) XRECORD (x, pgconn, Lisp_PGconn)
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
39 #define XSETPGCONN(x, p) XSETRECORD (x, p, pgconn)
617
af57a77cbc92 [xemacs-hg @ 2001-06-18 07:09:50 by ben]
ben
parents: 442
diff changeset
40 #define wrap_pgconn(p) wrap_record (p, pgconn)
442
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
41 #define PGCONNP(x) RECORDP (x, pgconn)
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
42 #define CHECK_PGCONN(x) CHECK_RECORD (x, pgconn)
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
43 #define CONCHECK_PGCONN(x) CONCHECK_RECORD (x, pgconn)
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
44
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
45 /****/
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
46
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
47 /* PGresult is an opaque object and we need to be able to store them in
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
48 Lisp code.
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
49 */
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
50 struct Lisp_PGresult
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
51 {
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
52 struct lcrecord_header header;
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
53 PGresult *pgresult;
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
54 };
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
55 typedef struct Lisp_PGresult Lisp_PGresult;
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
56
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
57 DECLARE_LRECORD (pgresult, Lisp_PGresult);
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
58
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
59 #define XPGRESULT(x) XRECORD (x, pgresult, Lisp_PGresult)
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
60 #define XSETPGRESULT(x, p) XSETRECORD (x, p, pgresult)
617
af57a77cbc92 [xemacs-hg @ 2001-06-18 07:09:50 by ben]
ben
parents: 442
diff changeset
61 #define wrap_pgresult(p) wrap_record (p, pgresult)
442
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
62 #define PGRESULTP(x) RECORDP (x, pgresult)
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
63 #define CHECK_PGRESULT(x) CHECK_RECORD (x, pgresult)
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
64 #define CONCHECK_PGRESULT(x) CONCHECK_RECORD (x, pgresult)
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
65
abe6d1db359e Import from CVS: tag r21-2-36
cvs
parents:
diff changeset
66 #endif /* INCLUDED_postgresql_h_ */