Tie application code to master ledger code.

This commit is contained in:
JoelKatz
2011-12-13 12:16:17 -08:00
parent d8f608abff
commit 91f0443e29

View File

@@ -7,7 +7,9 @@
#include "TimingService.h"
#include "PubKeyCache.h"
#include "ScopedLock.h"
#include "LedgerMaster.h"
#include "Wallet.h"
#include "Peer.h"
#include "database/database.h"
#include <boost/asio.hpp>
@@ -15,7 +17,6 @@
class RPCDoor;
class PeerDoor;
class Application
{
TimingService mTimingService;
@@ -23,14 +24,17 @@ class Application
KnownNodeList mKnownNodes;
Wallet mWallet;
PubKeyCache mPKCache;
LedgerMaster mMasterLedger;
Database* mDatabase;
ConnectionPool mConnectionPool;
PeerDoor* mPeerDoor;
RPCDoor* mRPCDoor;
//Serializer* mSerializer;
std::map<std::string, Peer::pointer> mPeerMap;
boost::recursive_mutex mPeerMapLock;
boost::asio::io_service mIOService;
boost::recursive_mutex dbLock;
@@ -43,6 +47,7 @@ public:
Wallet& getWallet() { return(mWallet); }
PubKeyCache& getPubKeyCache() { return mPKCache; }
Database* getDB() { return(mDatabase); }
LedgerMaster& getMasterLedger() { return mMasterLedger; }
ScopedLock getDBLock() { return ScopedLock(dbLock); }
void setDB(Database* db) { mDatabase=db; }