OSDN Git Service

259bef62f1f1d589862228bb7871199b99314bb3
[pg-rex/syncrep.git] / src / include / catalog / pg_language.h
1 /*-------------------------------------------------------------------------
2  *
3  * pg_language.h
4  *        definition of the system "language" relation (pg_language)
5  *        along with the relation's initial contents.
6  *
7  *
8  * Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
9  * Portions Copyright (c) 1994, Regents of the University of California
10  *
11  * $Id: pg_language.h,v 1.21 2003/03/10 22:28:19 tgl Exp $
12  *
13  * NOTES
14  *        the genbki.sh script reads this file and generates .bki
15  *        information from the DATA() statements.
16  *
17  *-------------------------------------------------------------------------
18  */
19 #ifndef PG_LANGUAGE_H
20 #define PG_LANGUAGE_H
21
22 /* ----------------
23  *              postgres.h contains the system type definitions and the
24  *              CATALOG(), BOOTSTRAP and DATA() sugar words so this file
25  *              can be read by both genbki.sh and the C compiler.
26  * ----------------
27  */
28
29 /* ----------------
30  *              pg_language definition.  cpp turns this into
31  *              typedef struct FormData_pg_language
32  * ----------------
33  */
34 CATALOG(pg_language)
35 {
36         NameData        lanname;
37         bool            lanispl;                /* Is a procedural language */
38         bool            lanpltrusted;   /* PL is trusted */
39         Oid                     lanplcallfoid;  /* Call handler for PL */
40         Oid                     lanvalidator;   /* optional validation function */
41         aclitem         lanacl[1];              /* Access privileges */
42 } FormData_pg_language;
43
44 /* ----------------
45  *              Form_pg_language corresponds to a pointer to a tuple with
46  *              the format of pg_language relation.
47  * ----------------
48  */
49 typedef FormData_pg_language *Form_pg_language;
50
51 /* ----------------
52  *              compiler constants for pg_language
53  * ----------------
54  */
55 #define Natts_pg_language                               6
56 #define Anum_pg_language_lanname                1
57 #define Anum_pg_language_lanispl                2
58 #define Anum_pg_language_lanpltrusted           3
59 #define Anum_pg_language_lanplcallfoid          4
60 #define Anum_pg_language_lanvalidator           5
61 #define Anum_pg_language_lanacl                 6
62
63 /* ----------------
64  *              initial contents of pg_language
65  * ----------------
66  */
67
68 DATA(insert OID = 12 ( "internal" f f 0 2246 _null_ ));
69 DESCR("Built-in functions");
70 #define INTERNALlanguageId 12
71 DATA(insert OID = 13 ( "c" f f 0 2247 _null_ ));
72 DESCR("Dynamically-loaded C functions");
73 #define ClanguageId 13
74 DATA(insert OID = 14 ( "sql" f t 0 2248 _null_ ));
75 DESCR("SQL-language functions");
76 #define SQLlanguageId 14
77
78 #endif   /* PG_LANGUAGE_H */