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 * @file 18 * @kit BasicServicesKit 19 * @arkts 1.1&1.2 20 */ 21 22/** 23 * Provides charger information includes type and protocol. 24 * 25 * @namespace charger 26 * @syscap SystemCapability.PowerManager.BatteryManager.Core 27 * @systemapi 28 * @since 10 29 */ 30declare namespace charger { 31 /** 32 * Indicates the type of the charger plugged-in. 33 * 34 * @enum { number } 35 * @syscap SystemCapability.PowerManager.BatteryManager.Core 36 * @systemapi 37 * @since 10 38 */ 39 export enum ChargeType { 40 /** 41 * Unknown type 42 * 43 * @syscap SystemCapability.PowerManager.BatteryManager.Core 44 * @systemapi 45 * @since 10 46 */ 47 NONE, 48 /** 49 * Wired normal type 50 * 51 * @syscap SystemCapability.PowerManager.BatteryManager.Core 52 * @systemapi 53 * @since 10 54 */ 55 WIRED_NORMAL, 56 /** 57 * Wired quick type 58 * 59 * @syscap SystemCapability.PowerManager.BatteryManager.Core 60 * @systemapi 61 * @since 10 62 */ 63 WIRED_QUICK, 64 /** 65 * Wired super quick type 66 * 67 * @syscap SystemCapability.PowerManager.BatteryManager.Core 68 * @systemapi 69 * @since 10 70 */ 71 WIRED_SUPER_QUICK, 72 /** 73 * Wireless normal type 74 * 75 * @syscap SystemCapability.PowerManager.BatteryManager.Core 76 * @systemapi 77 * @since 10 78 */ 79 WIRELESS_NORMAL, 80 /** 81 * Wireless quick type 82 * 83 * @syscap SystemCapability.PowerManager.BatteryManager.Core 84 * @systemapi 85 * @since 10 86 */ 87 WIRELESS_QUICK, 88 /** 89 * Wireless super quick type 90 * 91 * @syscap SystemCapability.PowerManager.BatteryManager.Core 92 * @systemapi 93 * @since 10 94 */ 95 WIRELESS_SUPER_QUICK 96 } 97} 98export default charger; 99