ObjectBox C and C++ API  0.12.0
obx::Store Class Reference

#include <objectbox.hpp>

Classes

class  Options
 

Public Member Functions

 Store (OBX_model *model)
 
 Store (const Options &options)
 
 Store (OBX_store *cStore)
 
 Store (const Store &)=delete
 Can't be copied, single owner of C resources is required (to avoid double-free during destruction) More...
 
 Store (Store &&source) noexcept
 
virtual ~Store ()
 
OBX_storecPtr () const
 
template<class EntityBinding >
Box< EntityBinding > box ()
 
Transaction tx (TxMode mode)
 Starts a transaction using the given mode. More...
 
Transaction txRead ()
 Starts a read(-only) transaction. More...
 
Transaction txWrite ()
 Starts a (read &) write transaction. More...
 
std::shared_ptr< SyncClientsyncClient ()
 

Constructor & Destructor Documentation

◆ Store() [1/5]

obx::Store::Store ( OBX_model model)
inlineexplicit

◆ Store() [2/5]

obx::Store::Store ( const Options options)
inlineexplicit

◆ Store() [3/5]

obx::Store::Store ( OBX_store cStore)
inlineexplicit

◆ Store() [4/5]

obx::Store::Store ( const Store )
delete

Can't be copied, single owner of C resources is required (to avoid double-free during destruction)

◆ Store() [5/5]

obx::Store::Store ( Store &&  source)
inlinenoexcept

Member Function Documentation

◆ box()

template<class EntityBinding >
Box<EntityBinding> obx::Store::box ( )
inline

◆ cPtr()

OBX_store* obx::Store::cPtr ( ) const
inline

◆ syncClient()

std::shared_ptr<SyncClient> obx::Store::syncClient ( )
inline
Returns
an existing SyncClient associated with the store (if available; see Sync::client() to create one)
Examples
/home/markus/dev/objectbox/objectbox-c/include/objectbox.hpp.