• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2022 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 AGNSS_EVENT_CALLBACK_MOCK_H
17 #define AGNSS_EVENT_CALLBACK_MOCK_H
18 
19 #include "iremote_stub.h"
20 #include "iremote_object.h"
21 #include <hdf_base.h>
22 
23 #include <iproxy_broker.h>
24 #include <v2_0/ia_gnss_callback.h>
25 #include "v2_0/ia_gnss_callback.h"
26 
27 namespace OHOS {
28 namespace HDI {
29 namespace Location {
30 namespace Agnss {
31 namespace V2_0 {
32 
33 class IAgnssEventCallback : public IAGnssCallback {
34 public:
35     DECLARE_HDI_DESCRIPTOR(u"ohos.hdi.location.agnss.v2_0.IAGnssCallback");
36 };
37 
38 class AgnssEventCallbackMock : public IProxyBroker<IAgnssEventCallback> {
39 public:
AgnssEventCallbackMock(const sptr<IRemoteObject> & remote)40     explicit AgnssEventCallbackMock(const sptr<IRemoteObject>& remote)
41         : IProxyBroker<IAgnssEventCallback>(remote) {
42     }
43     int32_t RequestSetUpAgnssDataLink(const OHOS::HDI::Location::Agnss::V2_0::AGnssDataLinkRequest& request) override;
44 
45     int32_t RequestSubscriberSetId(OHOS::HDI::Location::Agnss::V2_0::SubscriberSetIdType type) override;
46 
47     int32_t RequestAgnssRefInfo(OHOS::HDI::Location::Agnss::V2_0::AGnssRefInfoType type) override;
48 };
49 
50 } // V2_0
51 } // Agnss
52 } // Location
53 } // HDI
54 } // OHOS
55 #endif // AGNSS_EVENT_CALLBACK_MOCK_H
56