Refactor LoadFeeTrack into ILoadFeeTrack, split DatabaseCon out from Application.h

Conflicts:
	src/cpp/ripple/Application.cpp
This commit is contained in:
Vinnie Falco
2013-06-01 08:30:46 -07:00
parent f897b17027
commit ec732ed113
18 changed files with 394 additions and 267 deletions

View File

@@ -0,0 +1,24 @@
#ifndef RIPPLE_DATABASECON_H
#define RIPPLE_DATABASECON_H
// VFALCO: NOTE This looks like a pointless class. Figure out
// what purpose it is really trying to serve and do it better.
class DatabaseCon
{
public:
DatabaseCon (const std::string& name, const char *initString[], int countInit);
~DatabaseCon ();
Database* getDB () { return mDatabase; }
boost::recursive_mutex& getDBLock() { return mLock; }
static int getCount() { return sCount; }
// VFALCO: TODO, change "protected" to "private" throughout the code
private:
Database* mDatabase;
// VFALCO: TODO replace these with a single atomic counter.
boost::recursive_mutex mLock;
static int sCount;
};
#endif