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/* 17 * @addtogroup HdiAGnss 18 * @{ 19 * 20 * @brief Provides unified APIs for the AGNSS service. 21 * 22 * The upper layer can use the interfaces provided by this module to set the AGNSS callback, AGNSS server address, 23 * AGNSS reference information, and setId. 24 * 25 * @since 3.2 26 */ 27 28/* 29 * @file IAGnssCallback.idl 30 * 31 * @brief Defines the agnss callback to request the upper layer to establish or release data services, 32 * request the upper layer to deliver setId, and request the upper layer to deliver the agnss reference information. 33 * 34 * @since 3.2 35 * @version 1.0 36 */ 37 38package ohos.hdi.location.agnss.v1_0; 39 40import ohos.hdi.location.agnss.v1_0.AGnssTypes; 41 42/* 43 * @brief Defines the agnss callback to request the upper layer to establish or release data services, 44 * request the upper layer to deliver setId, and request the upper layer to deliver the agnss reference information. 45 * 46 * @since 3.2 47 */ 48[callback] interface IAGnssCallback { 49 /* 50 * @brief Request the upper layer to establish or release data services. 51 * 52 * @param request Indicates the request information for operating the data service. 53 * For details, see {@link AGnssDataLinkRequest}. 54 * @return Returns <b>0</b> if send request successed; returns a negative value otherwise. 55 * 56 * @since 3.2 57 * @version 1.0 58 */ 59 RequestSetUpAgnssDataLink([in] struct AGnssDataLinkRequest request); 60 61 /* 62 * @brief Request the upper layer to deliver the subscriber identity. 63 * 64 * @param type Indicates the type of setId. For details, see {@link SubscriberSetIdType}. 65 * @return Returns <b>0</b> if send request successed; returns a negative value otherwise. 66 * 67 * @since 3.2 68 * @version 1.0 69 */ 70 RequestSubscriberSetId([in] enum SubscriberSetIdType type); 71 72 /* 73 * @brief Request upper-layer ingest reference information. 74 * 75 * @return Returns <b>0</b> if send request successed; returns a negative value otherwise. 76 * 77 * @since 3.2 78 * @version 1.0 79 */ 80 RequestAgnssRefInfo(); 81} 82