@@ -63,18 +63,6 @@ def is_valid_bssid(bssid) -> bool:
63
63
64
64
return False
65
65
66
- @staticmethod
67
- def is_valid_uint_value (value , bit_count = 64 ):
68
- """
69
- Checks if 'value' is a non-negative integer fitting into 'bit_count' bits.
70
- For example, bit_count=32 => must fit within 0 <= value <= 0xFFFFFFFF
71
- """
72
- if not isinstance (value , int ):
73
- return False
74
- if value < 0 :
75
- return False
76
- return value < 2 ** bit_count
77
-
78
66
def assert_valid_bssid (self , value , field_name ):
79
67
"""Asserts that the value is a valid BSSID (MAC address), None, or NullValue."""
80
68
if isinstance (value , Nullable ):
@@ -86,26 +74,6 @@ def assert_valid_bssid(self, value, field_name):
86
74
asserts .assert_true (self .is_valid_bssid (value ),
87
75
f"{ field_name } should be a valid BSSID string (e.g., '00:11:22:33:44:55') or None/NullValue." )
88
76
89
- def assert_valid_uint64 (self , value , field_name ):
90
- """Asserts that the value is a valid uint64 or None (if attribute can return NULL)."""
91
- asserts .assert_true (value is None or self .is_valid_uint_value (value , bit_count = 64 ),
92
- f"{ field_name } should be a uint64 or NULL." )
93
-
94
- def assert_valid_uint32 (self , value , field_name ):
95
- """Asserts that the value is a valid uint32 or None (if attribute can return NULL)."""
96
- asserts .assert_true (value is None or self .is_valid_uint_value (value , bit_count = 32 ),
97
- f"{ field_name } should be a uint32 or NULL." )
98
-
99
- def assert_valid_uint16 (self , value , field_name ):
100
- """Asserts that the value is a valid uint16 or None (if attribute can return NULL)."""
101
- asserts .assert_true (value is None or self .is_valid_uint_value (value , bit_count = 16 ),
102
- f"{ field_name } should be a uint16 or NULL." )
103
-
104
- def assert_valid_uint8 (self , value , field_name ):
105
- """Asserts that the value is a valid uint16 or None (if attribute can return NULL)."""
106
- asserts .assert_true (value is None or self .is_valid_uint_value (value , bit_count = 8 ),
107
- f"{ field_name } should be a uint8 or NULL." )
108
-
109
77
async def read_dgwifi_attribute_expect_success (self , endpoint , attribute ):
110
78
cluster = Clusters .Objects .WiFiNetworkDiagnostics
111
79
return await self .read_single_attribute_check_success (endpoint = endpoint , cluster = cluster , attribute = attribute )
0 commit comments