1 #ifndef __ST_HYPERCACHECONFIG_H
2 #define __ST_HYPERCACHECONFIG_H
4 #include "StHyperUtilGeneric.h"
5 #include "StHyperSingleton.h"
19 bool setParameter(
const std::string key, std::string value) {
20 std::pair<std::map<std::string, std::string>::iterator,
bool> ret;
21 ret = m_CacheConfig.insert( std::pair<std::string, std::string>(key, value) );
26 bool setParameter(
const std::string key, T value) {
27 std::string val = StHyperUtilGeneric::toString(value);
28 std::pair<std::map<std::string, std::string>::iterator,
bool> ret;
29 ret = m_CacheConfig.insert( std::pair<std::string, std::string>(key, value) );
34 T getParameter(
const std::string key) {
36 std::map<std::string,std::string>::iterator it;
37 it = m_CacheConfig.find(key);
38 if ( it != m_CacheConfig.end() ) {
39 obj = StHyperUtilGeneric::fromString<T>((*it).second);
41 obj = StHyperUtilGeneric::fromString<T>(
"");
52 std::map<std::string,std::string> m_CacheConfig;
56 #endif // __ST_HYPERCACHE_CONFIG_H