diff options
Diffstat (limited to '')
-rw-r--r-- | src/bin/pg_rewind/datapagemap.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/bin/pg_rewind/datapagemap.h b/src/bin/pg_rewind/datapagemap.h new file mode 100644 index 0000000..76e9f20 --- /dev/null +++ b/src/bin/pg_rewind/datapagemap.h @@ -0,0 +1,29 @@ +/*------------------------------------------------------------------------- + * + * datapagemap.h + * + * Copyright (c) 2013-2021, PostgreSQL Global Development Group + * + *------------------------------------------------------------------------- + */ +#ifndef DATAPAGEMAP_H +#define DATAPAGEMAP_H + +#include "storage/block.h" +#include "storage/relfilenode.h" + +struct datapagemap +{ + char *bitmap; + int bitmapsize; +}; + +typedef struct datapagemap datapagemap_t; +typedef struct datapagemap_iterator datapagemap_iterator_t; + +extern void datapagemap_add(datapagemap_t *map, BlockNumber blkno); +extern datapagemap_iterator_t *datapagemap_iterate(datapagemap_t *map); +extern bool datapagemap_next(datapagemap_iterator_t *iter, BlockNumber *blkno); +extern void datapagemap_print(datapagemap_t *map); + +#endif /* DATAPAGEMAP_H */ |