• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2022 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #ifndef HARDWARE_INTERFACES_CAMERA_PROVIDER_AIDL_VTS_TORCH_PROVIDER_CB_H_
18 #define HARDWARE_INTERFACES_CAMERA_PROVIDER_AIDL_VTS_TORCH_PROVIDER_CB_H_
19 
20 #import <aidl/android/hardware/camera/provider/BnCameraProviderCallback.h>
21 #import <camera_aidl_test.h>
22 
23 using ::aidl::android::hardware::camera::common::TorchModeStatus;
24 using ::aidl::android::hardware::camera::provider::BnCameraProviderCallback;
25 
26 class TorchProviderCb : public BnCameraProviderCallback {
27   public:
28     TorchProviderCb(CameraAidlTest* parent);
29     ndk::ScopedAStatus torchModeStatusChange(const std::string& cameraDeviceName,
30                                              TorchModeStatus newStatus) override;
31 
32     ScopedAStatus cameraDeviceStatusChange(
33             const std::string& in_cameraDeviceName,
34             ::aidl::android::hardware::camera::common::CameraDeviceStatus in_newStatus) override;
35 
36     ScopedAStatus physicalCameraDeviceStatusChange(
37             const std::string& in_cameraDeviceName, const std::string& in_physicalCameraDeviceName,
38             ::aidl::android::hardware::camera::common::CameraDeviceStatus in_newStatus) override;
39 
40   private:
41     CameraAidlTest* mParent;
42 };
43 
44 #endif  // HARDWARE_INTERFACES_CAMERA_PROVIDER_AIDL_VTS_TORCH_PROVIDER_CB_H_
45