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 SyscapNdk 18 * @{ 19 * 20 * @brief Provides APIs for querying system capabilities. 21 * 22 * @since 10 23 */ 24 25 /** 26 * @file syscap_ndk.h 27 * @kit BasicServicesKit 28 * @brief Declares APIs for acquiring the set of system capabilities . 29 * @library NA 30 * @syscap SystemCapability.Startup.SystemInfo 31 * @since 10 32 */ 33 34 #ifndef SYSCAP_NDK_H 35 #define SYSCAP_NDK_H 36 37 #include <stdbool.h> 38 39 #ifdef __cplusplus 40 #if __cplusplus 41 extern "C" { 42 #endif 43 #endif 44 45 /** 46 * @brief Queries whether a device supports a specified SystemCapability. 47 * @param cap SystemCapability whether supported 48 * @return true - Supports the specified SystemCapability. 49 * false - The specified SystemCapability is not supported. 50 * @since 8 51 */ 52 bool canIUse(const char *cap); 53 54 #ifdef __cplusplus 55 #if __cplusplus 56 } 57 #endif 58 #endif 59 #endif 60 /** @} */ 61