Go to the documentation of this file. 1 #ifndef INDEX_BTREE_BTREEINTERNAL_H
2 #define INDEX_BTREE_BTREEINTERNAL_H
115 return const_cast<char*
>(
reinterpret_cast<const char*
>(
this)) +
134 return const_cast<char*
>(
reinterpret_cast<const char*
>(
this)) +
151 static inline const char*
156 static inline const RecordId&
193 #endif // INDEX_BTREE_BTREEINTERNAL_H
int16_t FieldOffset
Definition: tdb_base.h:212
static const RecordId & BTreeRecordGetHeapRecordId(const char *recbuf, bool isleaf)
Definition: BTreeInternal.h:157
constexpr uint16_t BTREE_PAGE_ISROOT
Definition: BTreeInternal.h:36
static FieldOffset BTreeComputePageUsage(SlotId num_recs, FieldOffset totrlen)
Returns the page usage of a B-Tree page given its number of records and its total length of all the r...
Definition: BTreeInternal.h:170
static char * BTreeRecordGetPayload(char *recbuf, bool isleaf)
Definition: BTreeInternal.h:143
constexpr const size_t PAGE_SIZE
Definition: tdb_base.h:159
static void Initialize(char *btmeta_buf, PageNumber root_pid)
Initializes the B-tree meta page.
Definition: BTreeUtils.cpp:8
static FieldOffset ComputeFreeSpace(FieldOffset usr_data_sz, SlotId num_recs, FieldOffset total_reclen)
Computes the size of the free space on the page if there are num_recs records inserted to an empty Va...
Definition: VarlenDataPage.cpp:526
constexpr PageNumber RESERVED_PID
An invalid page number reserved for file manager internal use.
Definition: tdb_base.h:243
uint16_t SlotId
Definition: tdb_base.h:223
constexpr FieldOffset BTREE_MAX_RECORD_SIZE
Definition: BTreeInternal.h:187
constexpr size_t BTreePageHeaderSize
Definition: BTreeInternal.h:92
constexpr FieldOffset BTREE_MIN_PAGE_USAGE
Definition: BTreeInternal.h:189
The record ID of a record on a page is a pair of ‘(PageNumber, SlotId)’.
Definition: Record.h:17
constexpr uint16_t BTREE_PAGE_ISLEAF
Definition: BTreeInternal.h:37
constexpr size_t BTreeLeafRecordHeaderSize
Definition: BTreeInternal.h:139
constexpr SlotId MaxSlotId
The maximum valid slot ID.
Definition: tdb_base.h:265
PageHeaderData m_ph
Definition: BTreeInternal.h:22
PageNumber m_root_pid
The page number of the B-Tree root page.
Definition: BTreeInternal.h:28
#define MAXALIGN(LEN)
Definition: tdb_base.h:328
constexpr size_t BTreeInternalRecordHeaderSize
Definition: BTreeInternal.h:120
The B-tree meta page.
Definition: BTreeInternal.h:21
static const RecordId INFINITY_RECORDID
This is the record number that is guaranteed to be larger than any valid record ID.
Definition: BTreeInternal.h:16
uint32_t PageNumber
Definition: tdb_base.h:214