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/IEndpointCallback.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/IEndpointCallback.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 "aidl/android/hardware/contexthub/IEndpointCallback.h"
12 
13 #include <android/binder_ibinder.h>
14 #include <cassert>
15 
16 #ifndef __BIONIC__
17 #ifndef __assert2
18 #define __assert2(a,b,c,d) ((void)0)
19 #endif
20 #endif
21 
22 namespace aidl {
23 namespace android {
24 namespace hardware {
25 namespace contexthub {
26 class BnEndpointCallback : public ::ndk::BnCInterface<IEndpointCallback> {
27 public:
28   BnEndpointCallback();
29   virtual ~BnEndpointCallback();
30   ::ndk::ScopedAStatus getInterfaceVersion(int32_t* _aidl_return) final;
31   ::ndk::ScopedAStatus getInterfaceHash(std::string* _aidl_return) final;
32 protected:
33   ::ndk::SpAIBinder createBinder() override;
34 private:
35 };
36 class IEndpointCallbackDelegator : public BnEndpointCallback {
37 public:
IEndpointCallbackDelegator(const std::shared_ptr<IEndpointCallback> & impl)38   explicit IEndpointCallbackDelegator(const std::shared_ptr<IEndpointCallback> &impl) : _impl(impl) {
39      int32_t _impl_ver = 0;
40      if (!impl->getInterfaceVersion(&_impl_ver).isOk()) {;
41         __assert2(__FILE__, __LINE__, __PRETTY_FUNCTION__, "Delegator failed to get version of the implementation.");
42      }
43      if (_impl_ver != IEndpointCallback::version) {
44         __assert2(__FILE__, __LINE__, __PRETTY_FUNCTION__, "Mismatched versions of delegator and implementation is not allowed.");
45      }
46   }
47 
onEndpointStarted(const std::vector<::aidl::android::hardware::contexthub::EndpointInfo> & in_endpointInfos)48   ::ndk::ScopedAStatus onEndpointStarted(const std::vector<::aidl::android::hardware::contexthub::EndpointInfo>& in_endpointInfos) override {
49     return _impl->onEndpointStarted(in_endpointInfos);
50   }
onEndpointStopped(const std::vector<::aidl::android::hardware::contexthub::EndpointId> & in_endpointIds,::aidl::android::hardware::contexthub::Reason in_reason)51   ::ndk::ScopedAStatus onEndpointStopped(const std::vector<::aidl::android::hardware::contexthub::EndpointId>& in_endpointIds, ::aidl::android::hardware::contexthub::Reason in_reason) override {
52     return _impl->onEndpointStopped(in_endpointIds, in_reason);
53   }
onMessageReceived(int32_t in_sessionId,const::aidl::android::hardware::contexthub::Message & in_msg)54   ::ndk::ScopedAStatus onMessageReceived(int32_t in_sessionId, const ::aidl::android::hardware::contexthub::Message& in_msg) override {
55     return _impl->onMessageReceived(in_sessionId, in_msg);
56   }
onMessageDeliveryStatusReceived(int32_t in_sessionId,const::aidl::android::hardware::contexthub::MessageDeliveryStatus & in_msgStatus)57   ::ndk::ScopedAStatus onMessageDeliveryStatusReceived(int32_t in_sessionId, const ::aidl::android::hardware::contexthub::MessageDeliveryStatus& in_msgStatus) override {
58     return _impl->onMessageDeliveryStatusReceived(in_sessionId, in_msgStatus);
59   }
onEndpointSessionOpenRequest(int32_t in_sessionId,const::aidl::android::hardware::contexthub::EndpointId & in_destination,const::aidl::android::hardware::contexthub::EndpointId & in_initiator,const std::optional<std::string> & in_serviceDescriptor)60   ::ndk::ScopedAStatus onEndpointSessionOpenRequest(int32_t in_sessionId, const ::aidl::android::hardware::contexthub::EndpointId& in_destination, const ::aidl::android::hardware::contexthub::EndpointId& in_initiator, const std::optional<std::string>& in_serviceDescriptor) override {
61     return _impl->onEndpointSessionOpenRequest(in_sessionId, in_destination, in_initiator, in_serviceDescriptor);
62   }
onCloseEndpointSession(int32_t in_sessionId,::aidl::android::hardware::contexthub::Reason in_reason)63   ::ndk::ScopedAStatus onCloseEndpointSession(int32_t in_sessionId, ::aidl::android::hardware::contexthub::Reason in_reason) override {
64     return _impl->onCloseEndpointSession(in_sessionId, in_reason);
65   }
onEndpointSessionOpenComplete(int32_t in_sessionId)66   ::ndk::ScopedAStatus onEndpointSessionOpenComplete(int32_t in_sessionId) override {
67     return _impl->onEndpointSessionOpenComplete(in_sessionId);
68   }
69 protected:
70 private:
71   std::shared_ptr<IEndpointCallback> _impl;
72 };
73 
74 }  // namespace contexthub
75 }  // namespace hardware
76 }  // namespace android
77 }  // namespace aidl
78