DurableStoreImpl Class Reference

#include <DurableStoreImpl.h>

List of all members.


Detailed Description

Storage implementation specific pieces of the data store.

Definition at line 48 of file DurableStoreImpl.h.

Public Types

typedef std::map< std::string,
int > 
RefCountMap
 Map used for ref counting tables.
typedef std::vector< SerializableObject * > PrototypeVector
 Typedef for the list of objects passed to get_table.

Public Member Functions

 DurableStoreImpl (const char *classname, const char *logpath)
 Constructor (initializes the log path).
virtual ~DurableStoreImpl ()
 Destructor.
virtual int init (const StorageConfig &config)=0
virtual int get_table (DurableTableImpl **table, const std::string &db_name, int flags, PrototypeVector &prototypes)=0
 Hook to get or create the implementation-specific components of a durable table.
virtual int del_table (const std::string &db_name)=0
 Hook to remove a table (by name) from the data store.
virtual int get_table_names (StringVector *names)=0
 Hook to get all of the names of the tables in the store.

Protected Member Functions

int check_db_dir (const char *db_dir, bool *dir_exists)
 Check for the db directory.
int create_db_dir (const char *db_dir)
 Create database directory.
void prune_db_dir (const char *db_dir, int tidy_wait)
 Remove the given directory, after waiting the specified amount of time.


Member Typedef Documentation

typedef std::map<std::string, int> DurableStoreImpl::RefCountMap

Map used for ref counting tables.

Definition at line 51 of file DurableStoreImpl.h.

typedef std::vector<SerializableObject*> DurableStoreImpl::PrototypeVector

Typedef for the list of objects passed to get_table.

Definition at line 56 of file DurableStoreImpl.h.


Constructor & Destructor Documentation

DurableStoreImpl::DurableStoreImpl ( const char *  classname,
const char *  logpath 
) [inline]

Constructor (initializes the log path).

Definition at line 61 of file DurableStoreImpl.h.

virtual DurableStoreImpl::~DurableStoreImpl (  )  [inline, virtual]

Destructor.

Definition at line 67 of file DurableStoreImpl.h.


Member Function Documentation

virtual int DurableStoreImpl::init ( const StorageConfig &  config  )  [pure virtual]

Real initialization function.

virtual int DurableStoreImpl::get_table ( DurableTableImpl **  table,
const std::string &  db_name,
int  flags,
PrototypeVector prototypes 
) [pure virtual]

Hook to get or create the implementation-specific components of a durable table.

virtual int DurableStoreImpl::del_table ( const std::string &  db_name  )  [pure virtual]

Hook to remove a table (by name) from the data store.

virtual int DurableStoreImpl::get_table_names ( StringVector *  names  )  [pure virtual]

Hook to get all of the names of the tables in the store.

int DurableStoreImpl::check_db_dir ( const char *  db_dir,
bool dir_exists 
) [protected]

Check for the db directory.

Parameters:
db_dir Directory to check
dir_exists To be set if directory exists.

int DurableStoreImpl::create_db_dir ( const char *  db_dir  )  [protected]

Create database directory.

void DurableStoreImpl::prune_db_dir ( const char *  db_dir,
int  tidy_wait 
) [protected]

Remove the given directory, after waiting the specified amount of time.


The documentation for this class was generated from the following file:
Generated on Fri Dec 22 14:48:03 2006 for DTN Reference Implementation by  doxygen 1.5.1