X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/980332313bffde590173f76fd006837e0c8f3bed..a5cb4cf37e5dfa9bb9ce5c5e4ccf8d5978d3576f:/projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp?ds=sidebyside diff --git a/projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp b/projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp index 73f58145..3f47f24b 100644 --- a/projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp +++ b/projects/stargazer/plugins/configuration/sgconfig/stgconfig.cpp @@ -20,7 +20,6 @@ #include "stgconfig.h" -#include "stg/plugin_creator.h" #include "stg/common.h" #include @@ -31,14 +30,10 @@ //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -static PLUGIN_CREATOR stgc; -//----------------------------------------------------------------------------- -//----------------------------------------------------------------------------- -//----------------------------------------------------------------------------- -bool STG_CONFIG_SETTINGS::ParseSettings(const MODULE_SETTINGS & s) +bool STG_CONFIG_SETTINGS::ParseSettings(const STG::ModuleSettings & s) { - PARAM_VALUE pv; - std::vector::const_iterator pvi; + STG::ParamValue pv; + std::vector::const_iterator pvi; /////////////////////////// pv.param = "Port"; pvi = std::find(s.moduleParams.begin(), s.moduleParams.end(), pv); @@ -67,9 +62,10 @@ bool STG_CONFIG_SETTINGS::ParseSettings(const MODULE_SETTINGS & s) //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -extern "C" PLUGIN * GetPlugin() +extern "C" STG::Plugin * GetPlugin() { -return stgc.GetPlugin(); + static STG_CONFIG plugin; + return &plugin; } //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- @@ -77,7 +73,7 @@ return stgc.GetPlugin(); STG_CONFIG::STG_CONFIG() : nonstop(false), isRunning(false), - logger(GetPluginLogger(GetStgLogger(), "conf_sg")), + logger(STG::PluginLogger::get("conf_sg")), config(logger) { }