template<class K, class V, int S, class L = BTreeNoLock>
eckit::BTree class

B+Tree index

Public types

using key_type = K
using value_type = V
using result_type = std::pair<K, V>

Constructors, destructors, conversion operators

BTree(const PathName&, bool readOnly = false, off_t offset = 0)
~BTree()

Public functions

auto get(const K&, V&) -> bool
auto set(const K&, const V&) -> bool
void preload()
template<class T>
void range(const K& key1, const K& key2, T& result)
auto remove(const K&) -> bool
void dump(std::ostream& s = std::cout) const
auto count() const -> size_t
auto count(unsigned long page) const -> size_t
Counts the entries in a page of the tree.
void lock()
void lockShared()
void unlock()
void flock()
void funlock()
void flush()
void sync()
auto path() const -> const PathName&

Friends

auto operator<<(std::ostream& s, const BTree& p) -> std::ostream&

Function documentation

template<class K, class V, int S, class L>
size_t eckit::BTree<K, V, S, L>::count() const

Counts the entries in the whole tree This is not an efficient call since it visits the whole tree. Use with care.

This website is beyond its original expiry date and the content may be out of date. The site owner has been notified and may choose to extend the expiry date and remove this banner. If you have any questions about this, please visit our support portal.