[ create a new paste ] login | about

Link: http://codepad.org/eXFcuH2P    [ raw code | fork ]

chatsiri.ratana - C++, pasted on Feb 21:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#ifndef CONNECTIONDB_H
#define CONNECTIONDB_H
#include "dbclient.h"
#include "connectiondb.h"
class ConnectionDb {

public:	
	static ConnectionDb& instance(); //create instance	
	virtual void connectDb() = 0;
protected: 
	ConnectionDb();
	virtual ~ConnectionDb();
private:
	mongo::DBClientConnection connection;
	static ConnectionDb *instance_; // sub class 
	friend class DisConnection;
	

};

#endif // CONNECTIONDB_H


Create a new paste based on this one


Comments: