3 * Prototypes for operating on BRIN pages.
5 * Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
6 * Portions Copyright (c) 1994, Regents of the University of California
9 * src/include/access/brin_pageops.h
11 #ifndef BRIN_PAGEOPS_H
12 #define BRIN_PAGEOPS_H
14 #include "access/brin_revmap.h"
16 extern bool brin_doupdate(Relation idxrel
, BlockNumber pagesPerRange
,
17 BrinRevmap
*revmap
, BlockNumber heapBlk
,
18 Buffer oldbuf
, OffsetNumber oldoff
,
19 const BrinTuple
*origtup
, Size origsz
,
20 const BrinTuple
*newtup
, Size newsz
,
22 extern bool brin_can_do_samepage_update(Buffer buffer
, Size origsz
,
24 extern OffsetNumber
brin_doinsert(Relation idxrel
, BlockNumber pagesPerRange
,
25 BrinRevmap
*revmap
, Buffer
*buffer
, BlockNumber heapBlk
,
26 BrinTuple
*tup
, Size itemsz
);
28 extern void brin_page_init(Page page
, uint16 type
);
29 extern void brin_metapage_init(Page page
, BlockNumber pagesPerRange
,
32 extern bool brin_start_evacuating_page(Relation idxRel
, Buffer buf
);
33 extern void brin_evacuate_page(Relation idxRel
, BlockNumber pagesPerRange
,
34 BrinRevmap
*revmap
, Buffer buf
);
36 extern void brin_page_cleanup(Relation idxrel
, Buffer buf
);
38 #endif /* BRIN_PAGEOPS_H */