Autonomy Software C++ 24.5.1
Welcome to the Autonomy Software repository of the Mars Rover Design Team (MRDT) at Missouri University of Science and Technology (Missouri S&T)! API reference contains the source code and other resources for the development of the autonomy software for our Mars rover. The Autonomy Software project aims to compete in the University Rover Challenge (URC) by demonstrating advanced autonomous capabilities and robust navigation algorithms.
Loading...
Searching...
No Matches
duckdb::Node15Leaf Class Reference

Node15Leaf holds up to 15 sorted bytes. More...

Inheritance diagram for duckdb::Node15Leaf:
Collaboration diagram for duckdb::Node15Leaf:

Static Public Member Functions

static void InsertByte (ART &art, Node &node, const uint8_t byte)
 Insert a byte.
static void DeleteByte (ART &art, Node &node, const uint8_t byte)
 Delete a byte.
Static Public Member Functions inherited from duckdb::BaseLeaf< 15, NType::NODE_15_LEAF >
static NodeHandle< BaseLeaf > New (ART &art, Node &node)
 Get a new BaseLeaf and initialize it.

Static Public Attributes

static constexpr NType NODE_15_LEAF = NType::NODE_15_LEAF
static constexpr uint8_t CAPACITY = 15

Static Private Member Functions

static void GrowNode7Leaf (ART &art, Node &node15_leaf, Node &node7_leaf)
static void ShrinkNode256Leaf (ART &art, Node &node15_leaf, Node &node256_leaf)
 We shrink at <= Node48::SHRINK_THRESHOLD.

Friends

class Node7Leaf
class Node256Leaf

Additional Inherited Members

Public Member Functions inherited from duckdb::BaseLeaf< 15, NType::NODE_15_LEAF >
BaseLeaf & operator= (const BaseLeaf &)=delete
bool HasByte (const uint8_t byte) const
 Returns true, if the byte exists, else false.
array_ptr< uint8_t > GetBytes ()
bool GetNextByte (uint8_t &byte) const

Detailed Description

Node15Leaf holds up to 15 sorted bytes.

Member Function Documentation

◆ InsertByte()

void duckdb::Node15Leaf::InsertByte ( ART & art,
Node & node,
const uint8_t byte )
static

Insert a byte.

153556 {
153557 {
153558 NodeHandle<Node15Leaf> n15_handle(art, node);
153559 auto &n15 = n15_handle.Get();
153560 if (n15.count != CAPACITY) {
153561 InsertByteInternal(n15, byte);
153562 return;
153563 }
153564 }
153565 auto node15 = node;
153566 Node256Leaf::GrowNode15Leaf(art, node, node15);
153567 Node256Leaf::InsertByte(art, node, byte);
153568}
static void InsertByte(ART &art, Node &node, const uint8_t byte)
Insert a byte.
Definition duckdb.cpp:155248
Here is the call graph for this function:
Here is the caller graph for this function:

◆ DeleteByte()

void duckdb::Node15Leaf::DeleteByte ( ART & art,
Node & node,
const uint8_t byte )
static

Delete a byte.

153570 {
153571 {
153572 auto n15_handle = DeleteByteInternal(art, node, byte);
153573 auto &n15 = n15_handle.Get();
153574 if (n15.count >= Node7Leaf::CAPACITY) {
153575 return;
153576 }
153577 }
153578 auto node15 = node;
153579 Node7Leaf::ShrinkNode15Leaf(art, node, node15);
153580}
Here is the caller graph for this function:

◆ GrowNode7Leaf()

void duckdb::Node15Leaf::GrowNode7Leaf ( ART & art,
Node & node15_leaf,
Node & node7_leaf )
staticprivate
153582 {
153583 {
153584 NodeHandle<Node7Leaf> n7_handle(art, node7_leaf);
153585 auto &n7 = n7_handle.Get();
153586
153587 auto n15_handle = New(art, node15_leaf);
153588 auto &n15 = n15_handle.Get();
153589 node15_leaf.SetGateStatus(node7_leaf.GetGateStatus());
153590
153591 n15.count = n7.count;
153592 for (uint8_t i = 0; i < n7.count; i++) {
153593 n15.key[i] = n7.key[i];
153594 }
153595 }
153596 Node::FreeNode(art, node7_leaf);
153597}
static NodeHandle< BaseLeaf > New(ART &art, Node &node)
Definition duckdb.cpp:150900
static void FreeNode(ART &art, Node &node)
Free the node.
Definition duckdb.cpp:154622

◆ ShrinkNode256Leaf()

void duckdb::Node15Leaf::ShrinkNode256Leaf ( ART & art,
Node & node15_leaf,
Node & node256_leaf )
staticprivate

We shrink at <= Node48::SHRINK_THRESHOLD.

153599 {
153600 {
153601 auto n15_handle = New(art, node15_leaf);
153602 auto &n15 = n15_handle.Get();
153603
153604 NodeHandle<Node256Leaf> n256_handle(art, node256_leaf);
153605 auto &n256 = n256_handle.Get();
153606
153607 node15_leaf.SetGateStatus(node256_leaf.GetGateStatus());
153608
153609 ValidityMask mask(&n256.mask[0], Node256::CAPACITY);
153610 for (uint16_t i = 0; i < Node256::CAPACITY; i++) {
153611 if (mask.RowIsValid(i)) {
153612 n15.key[n15.count] = UnsafeNumericCast<uint8_t>(i);
153613 n15.count++;
153614 }
153615 }
153616 }
153617 Node::FreeNode(art, node256_leaf);
153618}
GMat mask(const GMat &src, const GMat &mask)
Here is the call graph for this function:
Here is the caller graph for this function:

The documentation for this class was generated from the following file: