1 /***************************************************************************
2  *   Copyright (C) 2007 by Pierre Marchand   *
3  *   pierre@oep-h.com   *
4  *                                                                         *
5  *   This program is free software; you can redistribute it and/or modify  *
6  *   it under the terms of the GNU General Public License as published by  *
7  *   the Free Software Foundation; either version 2 of the License, or     *
8  *   (at your option) any later version.                                   *
9  *                                                                         *
10  *   This program is distributed in the hope that it will be useful,       *
11  *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
12  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
13  *   GNU General Public License for more details.                          *
14  *                                                                         *
15  *   You should have received a copy of the GNU General Public License     *
16  *   along with this program; if not, write to the                         *
17  *   Free Software Foundation, Inc.,                                       *
18  *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
19  ***************************************************************************/
20 #ifndef DATALOADER_H
21 #define DATALOADER_H
22 
23 #include <QMap>
24 #include <QString>
25 
26 /**
27 	@author Pierre Marchand <pierre@oep-h.com>
28 */
29 class DataLoader
30 {
31 
32 	QMap<QString, QMap<QString,QString> > sm;
33 	QMap<QString,QString> pm;
34 
35 	void load();
36 public:
37 	DataLoader();
~DataLoader()38 	~DataLoader(){}
39 
40 	bool update(const QString& name, const QString& sample);
41 	bool remove(const QString& name);
42 	void reload();
43 
44 
systemSamples()45 	const QMap<QString, QMap<QString,QString> >& systemSamples()const{return sm;}
userSamples()46 	const QMap<QString,QString>& userSamples()const{return pm;}
47 
48 };
49 
50 #endif
51