|
PST File Format SDK v0.4
|
Contains the actual key value pairs of the btree. More...
#include <page.h>
Inheritance diagram for pstsdk::bt_leaf_page< K, V >:
Collaboration diagram for pstsdk::bt_leaf_page< K, V >:Public Member Functions | |
| bt_leaf_page (const shared_db_ptr &db, const page_info &pi, std::vector< std::pair< K, V > > data) | |
| Construct a leaf page from disk. | |
| const V & | get_value (uint pos) const |
| Returns the value at the associated position on this leaf node. | |
| const K & | get_key (uint pos) const |
| Returns the key at the specified position. | |
| uint | num_values () const |
| Returns the number of entries in this btree_node. | |
Public Member Functions inherited from pstsdk::bt_page< K, V > | |
| bt_page (const shared_db_ptr &db, const page_info &pi, ushort level) | |
| Construct a bt_page from disk. | |
| ushort | get_level () const |
| Returns the level of this bt_page. | |
Public Member Functions inherited from pstsdk::page | |
| page (const shared_db_ptr &db, const page_info &pi) | |
| Construct a page from disk. | |
| page_id | get_page_id () const |
| Get the page id. | |
| ulonglong | get_address () const |
| Get the physical address of this page. | |
Public Member Functions inherited from pstsdk::btree_node< K, V > | |
| virtual | ~btree_node () |
| const_iterator | begin () const |
| Returns a STL style iterator positioned at the first entry. | |
| const_iterator | end () const |
| Returns a STL style iterator positioned at the "end" entry. | |
| int | binary_search (const K &key) const |
| Performs a binary search over the keys of this btree_node. | |
Public Member Functions inherited from pstsdk::btree_node_leaf< K, V > | |
| virtual | ~btree_node_leaf () |
| const V & | lookup (const K &key) const |
| Looks up the associated value for a given key. | |
Additional Inherited Members | |
Public Types inherited from pstsdk::btree_node< K, V > | |
| typedef const_btree_node_iter< K, V > | const_iterator |
Protected Member Functions inherited from pstsdk::page | |
| shared_db_ptr | get_db_ptr () const |
Protected Member Functions inherited from pstsdk::btree_node_leaf< K, V > | |
| void | first (btree_iter_impl< K, V > &iter) const |
| Positions the iterator at the first element on this tree. | |
| void | last (btree_iter_impl< K, V > &iter) const |
| Positions the iterator at the "end" element. | |
| void | next (btree_iter_impl< K, V > &iter) const |
| Moves the iterator to the next element. | |
| void | prev (btree_iter_impl< K, V > &iter) const |
| Moves the iterator to the previous element. | |
Protected Attributes inherited from pstsdk::page | |
| weak_db_ptr | m_db |
| The database context we're a member of. | |
| page_id | m_pid |
| Page id. | |
| ulonglong | m_address |
| Address of this page. | |
Contains the actual key value pairs of the btree.
| K | key type |
| V | value type |
|
inline |
|
inlinevirtual |
Returns the key at the specified position.
This is specific to this btree_node, not the entire tree
| [in] | pos | The position to retrieve the key for |
Implements pstsdk::btree_node< K, V >.
|
inlinevirtual |
Returns the value at the associated position on this leaf node.
| [in] | pos | The position to retrieve the value for |
Implements pstsdk::btree_node_leaf< K, V >.
|
inlinevirtual |
Returns the number of entries in this btree_node.
This is specific to this btree_node, not the entire tree
Implements pstsdk::btree_node< K, V >.