• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1  /*
2  * Copyright (c) 2024 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef HSTREAM_DEPTH_STUB_FUZZER_H
17 #define HSTREAM_DEPTH_STUB_FUZZER_H
18 
19 #include "hstream_depth_data_stub.h"
20 
21 namespace OHOS {
22 namespace CameraStandard {
23 
24 class HStreamDepthDataStubFuzz : public HStreamDepthDataStub {
25 public:
Start()26     int32_t Start() override
27     {
28         return 0;
29     }
Stop()30     int32_t Stop() override
31     {
32         return 0;
33     }
SetCallback(sptr<IStreamDepthDataCallback> & callback)34     int32_t SetCallback(sptr<IStreamDepthDataCallback>& callback) override
35     {
36         return 0;
37     }
UnSetCallback()38     int32_t UnSetCallback() override
39     {
40         return 0;
41     }
SetDataAccuracy(int32_t dataAccuracy)42     int32_t SetDataAccuracy(int32_t dataAccuracy) override
43     {
44         return 0;
45     }
Release()46     int32_t Release() override
47     {
48         return 0;
49     }
OperatePermissionCheck(uint32_t interfaceCode)50     int32_t OperatePermissionCheck(uint32_t interfaceCode) override
51     {
52         return 0;
53     }
54 };
55 
56 class HStreamDepthDataStubFuzzer {
57 public:
58 static std::shared_ptr<HStreamDepthDataStubFuzz> fuzz_;
59 static void OnRemoteRequest(int32_t code);
60 };
61 } //CameraStandard
62 } //OHOS
63 #endif //HSTREAM_DEPTH_STUB_FUZZER_H