static const char BUNDLE_KEY_PREFIX_OSP[] = "__OSP_";
const char TIZEN_NOTIFICATION_DATA[] = "http://tizen.org/appcontrol/data/notification";
-static const char SAMSUNG_ACCOUNT_KEY_CLIENT_ID[] = "client_id";
-static const char SAMSUNG_ACCOUNT_KEY_CLIENT_SECRET[] = "client_secret";
-static const char SAMSUNG_ACCOUNT_KEY_SERVICE_CATEGORY[] = "service_category";
-
-static const char SMS_KEY_SERVICE_CALLER[] = "service_caller";
-static const char SMS_KEY_SERVICE_DATA[] = "service_data";
-
_AppArg::_AppArg(void)
: __pBundle(null)
SysLog(NID_APP, "argument is %s", p);
}
- String tmp;
- p = appsvc_get_data(pBundle, SMS_KEY_SERVICE_CALLER);
- if (p)
- {
- tmp.Format(60, L"%s:%s", SMS_KEY_SERVICE_CALLER, p);
- pList->Add(*new (std::nothrow) String(tmp));
- SysLog(NID_APP, "service_caller is %s", p);
- }
-
- p = appsvc_get_data(pBundle, SMS_KEY_SERVICE_DATA);
- if (p)
- {
- tmp.Format(60, L"%s:%s", SMS_KEY_SERVICE_DATA, p);
- pList->Add(*new (std::nothrow) String(tmp));
- SysLog(NID_APP, "service_data is set");
- }
-
- p = appsvc_get_data(pBundle, SAMSUNG_ACCOUNT_KEY_CLIENT_ID);
- if (p)
- {
- tmp.Format(60, L"%s:%s", SAMSUNG_ACCOUNT_KEY_CLIENT_ID, p);
- pList->Add(*new (std::nothrow) String(tmp));
- SysLog(NID_APP, "client_id is %s", p);
- }
-
- p = appsvc_get_data(pBundle, SAMSUNG_ACCOUNT_KEY_CLIENT_SECRET);
- if (p)
- {
- tmp.Format(60, L"%s:%s", SAMSUNG_ACCOUNT_KEY_CLIENT_SECRET, p);
- pList->Add(*new (std::nothrow) String(tmp));
- SysLog(NID_APP, "client_secret is %s", p);
- }
-
- p = appsvc_get_data(pBundle, SAMSUNG_ACCOUNT_KEY_SERVICE_CATEGORY);
- if (p)
- {
- tmp.Format(60, L"%s:%s", SAMSUNG_ACCOUNT_KEY_SERVICE_CATEGORY, p);
- pList->Add(*new (std::nothrow) String(tmp));
- SysLog(NID_APP, "service_category is %s", p);
- }
-
return E_SUCCESS;
}
}
}
+
+void
+_AppArg::UpdateSubMode(bundle* pBundle)
+{
+ appsvc_add_data(pBundle, OSP_K_SUBMODE_CALLEE, "1");
+}
+
+
+bool
+_AppArg::IsSubMode(bundle* pBundle)
+{
+ const char* p = appsvc_get_data(pBundle, OSP_K_SUBMODE_CALLEE);
+ if (p && (strncmp(p, "1", sizeof(char)) == 0))
+ {
+ return true;
+ }
+
+ return false;
+}
+
+
int
_AppArg::GetRequestIdFromBundle(bundle* pBundle)
{