Minor changes here and there.
[aesalon.git] / include / config / Vault.h
blobcd43b12b55cc3208be5e25d2358ec62775906b61
1 /** Aesalon, a tool to visualize program behaviour in real time.
2 Copyright (C) 2009-2011, Aesalon development team.
4 Aesalon is distributed under the terms of the GNU GPLv3. See
5 the included file LICENSE for more information.
7 @file include/config/Vault.h
8 */
10 #ifndef AesalonConfig_Vault_H
11 #define AesalonConfig_Vault_H
13 #include <map>
14 #include <string>
15 #include <vector>
17 namespace Config {
19 class Vault {
20 public:
21 typedef std::pair<std::string, std::string> KeyPair;
22 private:
23 typedef std::multimap<std::string, std::string> DataMap;
24 DataMap m_dataMap;
25 public:
26 Vault();
27 virtual ~Vault() {}
29 void clear(const std::string &key);
30 void set(const std::string &key, const std::string &value);
32 std::string get(const std::string &key);
34 void get(const std::string &key, std::vector<std::string> &values);
36 void match(const std::string &pattern, std::vector<KeyPair> &values);
37 private:
38 bool matches(const std::string &string, const std::string &pattern);
41 } // namespace Config
43 #endif