![]() |
Storage Engine API
|
This structure represents header data for a btree bucket. More...
#include <btree_ondisk.h>
This structure represents header data for a btree bucket.
An object of this type is typically allocated inside of a buffer of size BucketSize, resulting in a full bucket with an appropriate header.
The body of a btree bucket contains an array of _KeyNode objects starting from its lowest indexed bytes and growing to higher indexed bytes. The body also contains variable width bson keys, which are allocated from the highest indexed bytes toward lower indexed bytes.
|hhhh|kkkkkkk-----—bbbbbbbbbbbuuubbbuubbb| h = header data k = KeyNode data
Public Types | |
enum | { HeaderSize = 40 } |
Public Attributes | |
DiskLoc | parent |
Parent bucket of this bucket, which isNull() for the root bucket. More... | |
DiskLoc | nextChild |
Given that there are n keys, this is the n index child. More... | |
unsigned short | _wasSize |
Can be reused, value is 8192 in current pdfile version Apr2010. More... | |
unsigned short | _reserved1 |
zero More... | |
int | flags |
int | emptySize |
basicInsert() assumes the next three members are consecutive and in this order: More... | |
int | topSize |
Size used for bson storage, including storage of old keys. More... | |
int | n |
int | reserved |
char | data [4] |
unsigned short mongo::BtreeBucketV0::_reserved1 |
zero
unsigned short mongo::BtreeBucketV0::_wasSize |
Can be reused, value is 8192 in current pdfile version Apr2010.
char mongo::BtreeBucketV0::data[4] |
int mongo::BtreeBucketV0::emptySize |
basicInsert() assumes the next three members are consecutive and in this order:
Size of the empty region.
int mongo::BtreeBucketV0::flags |
int mongo::BtreeBucketV0::n |
DiskLoc mongo::BtreeBucketV0::nextChild |
Given that there are n keys, this is the n index child.
DiskLoc mongo::BtreeBucketV0::parent |
Parent bucket of this bucket, which isNull() for the root bucket.
int mongo::BtreeBucketV0::reserved |
int mongo::BtreeBucketV0::topSize |
Size used for bson storage, including storage of old keys.