Changed PkgName type from Optional<String> to String PART 5
authorJan Olszak <j.olszak@samsung.com>
Thu, 3 Jan 2013 14:41:42 +0000 (15:41 +0100)
committerGerrit Code Review <gerrit2@kim11>
Fri, 18 Jan 2013 08:55:02 +0000 (17:55 +0900)
[Issue] Deleting temporary API.
[Bug] N/A
[Cause] N/A
[Solution] Changed Pkgname type, changed api methods.
[Verification] Build commons, installer. Run all tests.

Change-Id: If76af2c0b9655260a8b35883bf693e30128cb66a

modules/widget_dao/dao/widget_dao.cpp
modules/widget_dao/dao/widget_dao_read_only.cpp
modules/widget_dao/include/dpl/wrt-dao-ro/common_dao_types.h
modules/widget_dao/include/dpl/wrt-dao-ro/widget_dao_read_only.h
modules/widget_dao/include/dpl/wrt-dao-rw/widget_dao.h

index e078797..1c73f94 100644 (file)
@@ -96,15 +96,7 @@ void WidgetDAO::setProperty(
     }
 }
 
-void WidgetDAO::setPkgName(const DPL::OptionalString& pkgName)
-{
-
-   // if(!!pkgName)
-        setPkgName_TEMPORARY_API(*pkgName);
-}
-
-
-void WidgetDAO::setPkgName_TEMPORARY_API(const WidgetPkgName& pkgName)
+void WidgetDAO::setPkgName(const WidgetPkgName& pkgName)
 {
     SQL_CONNECTION_EXCEPTION_HANDLER_BEGIN
     {
index ade490b..7adaf41 100644 (file)
@@ -413,16 +413,6 @@ WidgetPkgNameList WidgetDAOReadOnly::getPkgnameList()
     SQL_CONNECTION_EXCEPTION_HANDLER_END("Failed to get Pkgname list")
 }
 
-WidgetPkgNameList_TEMPORARY_API WidgetDAOReadOnly::getPkgnameList_TEMPORARY_API()
-{
-    LogDebug("Getting Pkgname List ");
-    SQL_CONNECTION_EXCEPTION_HANDLER_BEGIN
-    {
-        WRT_DB_SELECT(select, WidgetInfo, &WrtDatabase::interface())
-        return select->GetValueList<WidgetInfo::pkgname>();
-    }
-    SQL_CONNECTION_EXCEPTION_HANDLER_END("Failed to get Pkgname list")
-}
 
 DbWidgetDAOReadOnlyList WidgetDAOReadOnly::getWidgetList()
 {
@@ -528,11 +518,6 @@ WidgetGUID WidgetDAOReadOnly::getGUID() const
     return row.Get_widget_id();
 }
 
-DPL::OptionalString WidgetDAOReadOnly::getPkgname() const
-{
-    return DPL::OptionalString(getPkgName());
-}
-
 DPL::OptionalString WidgetDAOReadOnly::getDefaultlocale() const
 {
     WidgetInfoRow row = getWidgetInfoRow(m_widgetHandle);
index 444f176..3620658 100644 (file)
@@ -237,7 +237,6 @@ typedef std::multiset<DbWidgetFeature> DbWidgetFeatureSet;
 typedef std::list<DbWidgetHandle> DbWidgetHandleList;
 
 typedef std::list<WidgetPkgName> WidgetPkgNameList; //TODO: this cannot be null -> appropriate changes in db schema needed
-typedef std::list<WidgetPkgName> WidgetPkgNameList_TEMPORARY_API; //TODO: this cannot be null -> appropriate changes in db schema needed
 
 class WidgetDAOReadOnly; //forward declaration
 typedef std::shared_ptr<WidgetDAOReadOnly> WidgetDAOReadOnlyPtr;
index f454637..8be742c 100644 (file)
@@ -373,15 +373,6 @@ class WidgetDAOReadOnly
 
 
     /**
-    * This method returns the Package name of the widget.
-    *
-    * @return pkgname
-    * @exception WRT_CONF_ERR_EMDB_FAILURE - Fail to query DB table.
-    * @exception WRT_CONF_ERR_EMDB_NO_RECORD - Can not find matching records in DB table.
-    */
-    DPL::OptionalString getPkgname() const;
-
-    /**
      * This method returns the defaultlocale for the widget.
      *
      * @return defaultlocale
@@ -574,7 +565,6 @@ class WidgetDAOReadOnly
      * @return list of pkgname of installed packages
      */
     static WidgetPkgNameList getPkgnameList();
-    static WidgetPkgNameList_TEMPORARY_API getPkgnameList_TEMPORARY_API();
 
     /**
      * This method returns a list of all the installed widgets.
index 3f7b819..3137c24 100644 (file)
@@ -132,8 +132,7 @@ class WidgetDAO : public WidgetDAOReadOnly
 
     /* set PkgName
      */
-    void setPkgName(const DPL::OptionalString& pkgName);
-    void setPkgName_TEMPORARY_API(const WidgetPkgName& pkgName);
+    void setPkgName(const WidgetPkgName& pkgName);
 
     /* This function will update of api-feature status.
      * If status is true (feature rejected) plugin connected with this