Subversion Repositories HomeAutomation

Rev

Details | Last modification | View Log | SVN | RSS feed

Rev Author Line No. Line
1309 runge 1
/*
2
 * Database.h
3
 *
4
 *  Created on: Jul 23, 2009
5
 *      Author: Mattias Runge
6
 */
7
 
8
#ifndef DATABASE_H_
9
#define DATABASE_H_
10
 
1310 runge 11
#include <string>
12
#include <boost/make_shared.hpp>
13
#include "xml/Node.h"
14
#include "utils/Logger.h"
15
 
1309 runge 16
namespace atom {
17
namespace db {
18
 
1310 runge 19
using namespace std;
20
using namespace utils;
21
 
1309 runge 22
class Database
23
{
24
public:
1310 runge 25
    typedef boost::shared_ptr<Database> pointer;
26
 
27
    virtual ~Database();
28
 
29
    static pointer getInstance();
30
 
31
    void load(string filename);
32
 
33
    xml::Node & getRootNode();
34
 
35
private:
1309 runge 36
    Database();
1310 runge 37
 
38
    static pointer Instance;
39
 
40
    Logger LOG;
41
 
42
    xml::Node myXmlNode;
1309 runge 43
};
44
 
45
}
46
}
47
 
48
#endif /* DATABASE_H_ */