new dbi API additions to support threading

--HG--
extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%401101
This commit is contained in:
David Anderson
2007-07-13 19:19:30 +00:00
parent 41aa77314d
commit 93c9ffdf02
12 changed files with 202 additions and 20 deletions
+6 -1
View File
@@ -2,6 +2,7 @@
#define _INCLUDE_SM_MYSQL_DATABASE_H_
#include "MyDriver.h"
#include <IThreader.h>
class MyQuery;
class MyStatement;
@@ -22,12 +23,16 @@ public: //IDatabase
bool QuoteString(const char *str, char buffer[], size_t maxlen, size_t *newSize);
unsigned int GetAffectedRows();
unsigned int GetInsertID();
bool LockForFullAtomicOperation();
void UnlockFromFullAtomicOperation();
void IncReferenceCount();
IDBDriver *GetDriver();
public:
const DatabaseInfo &GetInfo();
void IncRefCount();
private:
MYSQL *m_mysql;
unsigned int m_refcount;
IMutex *m_pFullLock;
/* ---------- */
DatabaseInfo m_Info;