|
libmoost
|
*** This class is NOT thread safe *** More...
#include <kvds_bdb_linux.hpp>
Public Types | |
| typedef boost::shared_ptr< Db > | store_type |
Public Member Functions | |
| KvdsBdb () | |
| ~KvdsBdb () | |
| void | open (char const dsname[], bool newdb=false) |
| void | save () |
| void | close () |
| store_type & | get_store () |
| bool | put (void const *pkey, size_t const ksize, void const *pval, size_t const vsize) |
| bool | get (void const *pkey, size_t const ksize, void *pval, size_t &vsize) |
| bool | add (void const *pkey, size_t const ksize, void const *pval, size_t const vsize) |
| bool | all (void const *pkey, size_t const ksize, void *pval, size_t &vsize) |
| bool | xst (void const *pkey, size_t const ksize) |
| bool | del (void const *pkey, size_t const ksize) |
| bool | clr () |
| bool | beg () |
| bool | nxt (void *pkey, size_t &ksize) |
| bool | end () |
| bool | siz (void const *pkey, size_t const ksize, size_t &vsize) |
| bool | cnt (boost::uint64_t &cnt) |
| bool | nil (bool &isnil) |
| template<> | |
| bool | cnt (boost::uint64_t &cnt) |
| template<> | |
| bool | cnt (boost::uint64_t &cnt) |
Private Member Functions | |
| void | assert_data_store_open () const |
| void | set_next_itr () |
| int | get (Dbt &kt, Dbt &vt) |
Private Attributes | |
| store_type | pdb_ |
| Dbc * | pitr_ |
*** This class is NOT thread safe ***
Only HASH and BTREE are supported, trying to use another type will generate a link error
Definition at line 142 of file kvds_bdb_linux.hpp.
| typedef boost::shared_ptr<Db> moost::kvds::KvdsBdb< dbtypeT >::store_type |
Definition at line 145 of file kvds_bdb_linux.hpp.
| moost::kvds::KvdsBdb< dbtypeT >::KvdsBdb | ( | ) | [inline] |
Definition at line 147 of file kvds_bdb_linux.hpp.
| moost::kvds::KvdsBdb< dbtypeT >::~KvdsBdb | ( | ) | [inline] |
| bool moost::kvds::KvdsBdb< dbtypeT >::add | ( | void const * | pkey, |
| size_t const | ksize, | ||
| void const * | pval, | ||
| size_t const | vsize | ||
| ) | [inline] |
Create abuffer big enough for exists + new
Definition at line 278 of file kvds_bdb_linux.hpp.

| bool moost::kvds::KvdsBdb< dbtypeT >::all | ( | void const * | pkey, |
| size_t const | ksize, | ||
| void * | pval, | ||
| size_t & | vsize | ||
| ) | [inline] |
| void moost::kvds::KvdsBdb< dbtypeT >::assert_data_store_open | ( | ) | const [inline, private] |
| bool moost::kvds::KvdsBdb< dbtypeT >::beg | ( | ) | [inline] |
| void moost::kvds::KvdsBdb< dbtypeT >::close | ( | ) | [inline] |
| bool moost::kvds::KvdsBdb< dbtypeT >::clr | ( | ) | [inline] |
| bool moost::kvds::KvdsBdb< dbtypeT >::cnt | ( | boost::uint64_t & | cnt | ) |

| bool moost::kvds::KvdsBdb< DB_HASH >::cnt | ( | boost::uint64_t & | cnt | ) | [inline] |
Definition at line 514 of file kvds_bdb_linux.hpp.
| bool moost::kvds::KvdsBdb< DB_BTREE >::cnt | ( | boost::uint64_t & | cnt | ) | [inline] |
Definition at line 532 of file kvds_bdb_linux.hpp.
| bool moost::kvds::KvdsBdb< dbtypeT >::del | ( | void const * | pkey, |
| size_t const | ksize | ||
| ) | [inline] |
| bool moost::kvds::KvdsBdb< dbtypeT >::end | ( | ) | [inline] |
Definition at line 457 of file kvds_bdb_linux.hpp.
| bool moost::kvds::KvdsBdb< dbtypeT >::get | ( | void const * | pkey, |
| size_t const | ksize, | ||
| void * | pval, | ||
| size_t & | vsize | ||
| ) | [inline] |
| int moost::kvds::KvdsBdb< dbtypeT >::get | ( | Dbt & | kt, |
| Dbt & | vt | ||
| ) | [inline, private] |
Definition at line 501 of file kvds_bdb_linux.hpp.
| store_type& moost::kvds::KvdsBdb< dbtypeT >::get_store | ( | ) | [inline] |
You can call this to get a refernce to the underlying store. Useful if you need to do post construction configuration. For example if using a google hash or spare map you need to specify the delete/erase keys
Definition at line 198 of file kvds_bdb_linux.hpp.
| bool moost::kvds::KvdsBdb< dbtypeT >::nil | ( | bool & | isnil | ) | [inline] |
| bool moost::kvds::KvdsBdb< dbtypeT >::nxt | ( | void * | pkey, |
| size_t & | ksize | ||
| ) | [inline] |
| void moost::kvds::KvdsBdb< dbtypeT >::open | ( | char const | dsname[], |
| bool | newdb = false |
||
| ) | [inline] |
We do not support transactions!
Definition at line 160 of file kvds_bdb_linux.hpp.

| bool moost::kvds::KvdsBdb< dbtypeT >::put | ( | void const * | pkey, |
| size_t const | ksize, | ||
| void const * | pval, | ||
| size_t const | vsize | ||
| ) | [inline] |
| void moost::kvds::KvdsBdb< dbtypeT >::save | ( | ) | [inline] |
Definition at line 174 of file kvds_bdb_linux.hpp.
| void moost::kvds::KvdsBdb< dbtypeT >::set_next_itr | ( | ) | [inline, private] |
all good :)
End
Definition at line 206 of file kvds_bdb_linux.hpp.

| bool moost::kvds::KvdsBdb< dbtypeT >::siz | ( | void const * | pkey, |
| size_t const | ksize, | ||
| size_t & | vsize | ||
| ) | [inline] |
Definition at line 462 of file kvds_bdb_linux.hpp.


| bool moost::kvds::KvdsBdb< dbtypeT >::xst | ( | void const * | pkey, |
| size_t const | ksize | ||
| ) | [inline] |
store_type moost::kvds::KvdsBdb< dbtypeT >::pdb_ [private] |
Definition at line 508 of file kvds_bdb_linux.hpp.
Dbc* moost::kvds::KvdsBdb< dbtypeT >::pitr_ [private] |
Definition at line 509 of file kvds_bdb_linux.hpp.