1 /*
2  * This file is auto-generated.  DO NOT MODIFY.
3  * Using: out/host/linux-x86/bin/aidl --lang=ndk -Weverything -Wno-missing-permission-annotation --structured --version 4 --hash notfrozen -t --stability vintf --min_sdk_version 33 --previous_api_dir=hardware/interfaces/contexthub/aidl/aidl_api/android.hardware.contexthub/3 --previous_hash 03f1982c8e20e58494a4ff8c9736b1c257dfeb6c --ninja -d out/soong/.intermediates/hardware/interfaces/contexthub/aidl/android.hardware.contexthub-V4-ndk-source/gen/staging/android/hardware/contexthub/IContextHubCallback.cpp.d -h out/soong/.intermediates/hardware/interfaces/contexthub/aidl/android.hardware.contexthub-V4-ndk-source/gen/include/staging -o out/soong/.intermediates/hardware/interfaces/contexthub/aidl/android.hardware.contexthub-V4-ndk-source/gen/staging -Nhardware/interfaces/contexthub/aidl hardware/interfaces/contexthub/aidl/android/hardware/contexthub/IContextHubCallback.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 <cstdint>
12 #include <memory>
13 #include <optional>
14 #include <string>
15 #include <vector>
16 #include <android/binder_interface_utils.h>
17 #include <aidl/android/hardware/contexthub/AsyncEventType.h>
18 #include <aidl/android/hardware/contexthub/ContextHubMessage.h>
19 #include <aidl/android/hardware/contexthub/MessageDeliveryStatus.h>
20 #include <aidl/android/hardware/contexthub/NanSessionRequest.h>
21 #include <aidl/android/hardware/contexthub/NanoappInfo.h>
22 #ifdef BINDER_STABILITY_SUPPORT
23 #include <android/binder_stability.h>
24 #endif  // BINDER_STABILITY_SUPPORT
25 
26 namespace aidl::android::hardware::contexthub {
27 class ContextHubMessage;
28 class MessageDeliveryStatus;
29 class NanSessionRequest;
30 class NanoappInfo;
31 }  // namespace aidl::android::hardware::contexthub
32 namespace aidl {
33 namespace android {
34 namespace hardware {
35 namespace contexthub {
36 class IContextHubCallbackDelegator;
37 
38 class IContextHubCallback : public ::ndk::ICInterface {
39 public:
40   typedef IContextHubCallbackDelegator DefaultDelegator;
41   static const char* descriptor;
42   IContextHubCallback();
43   virtual ~IContextHubCallback();
44 
45   enum : int32_t { CONTEXTHUB_NAN_TRANSACTION_TIMEOUT_MS = 10000 };
46   static inline const int32_t version = true ? 3 : 4;
47   static inline const std::string hash = true ? "03f1982c8e20e58494a4ff8c9736b1c257dfeb6c" : "notfrozen";
48   static constexpr uint32_t TRANSACTION_handleNanoappInfo = FIRST_CALL_TRANSACTION + 0;
49   static constexpr uint32_t TRANSACTION_handleContextHubMessage = FIRST_CALL_TRANSACTION + 1;
50   static constexpr uint32_t TRANSACTION_handleContextHubAsyncEvent = FIRST_CALL_TRANSACTION + 2;
51   static constexpr uint32_t TRANSACTION_handleTransactionResult = FIRST_CALL_TRANSACTION + 3;
52   static constexpr uint32_t TRANSACTION_handleNanSessionRequest = FIRST_CALL_TRANSACTION + 4;
53   static constexpr uint32_t TRANSACTION_handleMessageDeliveryStatus = FIRST_CALL_TRANSACTION + 5;
54   static constexpr uint32_t TRANSACTION_getUuid = FIRST_CALL_TRANSACTION + 6;
55   static constexpr uint32_t TRANSACTION_getName = FIRST_CALL_TRANSACTION + 7;
56 
57   static std::shared_ptr<IContextHubCallback> fromBinder(const ::ndk::SpAIBinder& binder);
58   static binder_status_t writeToParcel(AParcel* parcel, const std::shared_ptr<IContextHubCallback>& instance);
59   static binder_status_t readFromParcel(const AParcel* parcel, std::shared_ptr<IContextHubCallback>* instance);
60   static bool setDefaultImpl(const std::shared_ptr<IContextHubCallback>& impl);
61   static const std::shared_ptr<IContextHubCallback>& getDefaultImpl();
62   virtual ::ndk::ScopedAStatus handleNanoappInfo(const std::vector<::aidl::android::hardware::contexthub::NanoappInfo>& in_appInfo) = 0;
63   virtual ::ndk::ScopedAStatus handleContextHubMessage(const ::aidl::android::hardware::contexthub::ContextHubMessage& in_msg, const std::vector<std::string>& in_msgContentPerms) = 0;
64   virtual ::ndk::ScopedAStatus handleContextHubAsyncEvent(::aidl::android::hardware::contexthub::AsyncEventType in_evt) = 0;
65   virtual ::ndk::ScopedAStatus handleTransactionResult(int32_t in_transactionId, bool in_success) = 0;
66   virtual ::ndk::ScopedAStatus handleNanSessionRequest(const ::aidl::android::hardware::contexthub::NanSessionRequest& in_request) = 0;
67   virtual ::ndk::ScopedAStatus handleMessageDeliveryStatus(char16_t in_hostEndpointId, const ::aidl::android::hardware::contexthub::MessageDeliveryStatus& in_messageDeliveryStatus) = 0;
68   virtual ::ndk::ScopedAStatus getUuid(std::array<uint8_t, 16>* _aidl_return) = 0;
69   virtual ::ndk::ScopedAStatus getName(std::string* _aidl_return) = 0;
70   virtual ::ndk::ScopedAStatus getInterfaceVersion(int32_t* _aidl_return) = 0;
71   virtual ::ndk::ScopedAStatus getInterfaceHash(std::string* _aidl_return) = 0;
72 private:
73   static std::shared_ptr<IContextHubCallback> default_impl;
74 };
75 class IContextHubCallbackDefault : public IContextHubCallback {
76 public:
77   ::ndk::ScopedAStatus handleNanoappInfo(const std::vector<::aidl::android::hardware::contexthub::NanoappInfo>& in_appInfo) override;
78   ::ndk::ScopedAStatus handleContextHubMessage(const ::aidl::android::hardware::contexthub::ContextHubMessage& in_msg, const std::vector<std::string>& in_msgContentPerms) override;
79   ::ndk::ScopedAStatus handleContextHubAsyncEvent(::aidl::android::hardware::contexthub::AsyncEventType in_evt) override;
80   ::ndk::ScopedAStatus handleTransactionResult(int32_t in_transactionId, bool in_success) override;
81   ::ndk::ScopedAStatus handleNanSessionRequest(const ::aidl::android::hardware::contexthub::NanSessionRequest& in_request) override;
82   ::ndk::ScopedAStatus handleMessageDeliveryStatus(char16_t in_hostEndpointId, const ::aidl::android::hardware::contexthub::MessageDeliveryStatus& in_messageDeliveryStatus) override;
83   ::ndk::ScopedAStatus getUuid(std::array<uint8_t, 16>* _aidl_return) override;
84   ::ndk::ScopedAStatus getName(std::string* _aidl_return) override;
85   ::ndk::ScopedAStatus getInterfaceVersion(int32_t* _aidl_return) override;
86   ::ndk::ScopedAStatus getInterfaceHash(std::string* _aidl_return) override;
87   ::ndk::SpAIBinder asBinder() override;
88   bool isRemote() override;
89 };
90 }  // namespace contexthub
91 }  // namespace hardware
92 }  // namespace android
93 }  // namespace aidl
94