1/* 2 * Copyright (c) 2023 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 thermal 18 * @{ 19 * 20 * @brief Provides APIs for managing, controlling, and subscribing to the device temperature. 21 * 22 * The thermal module provides APIs for the thermal service to manage, control, and subscribe to the device temperature. 23 * After obtaining an object or proxy of this module, the thermal service can invoke related APIs to manage, control, 24 * and subscribe to the device temperature. 25 * 26 * @since 3.1 27 * @version 1.1 28 */ 29 30/** 31 * @file IThermalCallback.idl 32 * 33 * @brief Provides the callback of device temperature changes. 34 * 35 * The thermal module provides the callback for the thermal service to obtain device temperature changes. 36 * 37 * @since 3.1 38 * @version 1.1 39 */ 40 41package ohos.hdi.thermal.v1_1; 42 43import ohos.hdi.thermal.v1_1.ThermalTypes; 44 45/** 46 * @brief Represents the callback of thermal status changes. 47 * 48 * After creating a callback object, the thermal service can call {@link IThermalInterface} to register a callback to 49 * subscribe to thermal status changes. 50 * 51 * @since 3.1 52 */ 53[callback] interface IThermalCallback { 54 /** 55 * @brief Callback of thermal status changes. 56 * 57 * @param event Thermal information of the device, including the device type and temperature. 58 * @see HdfThermalCallbackInfo 59 * 60 * @since 3.1 61 */ 62 OnThermalDataEvent([in] struct HdfThermalCallbackInfo event); 63} 64/** @} */ 65