add get tizen package id list
authorSoyoung Kim <sy037.kim@samsung.com>
Tue, 7 May 2013 12:18:19 +0000 (21:18 +0900)
committerSoyoung Kim <sy037.kim@samsung.com>
Wed, 8 May 2013 04:17:46 +0000 (13:17 +0900)
[Issue#] N/A
[Problem] N/A
[Cause] N/A
[Solution] Add function to get package id list.
[SCMRequest] N/A

Change-Id: I173f53ef5dcb65c286eada4a950c3184adc39885

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

index 194c1ac..87815fc 100644 (file)
@@ -434,6 +434,17 @@ TizenAppIdList WidgetDAOReadOnly::getTizenAppidList()
     SQL_CONNECTION_EXCEPTION_HANDLER_END("Failed to get Pkgname list")
 }
 
+TizenPkgIdList WidgetDAOReadOnly::getTizenPkgidList()
+{
+    LogDebug("Getting Pkgid List ");
+    SQL_CONNECTION_EXCEPTION_HANDLER_BEGIN
+    {
+        WRT_DB_SELECT(select, WidgetInfo, &WrtDatabase::interface())
+        return select->GetValueList<WidgetInfo::tizen_pkgid>();
+    }
+    SQL_CONNECTION_EXCEPTION_HANDLER_END("Failed to get Pkgid list")
+}
+
 DbWidgetDAOReadOnlyList WidgetDAOReadOnly::getWidgetList()
 {
     LogDebug("Getting DbWidget List");
index 3c3c943..a91b73f 100644 (file)
@@ -219,6 +219,7 @@ typedef std::multiset<DbWidgetFeature> DbWidgetFeatureSet;
  */
 typedef std::list<DbWidgetHandle> DbWidgetHandleList;
 typedef std::list<TizenAppId> TizenAppIdList;
+typedef std::list<TizenPkgId> TizenPkgIdList;
 
 class WidgetDAOReadOnly; //forward declaration
 typedef std::shared_ptr<WidgetDAOReadOnly> WidgetDAOReadOnlyPtr;
index 1ae5364..3f9870c 100644 (file)
@@ -603,6 +603,12 @@ class WidgetDAOReadOnly
     static TizenAppIdList getTizenAppidList();
 
     /**
+     * This method returns list of tizen package list of installed packages
+     * @return list of TizenPkgIdList of installed packages
+     */
+    static TizenPkgIdList getTizenPkgidList();
+
+    /**
      * This method returns a list of all the installed widgets.
      *
      * @return list of installed widgets.