1 /*
2 * This file is auto-generated. DO NOT MODIFY.
3 * Using: out/host/linux-x86/bin/aidl --lang=cpp -Weverything -Wno-missing-permission-annotation -t --min_sdk_version current --ninja -d out/soong/.intermediates/system/apex/apexd/apex_aidl_interface-cpp-source/gen/staging/android/apex/ApexInfo.cpp.d -h out/soong/.intermediates/system/apex/apexd/apex_aidl_interface-cpp-source/gen/include/staging -o out/soong/.intermediates/system/apex/apexd/apex_aidl_interface-cpp-source/gen/staging -Nsystem/apex/apexd/aidl system/apex/apexd/aidl/android/apex/ApexInfo.aidl
4 *
5 * DO NOT CHECK THIS FILE INTO A CODE TREE (e.g. git, etc..).
6 * ALWAYS GENERATE THIS FILE FROM UPDATED AIDL COMPILER
7 * AS A BUILD INTERMEDIATE ONLY. THIS IS NOT SOURCE CODE.
8 */
9 #pragma once
10
11 #include <android/apex/ApexInfo.h>
12 #include <android/binder_to_string.h>
13 #include <array>
14 #include <binder/Enums.h>
15 #include <binder/Parcel.h>
16 #include <binder/Status.h>
17 #include <cstdint>
18 #include <string>
19 #include <tuple>
20 #include <utils/String16.h>
21
22 namespace android {
23 namespace apex {
24 class LIBBINDER_EXPORTED ApexInfo : public ::android::Parcelable {
25 public:
26 enum class Partition : int8_t {
27 SYSTEM = 0,
28 SYSTEM_EXT = 1,
29 PRODUCT = 2,
30 VENDOR = 3,
31 ODM = 4,
32 };
33 ::std::string moduleName;
34 ::std::string modulePath;
35 ::std::string preinstalledModulePath;
36 int64_t versionCode = 0L;
37 ::std::string versionName;
38 bool isFactory = false;
39 bool isActive = false;
40 bool hasClassPathJars = false;
41 bool activeApexChanged = false;
42 ::android::apex::ApexInfo::Partition partition = ::android::apex::ApexInfo::Partition(0);
43 inline bool operator==(const ApexInfo& _rhs) const {
44 return std::tie(moduleName, modulePath, preinstalledModulePath, versionCode, versionName, isFactory, isActive, hasClassPathJars, activeApexChanged, partition) == std::tie(_rhs.moduleName, _rhs.modulePath, _rhs.preinstalledModulePath, _rhs.versionCode, _rhs.versionName, _rhs.isFactory, _rhs.isActive, _rhs.hasClassPathJars, _rhs.activeApexChanged, _rhs.partition);
45 }
46 inline bool operator<(const ApexInfo& _rhs) const {
47 return std::tie(moduleName, modulePath, preinstalledModulePath, versionCode, versionName, isFactory, isActive, hasClassPathJars, activeApexChanged, partition) < std::tie(_rhs.moduleName, _rhs.modulePath, _rhs.preinstalledModulePath, _rhs.versionCode, _rhs.versionName, _rhs.isFactory, _rhs.isActive, _rhs.hasClassPathJars, _rhs.activeApexChanged, _rhs.partition);
48 }
49 inline bool operator!=(const ApexInfo& _rhs) const {
50 return !(*this == _rhs);
51 }
52 inline bool operator>(const ApexInfo& _rhs) const {
53 return _rhs < *this;
54 }
55 inline bool operator>=(const ApexInfo& _rhs) const {
56 return !(*this < _rhs);
57 }
58 inline bool operator<=(const ApexInfo& _rhs) const {
59 return !(_rhs < *this);
60 }
61
62 ::android::status_t readFromParcel(const ::android::Parcel* _aidl_parcel) final;
63 ::android::status_t writeToParcel(::android::Parcel* _aidl_parcel) const final;
getParcelableDescriptor()64 static const ::android::String16& getParcelableDescriptor() {
65 static const ::android::StaticString16 DESCRIPTOR (u"android.apex.ApexInfo");
66 return DESCRIPTOR;
67 }
toString()68 inline std::string toString() const {
69 std::ostringstream _aidl_os;
70 _aidl_os << "ApexInfo{";
71 _aidl_os << "moduleName: " << ::android::internal::ToString(moduleName);
72 _aidl_os << ", modulePath: " << ::android::internal::ToString(modulePath);
73 _aidl_os << ", preinstalledModulePath: " << ::android::internal::ToString(preinstalledModulePath);
74 _aidl_os << ", versionCode: " << ::android::internal::ToString(versionCode);
75 _aidl_os << ", versionName: " << ::android::internal::ToString(versionName);
76 _aidl_os << ", isFactory: " << ::android::internal::ToString(isFactory);
77 _aidl_os << ", isActive: " << ::android::internal::ToString(isActive);
78 _aidl_os << ", hasClassPathJars: " << ::android::internal::ToString(hasClassPathJars);
79 _aidl_os << ", activeApexChanged: " << ::android::internal::ToString(activeApexChanged);
80 _aidl_os << ", partition: " << ::android::internal::ToString(partition);
81 _aidl_os << "}";
82 return _aidl_os.str();
83 }
84 }; // class ApexInfo
85 } // namespace apex
86 } // namespace android
87 namespace android {
88 namespace apex {
toString(ApexInfo::Partition val)89 [[nodiscard]] static inline std::string toString(ApexInfo::Partition val) {
90 switch(val) {
91 case ApexInfo::Partition::SYSTEM:
92 return "SYSTEM";
93 case ApexInfo::Partition::SYSTEM_EXT:
94 return "SYSTEM_EXT";
95 case ApexInfo::Partition::PRODUCT:
96 return "PRODUCT";
97 case ApexInfo::Partition::VENDOR:
98 return "VENDOR";
99 case ApexInfo::Partition::ODM:
100 return "ODM";
101 default:
102 return std::to_string(static_cast<int8_t>(val));
103 }
104 }
105 } // namespace apex
106 } // namespace android
107 namespace android {
108 namespace internal {
109 #pragma clang diagnostic push
110 #pragma clang diagnostic ignored "-Wc++17-extensions"
111 template <>
112 constexpr inline std::array<::android::apex::ApexInfo::Partition, 5> enum_values<::android::apex::ApexInfo::Partition> = {
113 ::android::apex::ApexInfo::Partition::SYSTEM,
114 ::android::apex::ApexInfo::Partition::SYSTEM_EXT,
115 ::android::apex::ApexInfo::Partition::PRODUCT,
116 ::android::apex::ApexInfo::Partition::VENDOR,
117 ::android::apex::ApexInfo::Partition::ODM,
118 };
119 #pragma clang diagnostic pop
120 } // namespace internal
121 } // namespace android
122