/* * Copyright (c) 2022 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ /* * @addtogroup HdiAGnss * @{ * * @brief Provides unified APIs for the AGNSS service. * * The upper layer can use the interfaces provided by this module to set the AGNSS callback, AGNSS server address, * AGNSS reference information, and setId. * * @since 3.2 */ /* * @file IAGnssInterface.idl * * @brief Defines the agnss interfaces to set the AGNSS callback, AGNSS server address, AGNSS reference information, * and setId. * * @since 3.2 * @version 1.0 */ package ohos.hdi.location.agnss.v1_0; import ohos.hdi.location.agnss.v1_0.IAGnssCallback; import ohos.hdi.location.agnss.v1_0.AGnssTypes; /* * @brief Defines the agnss interfaces to set the AGNSS callback, AGNSS server address, AGNSS reference information, * and setId. * * @since 3.2 */ interface IAGnssInterface { /* * @brief Set the agnss callback function. * * @param callback Indicates the agnss callback to request the upper layer to establish or release data services, * request the upper layer to deliver setId, and request the upper layer to deliver the agnss reference information. * For details, see {@link IAGnssCallback}. * @return Returns 0 if setup callback successed; returns a negative value otherwise. * * @since 3.2 * @version 1.0 */ SetAgnssCallback([in] IAGnssCallback callbackObj); /* * @brief Set the Agnss Server Information. * * @param server Indicates the AGNSS server information. * For details, see {@link AGnssServerInfo}. * @return Returns 0 if setup callback successed; returns a negative value otherwise. * * @since 3.2 * @version 1.0 */ SetAgnssServer([in] struct AGnssServerInfo server); /* * @brief Ingesting Reference Information. * * @param refInfo Indicates the AGNSS reference information structure. * For details, see {@link AGnssRefInfo}. * @return Returns 0 if setup callback successed; returns a negative value otherwise. * * @since 3.2 * @version 1.0 */ SetAgnssRefInfo([in] struct AGnssRefInfo refInfo); /* * @brief Set Subscriber Identity. * * @param id Indicates the AGNSS setid information. * For details, see {@link SubscriberSetId}. * @return Returns 0 if setup callback successed; returns a negative value otherwise. * * @since 3.2 * @version 1.0 */ SetSubscriberSetId([in] struct SubscriberSetId id); }