Remove unnecessary parcelable and req handlers
authorJunghyun Yeon <jungh.yeon@samsung.com>
Wed, 17 Feb 2021 07:28:11 +0000 (16:28 +0900)
committer연정현/Tizen Platform Lab(SR)/Staff Engineer/삼성전자 <jungh.yeon@samsung.com>
Wed, 17 Feb 2021 08:08:48 +0000 (17:08 +0900)
AppctrlPrivInfo and DataCtrlPrivInfo will be handled at
QueryParcelable and QueryHandler

Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
src/common/parcel/appctrlprivinfo_parcelable.cc [deleted file]
src/common/parcel/appctrlprivinfo_parcelable.hh [deleted file]
src/common/parcel/datactrlinfo_parcelable.cc [deleted file]
src/common/parcel/datactrlinfo_parcelable.hh [deleted file]
src/server/get_appctrlpriv_request_handler.cc [deleted file]
src/server/get_appctrlpriv_request_handler.hh [deleted file]
src/server/get_datacontrol_request_handler.cc [deleted file]
src/server/get_datacontrol_request_handler.hh [deleted file]

diff --git a/src/common/parcel/appctrlprivinfo_parcelable.cc b/src/common/parcel/appctrlprivinfo_parcelable.cc
deleted file mode 100644 (file)
index 4be3a5b..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (c) 2021 Samsung Electronics Co., Ltd All Rights Reserved
- *
- * Licensed under the Apache License, Version 2.0 (the License);
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an AS IS BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#include "appctrlprivinfo_parcelable.hh"
-
-#include <vector>
-
-#include "pkgmgrinfo_private.h"
-
-namespace pkgmgr_common {
-namespace parcel {
-
-bool AppCtrlPrivInfoParcelable::SetAppCtrlPrivQuery(std::string app_id) {
-  return true;
-}
-
-std::string AppCtrlPrivInfoParcelable::GetQueryAppID() { return {}; }
-
-bool AppCtrlPrivInfoParcelable::SetResult(std::string app_control,
-                                      std::string privilege) {
-  return true;
-}
-
-std::vector<std::string> AppCtrlPrivInfoParcelable::GetResultAppControl() {
-  return {};
-}
-
-std::unique_ptr<AbstractParcelable> AppCtrlPrivInfoParcelable::Deserialize(
-    std::vector<unsigned char> data) {
-  return nullptr;
-}
-
-std::unique_ptr<AbstractParcelable> AppCtrlPrivInfoParcelable::Factory::CreateParcel() {
-  return nullptr;
-}
-
-}  // namespace parcel
-}  // namespace pkgmgr_common
diff --git a/src/common/parcel/appctrlprivinfo_parcelable.hh b/src/common/parcel/appctrlprivinfo_parcelable.hh
deleted file mode 100644 (file)
index 52680aa..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-#ifndef APPCTRLPRIVINFO_PARCELABLE_HH_
-#define APPCTRLPRIVINFO_PARCELABLE_HH_
-
-#include "abstract_parcelable.hh"
-
-#include <vector>
-
-#include "pkgmgrinfo_private.h"
-
-namespace pkgmgr_common {
-namespace parcel {
-
-#ifndef EXPORT_API
-#define EXPORT_API __attribute__((visibility("default")))
-#endif
-
-class EXPORT_API AppCtrlPrivInfoParcelable : public AbstractParcelable {
- public:
-  class EXPORT_API Factory : IFactory {
-   public:
-    std::unique_ptr<AbstractParcelable> CreateParcel();
-  };
-  bool SetAppCtrlPrivQuery(std::string app_id);
-  std::string GetQueryAppID();
-  bool SetResult(std::string app_control, std::string privilege);
-  std::vector<std::string> GetResultAppControl();
-  std::unique_ptr<AbstractParcelable> Deserialize(std::vector<unsigned char> data);
-
-  virtual void WriteToParcel(tizen_base::Parcel* parcel) const {
-    parcel->WriteString("test");
-    parcel->WriteUInt32(32);
-  }
-
-  virtual void ReadFromParcel(tizen_base::Parcel* parcel) {
-    std::string a = parcel->ReadString();
-    unsigned int b;
-    parcel->ReadUInt32(&b);
-  }
-};
-
-}  // namespace parcel
-}  // namespace pkgmgr_common
-
-#endif  // APPCTRLPRIVINFO_PARCELABLE_HH_
diff --git a/src/common/parcel/datactrlinfo_parcelable.cc b/src/common/parcel/datactrlinfo_parcelable.cc
deleted file mode 100644 (file)
index 7b673d2..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2021 Samsung Electronics Co., Ltd All Rights Reserved
- *
- * Licensed under the Apache License, Version 2.0 (the License);
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an AS IS BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#include "datactrlinfo_parcelable.hh"
-
-#include <vector>
-
-#include "pkgmgrinfo_private.h"
-
-namespace pkgmgr_common {
-namespace parcel {
-
-bool DataCtrlInfoParcelable::SetDataCtrlInfoQuery(std::string providerid,
-                                              std::string type) {
-  return true;
-}
-
-std::string DataCtrlInfoParcelable::GetQueryProviderID() { return {}; }
-
-std::string DataCtrlInfoParcelable::GetQueryType() { return {}; }
-
-std::vector<std::string> DataCtrlInfoParcelable::GetResultDataCtrlInfo() {
-  return {};
-}
-
-std::unique_ptr<AbstractParcelable> DataCtrlInfoParcelable::Deserialize(
-    std::vector<unsigned char> data) {
-  return nullptr;
-}
-
-std::unique_ptr<AbstractParcelable> DataCtrlInfoParcelable::Factory::CreateParcel() {
-  return nullptr;
-}
-
-}  // namespace parcel
-}  // namespace pkgmgr_common
diff --git a/src/common/parcel/datactrlinfo_parcelable.hh b/src/common/parcel/datactrlinfo_parcelable.hh
deleted file mode 100644 (file)
index fe88e25..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-#ifndef DATACTRLINFO_PARCELABLE_HH_
-#define DATACTRLINFO_PARCELABLE_HH_
-
-#include "abstract_parcelable.hh"
-
-#include <vector>
-
-#include "pkgmgrinfo_private.h"
-
-namespace pkgmgr_common {
-namespace parcel {
-
-#ifndef EXPORT_API
-#define EXPORT_API __attribute__((visibility("default")))
-#endif
-
-class EXPORT_API DataCtrlInfoParcelable : public AbstractParcelable {
- public:
-  class EXPORT_API Factory : IFactory {
-   public:
-    std::unique_ptr<AbstractParcelable> CreateParcel();
-  };
-  bool SetDataCtrlInfoQuery(std::string providerid, std::string type);
-  std::string GetQueryProviderID();
-  std::string GetQueryType();
-  std::vector<std::string> GetResultDataCtrlInfo();
-  std::unique_ptr<AbstractParcelable> Deserialize(std::vector<unsigned char> data);
-
-  virtual void WriteToParcel(tizen_base::Parcel* parcel) const {
-    parcel->WriteString("test");
-    parcel->WriteUInt32(32);
-  }
-
-  virtual void ReadFromParcel(tizen_base::Parcel* parcel) {
-    std::string a = parcel->ReadString();
-    unsigned int b;
-    parcel->ReadUInt32(&b);
-  }
-};
-
-}  // namespace parcel
-}  // namespace pkgmgr_common
-
-#endif  // DATACTRLINFO_PARCELABLE_HH_
diff --git a/src/server/get_appctrlpriv_request_handler.cc b/src/server/get_appctrlpriv_request_handler.cc
deleted file mode 100644 (file)
index b88b4a5..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-// Copyright (c) 2021 Samsung Electronics Co., Ltd All Rights Reserved
-// Use of this source code is governed by an apache-2.0 license that can be
-// found in the LICENSE file.
-
-#include "get_appctrlpriv_request_handler.hh"
-
-#include <string>
-
-namespace pkgmgr_server {
-namespace request_handler {
-
-bool GetAppctrlprivRequestHandler::HandleRequest(std::string data,
-                                                 std::string locale) {
-  return true;
-}
-
-std::string GetAppctrlprivRequestHandler::GetResult() {
-  std::string tmp_result("tmp_result");
-
-  return tmp_result;
-}
-
-}  // namespace request_handler
-}  // namespace pkgmgr_server
diff --git a/src/server/get_appctrlpriv_request_handler.hh b/src/server/get_appctrlpriv_request_handler.hh
deleted file mode 100644 (file)
index d062f9e..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-// Copyright (c) 2021 Samsung Electronics Co., Ltd All Rights Reserved
-// Use of this source code is governed by an apache-2.0 license that can be
-// found in the LICENSE file.
-
-#ifndef SERVER_GET_APPCTRLPRIV_REQUEST_HANDLER_HH_
-#define SERVER_GET_APPCTRLPRIV_REQUEST_HANDLER_HH_
-
-#include "abstract_request_handler.hh"
-
-#include <string>
-
-namespace pkgmgr_server {
-namespace request_handler {
-
-#ifndef EXPORT_API
-#define EXPORT_API __attribute__((visibility("default")))
-#endif
-
-class EXPORT_API GetAppctrlprivRequestHandler : public AbstractRequestHandler {
- public:
-  bool HandleRequest(std::string data, std::string locale) override;
-
-  std::string GetResult() override;
-};
-
-}  // namespace request_handler
-}  // namespace pkgmgr_server
-
-#endif  // SERVER_GET_APPCTRLPRIV_REQUEST_HANDLER_HH_
diff --git a/src/server/get_datacontrol_request_handler.cc b/src/server/get_datacontrol_request_handler.cc
deleted file mode 100644 (file)
index 88c500e..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-// Copyright (c) 2021 Samsung Electronics Co., Ltd All Rights Reserved
-// Use of this source code is governed by an apache-2.0 license that can be
-// found in the LICENSE file.
-
-#include "get_datacontrol_request_handler.hh"
-
-#include <string>
-
-namespace pkgmgr_server {
-namespace request_handler {
-
-bool GetDatacontrolRequestHandler::HandleRequest(std::string data,
-                                                 std::string locale) {
-  return true;
-}
-
-std::string GetDatacontrolRequestHandler::GetResult() {
-  std::string tmp_result("tmp_result");
-
-  return tmp_result;
-}
-
-}  // namespace request_handler
-}  // namespace pkgmgr_server
diff --git a/src/server/get_datacontrol_request_handler.hh b/src/server/get_datacontrol_request_handler.hh
deleted file mode 100644 (file)
index 506f350..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-// Copyright (c) 2021 Samsung Electronics Co., Ltd All Rights Reserved
-// Use of this source code is governed by an apache-2.0 license that can be
-// found in the LICENSE file.
-
-#ifndef SERVER_GET_DATACONTROL_REQUEST_HANDLER_HH_
-#define SERVER_GET_DATACONTROL_REQUEST_HANDLER_HH_
-
-#include "abstract_request_handler.hh"
-
-#include <string>
-
-namespace pkgmgr_server {
-namespace request_handler {
-
-#ifndef EXPORT_API
-#define EXPORT_API __attribute__((visibility("default")))
-#endif
-
-class EXPORT_API GetDatacontrolRequestHandler : public AbstractRequestHandler {
- public:
-  bool HandleRequest(std::string data, std::string locale) override;
-
-  std::string GetResult() override;
-};
-
-}  // namespace request_handler
-}  // namespace pkgmgr_server
-
-#endif  // SERVER_GET_DATACONTROL_REQUEST_HANDLER_HH_