2015-01-26 15:27:51 +00:00
|
|
|
#pragma once
|
|
|
|
|
2016-12-08 02:49:04 +00:00
|
|
|
#include <DB/Dictionaries/IDictionarySource.h>
|
2015-09-29 19:19:54 +00:00
|
|
|
#include <common/singleton.h>
|
2016-01-12 02:21:15 +00:00
|
|
|
|
2015-01-26 15:27:51 +00:00
|
|
|
|
2016-12-08 02:49:04 +00:00
|
|
|
namespace Poco
|
2015-01-26 15:27:51 +00:00
|
|
|
{
|
2016-12-08 02:49:04 +00:00
|
|
|
namespace Util
|
2015-11-12 14:28:23 +00:00
|
|
|
{
|
2016-12-08 02:49:04 +00:00
|
|
|
class AbstractConfiguration;
|
2015-10-13 15:38:08 +00:00
|
|
|
}
|
2015-01-26 15:27:51 +00:00
|
|
|
}
|
|
|
|
|
2016-12-08 02:49:04 +00:00
|
|
|
namespace DB
|
|
|
|
{
|
|
|
|
|
|
|
|
class Context;
|
2016-12-12 06:02:35 +00:00
|
|
|
struct DictionaryStructure;
|
2015-01-26 15:27:51 +00:00
|
|
|
|
2015-02-10 14:50:43 +00:00
|
|
|
/// creates IDictionarySource instance from config and DictionaryStructure
|
2015-01-26 15:27:51 +00:00
|
|
|
class DictionarySourceFactory : public Singleton<DictionarySourceFactory>
|
|
|
|
{
|
|
|
|
public:
|
2016-12-08 02:49:04 +00:00
|
|
|
DictionarySourceFactory();
|
2016-04-10 10:24:07 +00:00
|
|
|
|
2015-08-19 13:06:21 +00:00
|
|
|
DictionarySourcePtr create(
|
|
|
|
const std::string & name, Poco::Util::AbstractConfiguration & config, const std::string & config_prefix,
|
2016-12-08 02:49:04 +00:00
|
|
|
const DictionaryStructure & dict_struct, Context & context) const;
|
2015-01-26 15:27:51 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|