Add PkgInfoClient skeleton class
[platform/core/appfw/pkgmgr-info.git] / src / client / pkginfo_client.hh
1 // Copyright (c) 2021 Samsung Electronics Co., Ltd All Rights Reserved
2 // Use of this source code is governed by an apache-2.0 license that can be
3 // found in the LICENSE file.
4
5 #ifndef CLIENT_PKGINFO_CLIENT_HH_
6 #define CLIENT_PKGINFO_CLIENT_HH_
7
8 #include "../common/parcel/abstract_parcel.hh"
9 #include "../common/parcel/parcel_factory.hh"
10
11 #include <string>
12
13 namespace pkgmgr_client {
14
15 class PkgInfoClient {
16  public:
17   PkgInfoClient(std::shared_ptr<pkgmgr_common::parcel::AbstractParcel> parcel, uid_t uid, std::shared_ptr<pkgmgr_common::parcel::ParcelFactory> factory);
18   bool SendRequest();
19   std::shared_ptr<pkgmgr_common::parcel::AbstractParcel> GetResultParcel();
20
21  private:
22   std::shared_ptr<pkgmgr_common::parcel::AbstractParcel> parcel_;
23   uid_t uid_;
24   std::shared_ptr<pkgmgr_common::parcel::ParcelFactory> factory_;
25 };
26
27 }  // namespace pkgmgr_client
28
29 #endif  // CLIENT_PKGINFO_CLIENT_HH_