X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=modules%2Fwidget_dao%2Finclude%2Fdpl%2Fwrt-dao-ro%2Ffeature_model.h;h=8698d4a4213ecee1465e0ed3c0f6d26bed856194;hb=99d2eda0b32d9fe02b094f236742a58e740c2f50;hp=13b959c6d9a46ae7cb72eb6bac39955f8f38e78f;hpb=45bf3bfbb061b87511ece6f50b1aa6c803844a65;p=framework%2Fweb%2Fwrt-commons.git diff --git a/modules/widget_dao/include/dpl/wrt-dao-ro/feature_model.h b/modules/widget_dao/include/dpl/wrt-dao-ro/feature_model.h index 13b959c..8698d4a 100644 --- a/modules/widget_dao/include/dpl/wrt-dao-ro/feature_model.h +++ b/modules/widget_dao/include/dpl/wrt-dao-ro/feature_model.h @@ -24,21 +24,25 @@ #include #include -#include +#include #include #include #include #include namespace WrtDB { - typedef int FeatureHandle; typedef std::list FeatureHandleList; -typedef DPL::SharedPtr FeatureHandleListPtr; +typedef std::shared_ptr FeatureHandleListPtr; typedef int FeatureSetHandle; typedef std::list FeatureSetHandleList; +typedef struct { + std::string featureName; + DbPluginHandle pluginHandle; +} FeatureData; + class FeatureModel : public DPL::Event::Model { public: @@ -53,12 +57,19 @@ class FeatureModel : public DPL::Event::Model Name(this), DeviceCapabilities(this), PHandle(this, -1) + {} + + void SetData(const std::string& name, + const std::set& deviceCapabilities, + const DbPluginHandle& pluginHandle) { + Name.SetWithoutLock(name); + DeviceCapabilities.SetWithoutLock(deviceCapabilities); + PHandle.SetWithoutLock(pluginHandle); } }; -typedef DPL::SharedPtr FeatureModelPtr; - +typedef std::shared_ptr FeatureModelPtr; } // namespace WrtDB #endif // FEATURE_MODEL_H