PostgreSQL Source Code git master
amvalidate.h
Go to the documentation of this file.
1/*-------------------------------------------------------------------------
2 *
3 * amvalidate.h
4 * Support routines for index access methods' amvalidate and
5 * amadjustmembers functions.
6 *
7 * Copyright (c) 2016-2025, PostgreSQL Global Development Group
8 *
9 * src/include/access/amvalidate.h
10 *
11 *-------------------------------------------------------------------------
12 */
13#ifndef AMVALIDATE_H
14#define AMVALIDATE_H
15
16#include "utils/catcache.h"
17
18
19/* Struct returned (in a list) by identify_opfamily_groups() */
20typedef struct OpFamilyOpFuncGroup
21{
22 Oid lefttype; /* amoplefttype/amproclefttype */
23 Oid righttype; /* amoprighttype/amprocrighttype */
24 uint64 operatorset; /* bitmask of operators with these types */
25 uint64 functionset; /* bitmask of support funcs with these types */
27
28
29/* Functions in access/index/amvalidate.c */
30extern List *identify_opfamily_groups(CatCList *oprlist, CatCList *proclist);
31extern bool check_amproc_signature(Oid funcid, Oid restype, bool exact,
32 int minargs, int maxargs,...);
33extern bool check_amoptsproc_signature(Oid funcid);
34extern bool check_amop_signature(Oid opno, Oid restype,
35 Oid lefttype, Oid righttype);
36extern Oid opclass_for_family_datatype(Oid amoid, Oid opfamilyoid,
37 Oid datatypeoid);
38extern bool opfamily_can_sort_type(Oid opfamilyoid, Oid datatypeoid);
39
40#endif /* AMVALIDATE_H */
Oid opclass_for_family_datatype(Oid amoid, Oid opfamilyoid, Oid datatypeoid)
Definition: amvalidate.c:236
bool check_amproc_signature(Oid funcid, Oid restype, bool exact, int minargs, int maxargs,...)
Definition: amvalidate.c:152
struct OpFamilyOpFuncGroup OpFamilyOpFuncGroup
bool check_amop_signature(Oid opno, Oid restype, Oid lefttype, Oid righttype)
Definition: amvalidate.c:206
List * identify_opfamily_groups(CatCList *oprlist, CatCList *proclist)
Definition: amvalidate.c:43
bool opfamily_can_sort_type(Oid opfamilyoid, Oid datatypeoid)
Definition: amvalidate.c:271
bool check_amoptsproc_signature(Oid funcid)
Definition: amvalidate.c:192
uint64_t uint64
Definition: c.h:503
unsigned int Oid
Definition: postgres_ext.h:30
Definition: pg_list.h:54