1 /* 2 * Copyright (c) 2025 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 #ifndef LNN_SELECT_RULE_STRUCT_H 17 #define LNN_SELECT_RULE_STRUCT_H 18 19 #include "stdint.h" 20 #include "stdbool.h" 21 22 #ifdef __cplusplus 23 extern "C" { 24 #endif 25 26 #define UNACCEPT_SCORE 20 27 28 typedef enum { 29 HIGH_BAND_WIDTH = 0, 30 MIDDLE_HIGH_BAND_WIDTH, 31 MIDDLE_LOW_BAND_WIDTH, 32 LOW_BAND_WIDTH, 33 BW_TYPE_BUTT, 34 } BandWidthType; 35 36 typedef enum { 37 CUSTOM_QOS_MESH = 0, 38 CUSTOM_QOS_DB, 39 CUSTOM_QOS_RTT, 40 CUSTOM_QOS_BUTT, 41 } CustomQos; 42 43 typedef struct { 44 bool available; 45 int32_t (*linkFeatureCheck)(const char *networkId); 46 int32_t (*getLinkScore)(const char *networkId, uint32_t expectedBw); 47 } LinkAttribute; 48 49 #ifdef __cplusplus 50 } 51 #endif 52 #endif // LNN_SELECT_RULE_H