10#ifndef _SWATDB_SWATDBTYPES_H_
11#define _SWATDB_SWATDBTYPES_H_
49typedef std::uint32_t SlotId;
58 bool operator==(
const PageId& other)
const{
59 return (file_id == other.file_id) && (page_num == other.page_num);
62 bool operator!=(
const PageId& other)
const{
63 return (file_id != other.file_id) || (page_num != other.page_num);
74 bool operator==(
const RecordId& other)
const{
75 return (page_num == other.page_num) && (slot_id == other.slot_id);
78 bool operator!=(
const RecordId& other)
const{
79 return (page_num != other.page_num) || (slot_id != other.slot_id);
108 std::string field_name;
110 std::uint32_t max_size;
112 bool operator==(
const FieldEntry& other)
const{
113 return (max_size == other.max_size) && (field_name == other.field_name)
114 && (field_type == other.field_type);
117 bool operator!=(
const FieldEntry& other)
const{
118 return (max_size != other.max_size) || (field_name != other.field_name)
119 || (field_type != other.field_type);
154enum Comp {INVALID_TYPE,
Definition swatdb_types.h:107
Definition swatdb_types.h:54
Definition swatdb_types.h:70
Definition swatdb_types.h:225
const SlotId INVALID_SLOT_ID
Definition swatdb_types.h:331
const std::uint32_t MAX_RECORD_SIZE
Definition swatdb_types.h:269
const float MAX_HASH_BUCKET_LOAD
Definition swatdb_types.h:348
const float MAX_HEAP_PAGE_LOAD
Definition swatdb_types.h:342
const std::uint32_t MAX_FILE_NUM
Definition swatdb_types.h:250
std::uint32_t FrameId
Index of each frame in the bufferpool of BufferManager.
Definition swatdb_types.h:44
const std::uint32_t FILE_MAX_CAPACITY
Definition swatdb_types.h:241
const std::uint32_t INVALID_PAGE_NUM
Definition swatdb_types.h:304
const std::uint32_t BUF_SIZE
Definition swatdb_types.h:292
std::uint32_t FieldId
Definition swatdb_types.h:86
std::uint32_t FileId
Definition swatdb_types.h:33
const PageId INVALID_PAGE_ID
Definition swatdb_types.h:320
const std::uint32_t HEADER_PAGE_NUM
Definition swatdb_types.h:310
const RecordId INVALID_RECORD_ID
Definition swatdb_types.h:336
const char bm_rep_strs[MAXREPTYPES][BM_MAX_REP_STR_LEN]
Definition swatdb_types.h:187
std::uint16_t FieldOffset
Definition swatdb_types.h:92
RepType
Definition swatdb_types.h:167
FieldType
Definition swatdb_types.h:97
const std::uint32_t INVALID_FILE_ID
Definition swatdb_types.h:315
const int BM_MAX_REP_STR_LEN
Definition swatdb_types.h:181
std::uint32_t Level
Definition swatdb_types.h:130
const std::uint32_t INVALID_SLOT_OFFSET
Definition swatdb_types.h:326
const std::uint32_t PAGE_SIZE
Definition swatdb_types.h:258
std::uint32_t HashVal
Definition swatdb_types.h:136
const std::uint32_t MAX_FILE_NAME_LEN
Definition swatdb_types.h:287
const SlotId MAX_HASH_DIRSLOT
Definition swatdb_types.h:353
const std::uint32_t MAX_FIELD_NAME
Definition swatdb_types.h:299
std::uint32_t PageNum
Definition swatdb_types.h:38
const std::uint32_t MAX_PAGE_NUM
Definition swatdb_types.h:281
JoinType
Definition swatdb_types.h:211
SelectType
Definition swatdb_types.h:201
CatType
Definition swatdb_types.h:145