1#![warn(clippy::all)]
3#![allow(unused_parens, unused_variables, unused_mut, unused_imports, unreachable_code)]
4
5pub mod natural {
6
7 pub type MacAddr = [u8; 6];
8
9 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
10 #[repr(u32)]
11 pub enum BssType {
12 Unknown = 0,
13 Infrastructure = 1,
14 Independent = 2,
15 Mesh = 3,
16 Personal = 4,
17 UnknownOrdinal_(u32) = 5,
18 }
19 impl ::std::convert::From<u32> for BssType {
20 fn from(value: u32) -> Self {
21 match value {
22 0 => Self::Unknown,
23 1 => Self::Infrastructure,
24 2 => Self::Independent,
25 3 => Self::Mesh,
26 4 => Self::Personal,
27
28 _ => Self::UnknownOrdinal_(value),
29 }
30 }
31 }
32
33 impl ::std::convert::From<BssType> for u32 {
34 fn from(value: BssType) -> Self {
35 match value {
36 BssType::Unknown => 0,
37 BssType::Infrastructure => 1,
38 BssType::Independent => 2,
39 BssType::Mesh => 3,
40 BssType::Personal => 4,
41
42 BssType::UnknownOrdinal_(value) => value,
43 }
44 }
45 }
46
47 unsafe impl<___E> ::fidl_next::Encode<crate::wire::BssType, ___E> for BssType
48 where
49 ___E: ?Sized,
50 {
51 #[inline]
52 fn encode(
53 self,
54 encoder: &mut ___E,
55 out: &mut ::core::mem::MaybeUninit<crate::wire::BssType>,
56 _: (),
57 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
58 ::fidl_next::Encode::encode(&self, encoder, out, ())
59 }
60 }
61
62 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::BssType, ___E> for &'a BssType
63 where
64 ___E: ?Sized,
65 {
66 #[inline]
67 fn encode(
68 self,
69 encoder: &mut ___E,
70 out: &mut ::core::mem::MaybeUninit<crate::wire::BssType>,
71 _: (),
72 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
73 ::fidl_next::munge!(let crate::wire::BssType { value } = out);
74 let _ = value.write(::fidl_next::wire::Uint32::from(match *self {
75 BssType::Unknown => 0,
76
77 BssType::Infrastructure => 1,
78
79 BssType::Independent => 2,
80
81 BssType::Mesh => 3,
82
83 BssType::Personal => 4,
84
85 BssType::UnknownOrdinal_(value) => value,
86 }));
87
88 Ok(())
89 }
90 }
91
92 impl ::core::convert::From<crate::wire::BssType> for BssType {
93 fn from(wire: crate::wire::BssType) -> Self {
94 match u32::from(wire.value) {
95 0 => Self::Unknown,
96
97 1 => Self::Infrastructure,
98
99 2 => Self::Independent,
100
101 3 => Self::Mesh,
102
103 4 => Self::Personal,
104
105 value => Self::UnknownOrdinal_(value),
106 }
107 }
108 }
109
110 impl ::fidl_next::FromWire<crate::wire::BssType> for BssType {
111 #[inline]
112 fn from_wire(wire: crate::wire::BssType) -> Self {
113 Self::from(wire)
114 }
115 }
116
117 impl ::fidl_next::FromWireRef<crate::wire::BssType> for BssType {
118 #[inline]
119 fn from_wire_ref(wire: &crate::wire::BssType) -> Self {
120 Self::from(*wire)
121 }
122 }
123
124 #[doc = " Corresponds to the Capability Information field defined by IEEE Std 802.11-2020, 9.4.1.4.\n This contains subfields that indicate support for requested or optional capabilities.\n\n TODO(https://fxbug.dev/367315525) Consider making this a bitfield.\n"]
125 pub type CapabilityInfo = u16;
126
127 #[doc = " Identifies a frequency band in metadata of various operations.\n\n Examples of this enum in use are labeling scan results or reporting\n a driver capabilities from various frequency bands.\n\n NOTE: This enum is similar to the Band ID field defined in\n IEEE Std 802.11-2016 9.4.1.46, but its values are not the same.\n\n TODO(https://fxbug.dev/376442944): Create a spec-compliant Band ID type\n and migrate the platform to use it.\n"]
128 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
129 #[repr(u8)]
130 pub enum WlanBand {
131 TwoGhz = 0,
132 FiveGhz = 1,
133 UnknownOrdinal_(u8) = 2,
134 }
135 impl ::std::convert::From<u8> for WlanBand {
136 fn from(value: u8) -> Self {
137 match value {
138 0 => Self::TwoGhz,
139 1 => Self::FiveGhz,
140
141 _ => Self::UnknownOrdinal_(value),
142 }
143 }
144 }
145
146 impl ::std::convert::From<WlanBand> for u8 {
147 fn from(value: WlanBand) -> Self {
148 match value {
149 WlanBand::TwoGhz => 0,
150 WlanBand::FiveGhz => 1,
151
152 WlanBand::UnknownOrdinal_(value) => value,
153 }
154 }
155 }
156
157 unsafe impl<___E> ::fidl_next::Encode<crate::wire::WlanBand, ___E> for WlanBand
158 where
159 ___E: ?Sized,
160 {
161 #[inline]
162 fn encode(
163 self,
164 encoder: &mut ___E,
165 out: &mut ::core::mem::MaybeUninit<crate::wire::WlanBand>,
166 _: (),
167 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
168 ::fidl_next::Encode::encode(&self, encoder, out, ())
169 }
170 }
171
172 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::WlanBand, ___E> for &'a WlanBand
173 where
174 ___E: ?Sized,
175 {
176 #[inline]
177 fn encode(
178 self,
179 encoder: &mut ___E,
180 out: &mut ::core::mem::MaybeUninit<crate::wire::WlanBand>,
181 _: (),
182 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
183 ::fidl_next::munge!(let crate::wire::WlanBand { value } = out);
184 let _ = value.write(u8::from(match *self {
185 WlanBand::TwoGhz => 0,
186
187 WlanBand::FiveGhz => 1,
188
189 WlanBand::UnknownOrdinal_(value) => value,
190 }));
191
192 Ok(())
193 }
194 }
195
196 impl ::core::convert::From<crate::wire::WlanBand> for WlanBand {
197 fn from(wire: crate::wire::WlanBand) -> Self {
198 match u8::from(wire.value) {
199 0 => Self::TwoGhz,
200
201 1 => Self::FiveGhz,
202
203 value => Self::UnknownOrdinal_(value),
204 }
205 }
206 }
207
208 impl ::fidl_next::FromWire<crate::wire::WlanBand> for WlanBand {
209 #[inline]
210 fn from_wire(wire: crate::wire::WlanBand) -> Self {
211 Self::from(wire)
212 }
213 }
214
215 impl ::fidl_next::FromWireRef<crate::wire::WlanBand> for WlanBand {
216 #[inline]
217 fn from_wire_ref(wire: &crate::wire::WlanBand) -> Self {
218 Self::from(*wire)
219 }
220 }
221
222 #[doc = " Channel information consisting of the frequency band and the channel number.\n"]
223 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
224 #[repr(C)]
225 pub struct ChannelNumber {
226 pub band: crate::natural::WlanBand,
227
228 pub number: u8,
229 }
230
231 unsafe impl<___E> ::fidl_next::Encode<crate::wire::ChannelNumber, ___E> for ChannelNumber
232 where
233 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
234 {
235 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, crate::wire::ChannelNumber> = unsafe {
236 ::fidl_next::CopyOptimization::enable_if(
237 true && <crate::natural::WlanBand as ::fidl_next::Encode<
238 crate::wire::WlanBand,
239 ___E,
240 >>::COPY_OPTIMIZATION
241 .is_enabled()
242 && <u8 as ::fidl_next::Encode<u8, ___E>>::COPY_OPTIMIZATION.is_enabled(),
243 )
244 };
245
246 #[inline]
247 fn encode(
248 self,
249 encoder_: &mut ___E,
250 out_: &mut ::core::mem::MaybeUninit<crate::wire::ChannelNumber>,
251 _: (),
252 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
253 ::fidl_next::munge! {
254 let crate::wire::ChannelNumber {
255 band,
256 number,
257
258 } = out_;
259 }
260
261 ::fidl_next::Encode::encode(self.band, encoder_, band, ())?;
262
263 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(band.as_mut_ptr()) };
264
265 ::fidl_next::Encode::encode(self.number, encoder_, number, ())?;
266
267 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(number.as_mut_ptr()) };
268
269 Ok(())
270 }
271 }
272
273 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::ChannelNumber, ___E> for &'a ChannelNumber
274 where
275 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
276 {
277 #[inline]
278 fn encode(
279 self,
280 encoder_: &mut ___E,
281 out_: &mut ::core::mem::MaybeUninit<crate::wire::ChannelNumber>,
282 _: (),
283 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
284 ::fidl_next::munge! {
285 let crate::wire::ChannelNumber {
286 band,
287 number,
288
289 } = out_;
290 }
291
292 ::fidl_next::Encode::encode(&self.band, encoder_, band, ())?;
293
294 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(band.as_mut_ptr()) };
295
296 ::fidl_next::Encode::encode(&self.number, encoder_, number, ())?;
297
298 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(number.as_mut_ptr()) };
299
300 Ok(())
301 }
302 }
303
304 unsafe impl<___E>
305 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::ChannelNumber>, ___E>
306 for ChannelNumber
307 where
308 ___E: ::fidl_next::Encoder + ?Sized,
309 ChannelNumber: ::fidl_next::Encode<crate::wire::ChannelNumber, ___E>,
310 {
311 #[inline]
312 fn encode_option(
313 this: ::core::option::Option<Self>,
314 encoder: &mut ___E,
315 out: &mut ::core::mem::MaybeUninit<
316 ::fidl_next::wire::Box<'static, crate::wire::ChannelNumber>,
317 >,
318 _: (),
319 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
320 if let Some(inner) = this {
321 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
322 ::fidl_next::wire::Box::encode_present(out);
323 } else {
324 ::fidl_next::wire::Box::encode_absent(out);
325 }
326
327 Ok(())
328 }
329 }
330
331 unsafe impl<'a, ___E>
332 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::ChannelNumber>, ___E>
333 for &'a ChannelNumber
334 where
335 ___E: ::fidl_next::Encoder + ?Sized,
336 &'a ChannelNumber: ::fidl_next::Encode<crate::wire::ChannelNumber, ___E>,
337 {
338 #[inline]
339 fn encode_option(
340 this: ::core::option::Option<Self>,
341 encoder: &mut ___E,
342 out: &mut ::core::mem::MaybeUninit<
343 ::fidl_next::wire::Box<'static, crate::wire::ChannelNumber>,
344 >,
345 _: (),
346 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
347 if let Some(inner) = this {
348 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
349 ::fidl_next::wire::Box::encode_present(out);
350 } else {
351 ::fidl_next::wire::Box::encode_absent(out);
352 }
353
354 Ok(())
355 }
356 }
357
358 impl ::fidl_next::FromWire<crate::wire::ChannelNumber> for ChannelNumber {
359 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<crate::wire::ChannelNumber, Self> = unsafe {
360 ::fidl_next::CopyOptimization::enable_if(
361 true && <crate::natural::WlanBand as ::fidl_next::FromWire<
362 crate::wire::WlanBand,
363 >>::COPY_OPTIMIZATION
364 .is_enabled()
365 && <u8 as ::fidl_next::FromWire<u8>>::COPY_OPTIMIZATION.is_enabled(),
366 )
367 };
368
369 #[inline]
370 fn from_wire(wire: crate::wire::ChannelNumber) -> Self {
371 Self {
372 band: ::fidl_next::FromWire::from_wire(wire.band),
373
374 number: ::fidl_next::FromWire::from_wire(wire.number),
375 }
376 }
377 }
378
379 impl ::fidl_next::FromWireRef<crate::wire::ChannelNumber> for ChannelNumber {
380 #[inline]
381 fn from_wire_ref(wire: &crate::wire::ChannelNumber) -> Self {
382 Self {
383 band: ::fidl_next::FromWireRef::from_wire_ref(&wire.band),
384
385 number: ::fidl_next::FromWireRef::from_wire_ref(&wire.number),
386 }
387 }
388 }
389
390 #[doc = " Channel width is derived from the HT operation and VHT operation IEs,\n or defaults to 20 MHz if not specified explicitly\n\n IEEE Std 802.11-2016, Table 9-153 - HT/VHT Operation Information subfields\n"]
391 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
392 #[repr(u32)]
393 pub enum ChannelBandwidth {
394 Cbw20 = 1,
395 Cbw40 = 2,
396 Cbw40Below = 3,
397 Cbw80 = 4,
398 Cbw160 = 5,
399 Cbw80P80 = 6,
400 UnknownOrdinal_(u32) = 7,
401 }
402 impl ::std::convert::From<u32> for ChannelBandwidth {
403 fn from(value: u32) -> Self {
404 match value {
405 1 => Self::Cbw20,
406 2 => Self::Cbw40,
407 3 => Self::Cbw40Below,
408 4 => Self::Cbw80,
409 5 => Self::Cbw160,
410 6 => Self::Cbw80P80,
411
412 _ => Self::UnknownOrdinal_(value),
413 }
414 }
415 }
416
417 impl ::std::convert::From<ChannelBandwidth> for u32 {
418 fn from(value: ChannelBandwidth) -> Self {
419 match value {
420 ChannelBandwidth::Cbw20 => 1,
421 ChannelBandwidth::Cbw40 => 2,
422 ChannelBandwidth::Cbw40Below => 3,
423 ChannelBandwidth::Cbw80 => 4,
424 ChannelBandwidth::Cbw160 => 5,
425 ChannelBandwidth::Cbw80P80 => 6,
426
427 ChannelBandwidth::UnknownOrdinal_(value) => value,
428 }
429 }
430 }
431
432 unsafe impl<___E> ::fidl_next::Encode<crate::wire::ChannelBandwidth, ___E> for ChannelBandwidth
433 where
434 ___E: ?Sized,
435 {
436 #[inline]
437 fn encode(
438 self,
439 encoder: &mut ___E,
440 out: &mut ::core::mem::MaybeUninit<crate::wire::ChannelBandwidth>,
441 _: (),
442 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
443 ::fidl_next::Encode::encode(&self, encoder, out, ())
444 }
445 }
446
447 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::ChannelBandwidth, ___E>
448 for &'a ChannelBandwidth
449 where
450 ___E: ?Sized,
451 {
452 #[inline]
453 fn encode(
454 self,
455 encoder: &mut ___E,
456 out: &mut ::core::mem::MaybeUninit<crate::wire::ChannelBandwidth>,
457 _: (),
458 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
459 ::fidl_next::munge!(let crate::wire::ChannelBandwidth { value } = out);
460 let _ = value.write(::fidl_next::wire::Uint32::from(match *self {
461 ChannelBandwidth::Cbw20 => 1,
462
463 ChannelBandwidth::Cbw40 => 2,
464
465 ChannelBandwidth::Cbw40Below => 3,
466
467 ChannelBandwidth::Cbw80 => 4,
468
469 ChannelBandwidth::Cbw160 => 5,
470
471 ChannelBandwidth::Cbw80P80 => 6,
472
473 ChannelBandwidth::UnknownOrdinal_(value) => value,
474 }));
475
476 Ok(())
477 }
478 }
479
480 impl ::core::convert::From<crate::wire::ChannelBandwidth> for ChannelBandwidth {
481 fn from(wire: crate::wire::ChannelBandwidth) -> Self {
482 match u32::from(wire.value) {
483 1 => Self::Cbw20,
484
485 2 => Self::Cbw40,
486
487 3 => Self::Cbw40Below,
488
489 4 => Self::Cbw80,
490
491 5 => Self::Cbw160,
492
493 6 => Self::Cbw80P80,
494
495 value => Self::UnknownOrdinal_(value),
496 }
497 }
498 }
499
500 impl ::fidl_next::FromWire<crate::wire::ChannelBandwidth> for ChannelBandwidth {
501 #[inline]
502 fn from_wire(wire: crate::wire::ChannelBandwidth) -> Self {
503 Self::from(wire)
504 }
505 }
506
507 impl ::fidl_next::FromWireRef<crate::wire::ChannelBandwidth> for ChannelBandwidth {
508 #[inline]
509 fn from_wire_ref(wire: &crate::wire::ChannelBandwidth) -> Self {
510 Self::from(*wire)
511 }
512 }
513
514 #[doc = " Type corresponding to a BSSDescription defined by IEEE Std 802.11-2020 6.3.3.3.2\n\n This type only includes explicit fields for information frequently required\n from a BSSDescription. All other fields are left in a raw buffer of IEs as\n received in an advertisement from the AP, e.g., from a Beacon or Probe\n Response frame.\n\n The inclusion of a raw buffer of IEs ensures this type always includes all\n the information an AP advertises, no matter the version of Fuchsia the\n advertisement was received in.\n"]
515 #[derive(Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
516 pub struct BssDescription {
517 pub bssid: [u8; 6],
518
519 pub bss_type: crate::natural::BssType,
520
521 pub beacon_period: u16,
522
523 pub capability_info: u16,
524
525 pub ies: ::std::vec::Vec<u8>,
526
527 pub primary: crate::natural::ChannelNumber,
528
529 pub bandwidth: crate::natural::ChannelBandwidth,
530
531 pub vht_secondary_80_channel: crate::natural::ChannelNumber,
532
533 pub rssi_dbm: i8,
534
535 pub snr_db: i8,
536 }
537
538 unsafe impl<___E> ::fidl_next::Encode<crate::wire::BssDescription<'static>, ___E> for BssDescription
539 where
540 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
541 ___E: ::fidl_next::Encoder,
542 {
543 #[inline]
544 fn encode(
545 self,
546 encoder_: &mut ___E,
547 out_: &mut ::core::mem::MaybeUninit<crate::wire::BssDescription<'static>>,
548 _: (),
549 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
550 ::fidl_next::munge! {
551 let crate::wire::BssDescription {
552 bssid,
553 bss_type,
554 beacon_period,
555 capability_info,
556 ies,
557 primary,
558 bandwidth,
559 vht_secondary_80_channel,
560 rssi_dbm,
561 snr_db,
562
563 } = out_;
564 }
565
566 ::fidl_next::Encode::encode(self.bssid, encoder_, bssid, ())?;
567
568 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bssid.as_mut_ptr()) };
569
570 ::fidl_next::Encode::encode(self.bss_type, encoder_, bss_type, ())?;
571
572 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bss_type.as_mut_ptr()) };
573
574 ::fidl_next::Encode::encode(self.beacon_period, encoder_, beacon_period, ())?;
575
576 let mut _field =
577 unsafe { ::fidl_next::Slot::new_unchecked(beacon_period.as_mut_ptr()) };
578
579 ::fidl_next::Encode::encode(self.capability_info, encoder_, capability_info, ())?;
580
581 let mut _field =
582 unsafe { ::fidl_next::Slot::new_unchecked(capability_info.as_mut_ptr()) };
583
584 ::fidl_next::Encode::encode(self.ies, encoder_, ies, (4294967295, ()))?;
585
586 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(ies.as_mut_ptr()) };
587 ::fidl_next::Constrained::validate(_field, (4294967295, ()))?;
588
589 ::fidl_next::Encode::encode(self.primary, encoder_, primary, ())?;
590
591 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(primary.as_mut_ptr()) };
592
593 ::fidl_next::Encode::encode(self.bandwidth, encoder_, bandwidth, ())?;
594
595 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bandwidth.as_mut_ptr()) };
596
597 ::fidl_next::Encode::encode(
598 self.vht_secondary_80_channel,
599 encoder_,
600 vht_secondary_80_channel,
601 (),
602 )?;
603
604 let mut _field =
605 unsafe { ::fidl_next::Slot::new_unchecked(vht_secondary_80_channel.as_mut_ptr()) };
606
607 ::fidl_next::Encode::encode(self.rssi_dbm, encoder_, rssi_dbm, ())?;
608
609 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(rssi_dbm.as_mut_ptr()) };
610
611 ::fidl_next::Encode::encode(self.snr_db, encoder_, snr_db, ())?;
612
613 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(snr_db.as_mut_ptr()) };
614
615 Ok(())
616 }
617 }
618
619 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::BssDescription<'static>, ___E>
620 for &'a BssDescription
621 where
622 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
623 ___E: ::fidl_next::Encoder,
624 {
625 #[inline]
626 fn encode(
627 self,
628 encoder_: &mut ___E,
629 out_: &mut ::core::mem::MaybeUninit<crate::wire::BssDescription<'static>>,
630 _: (),
631 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
632 ::fidl_next::munge! {
633 let crate::wire::BssDescription {
634 bssid,
635 bss_type,
636 beacon_period,
637 capability_info,
638 ies,
639 primary,
640 bandwidth,
641 vht_secondary_80_channel,
642 rssi_dbm,
643 snr_db,
644
645 } = out_;
646 }
647
648 ::fidl_next::Encode::encode(&self.bssid, encoder_, bssid, ())?;
649
650 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bssid.as_mut_ptr()) };
651
652 ::fidl_next::Encode::encode(&self.bss_type, encoder_, bss_type, ())?;
653
654 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bss_type.as_mut_ptr()) };
655
656 ::fidl_next::Encode::encode(&self.beacon_period, encoder_, beacon_period, ())?;
657
658 let mut _field =
659 unsafe { ::fidl_next::Slot::new_unchecked(beacon_period.as_mut_ptr()) };
660
661 ::fidl_next::Encode::encode(&self.capability_info, encoder_, capability_info, ())?;
662
663 let mut _field =
664 unsafe { ::fidl_next::Slot::new_unchecked(capability_info.as_mut_ptr()) };
665
666 ::fidl_next::Encode::encode(&self.ies, encoder_, ies, (4294967295, ()))?;
667
668 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(ies.as_mut_ptr()) };
669 ::fidl_next::Constrained::validate(_field, (4294967295, ()))?;
670
671 ::fidl_next::Encode::encode(&self.primary, encoder_, primary, ())?;
672
673 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(primary.as_mut_ptr()) };
674
675 ::fidl_next::Encode::encode(&self.bandwidth, encoder_, bandwidth, ())?;
676
677 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bandwidth.as_mut_ptr()) };
678
679 ::fidl_next::Encode::encode(
680 &self.vht_secondary_80_channel,
681 encoder_,
682 vht_secondary_80_channel,
683 (),
684 )?;
685
686 let mut _field =
687 unsafe { ::fidl_next::Slot::new_unchecked(vht_secondary_80_channel.as_mut_ptr()) };
688
689 ::fidl_next::Encode::encode(&self.rssi_dbm, encoder_, rssi_dbm, ())?;
690
691 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(rssi_dbm.as_mut_ptr()) };
692
693 ::fidl_next::Encode::encode(&self.snr_db, encoder_, snr_db, ())?;
694
695 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(snr_db.as_mut_ptr()) };
696
697 Ok(())
698 }
699 }
700
701 unsafe impl<___E>
702 ::fidl_next::EncodeOption<
703 ::fidl_next::wire::Box<'static, crate::wire::BssDescription<'static>>,
704 ___E,
705 > for BssDescription
706 where
707 ___E: ::fidl_next::Encoder + ?Sized,
708 BssDescription: ::fidl_next::Encode<crate::wire::BssDescription<'static>, ___E>,
709 {
710 #[inline]
711 fn encode_option(
712 this: ::core::option::Option<Self>,
713 encoder: &mut ___E,
714 out: &mut ::core::mem::MaybeUninit<
715 ::fidl_next::wire::Box<'static, crate::wire::BssDescription<'static>>,
716 >,
717 _: (),
718 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
719 if let Some(inner) = this {
720 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
721 ::fidl_next::wire::Box::encode_present(out);
722 } else {
723 ::fidl_next::wire::Box::encode_absent(out);
724 }
725
726 Ok(())
727 }
728 }
729
730 unsafe impl<'a, ___E>
731 ::fidl_next::EncodeOption<
732 ::fidl_next::wire::Box<'static, crate::wire::BssDescription<'static>>,
733 ___E,
734 > for &'a BssDescription
735 where
736 ___E: ::fidl_next::Encoder + ?Sized,
737 &'a BssDescription: ::fidl_next::Encode<crate::wire::BssDescription<'static>, ___E>,
738 {
739 #[inline]
740 fn encode_option(
741 this: ::core::option::Option<Self>,
742 encoder: &mut ___E,
743 out: &mut ::core::mem::MaybeUninit<
744 ::fidl_next::wire::Box<'static, crate::wire::BssDescription<'static>>,
745 >,
746 _: (),
747 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
748 if let Some(inner) = this {
749 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
750 ::fidl_next::wire::Box::encode_present(out);
751 } else {
752 ::fidl_next::wire::Box::encode_absent(out);
753 }
754
755 Ok(())
756 }
757 }
758
759 impl<'de> ::fidl_next::FromWire<crate::wire::BssDescription<'de>> for BssDescription {
760 #[inline]
761 fn from_wire(wire: crate::wire::BssDescription<'de>) -> Self {
762 Self {
763 bssid: ::fidl_next::FromWire::from_wire(wire.bssid),
764
765 bss_type: ::fidl_next::FromWire::from_wire(wire.bss_type),
766
767 beacon_period: ::fidl_next::FromWire::from_wire(wire.beacon_period),
768
769 capability_info: ::fidl_next::FromWire::from_wire(wire.capability_info),
770
771 ies: ::fidl_next::FromWire::from_wire(wire.ies),
772
773 primary: ::fidl_next::FromWire::from_wire(wire.primary),
774
775 bandwidth: ::fidl_next::FromWire::from_wire(wire.bandwidth),
776
777 vht_secondary_80_channel: ::fidl_next::FromWire::from_wire(
778 wire.vht_secondary_80_channel,
779 ),
780
781 rssi_dbm: ::fidl_next::FromWire::from_wire(wire.rssi_dbm),
782
783 snr_db: ::fidl_next::FromWire::from_wire(wire.snr_db),
784 }
785 }
786 }
787
788 impl<'de> ::fidl_next::FromWireRef<crate::wire::BssDescription<'de>> for BssDescription {
789 #[inline]
790 fn from_wire_ref(wire: &crate::wire::BssDescription<'de>) -> Self {
791 Self {
792 bssid: ::fidl_next::FromWireRef::from_wire_ref(&wire.bssid),
793
794 bss_type: ::fidl_next::FromWireRef::from_wire_ref(&wire.bss_type),
795
796 beacon_period: ::fidl_next::FromWireRef::from_wire_ref(&wire.beacon_period),
797
798 capability_info: ::fidl_next::FromWireRef::from_wire_ref(&wire.capability_info),
799
800 ies: ::fidl_next::FromWireRef::from_wire_ref(&wire.ies),
801
802 primary: ::fidl_next::FromWireRef::from_wire_ref(&wire.primary),
803
804 bandwidth: ::fidl_next::FromWireRef::from_wire_ref(&wire.bandwidth),
805
806 vht_secondary_80_channel: ::fidl_next::FromWireRef::from_wire_ref(
807 &wire.vht_secondary_80_channel,
808 ),
809
810 rssi_dbm: ::fidl_next::FromWireRef::from_wire_ref(&wire.rssi_dbm),
811
812 snr_db: ::fidl_next::FromWireRef::from_wire_ref(&wire.snr_db),
813 }
814 }
815 }
816
817 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
818 #[repr(C)]
819 pub struct CSsid {
820 pub len: u8,
821
822 pub data: [u8; 32],
823 }
824
825 unsafe impl<___E> ::fidl_next::Encode<crate::wire::CSsid, ___E> for CSsid
826 where
827 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
828 {
829 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, crate::wire::CSsid> = unsafe {
830 ::fidl_next::CopyOptimization::enable_if(
831 true && <u8 as ::fidl_next::Encode<u8, ___E>>::COPY_OPTIMIZATION.is_enabled()
832 && <[u8; 32] as ::fidl_next::Encode<[u8; 32], ___E>>::COPY_OPTIMIZATION
833 .is_enabled(),
834 )
835 };
836
837 #[inline]
838 fn encode(
839 self,
840 encoder_: &mut ___E,
841 out_: &mut ::core::mem::MaybeUninit<crate::wire::CSsid>,
842 _: (),
843 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
844 ::fidl_next::munge! {
845 let crate::wire::CSsid {
846 len,
847 data,
848
849 } = out_;
850 }
851
852 ::fidl_next::Encode::encode(self.len, encoder_, len, ())?;
853
854 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(len.as_mut_ptr()) };
855
856 ::fidl_next::Encode::encode(self.data, encoder_, data, ())?;
857
858 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(data.as_mut_ptr()) };
859
860 Ok(())
861 }
862 }
863
864 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::CSsid, ___E> for &'a CSsid
865 where
866 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
867 {
868 #[inline]
869 fn encode(
870 self,
871 encoder_: &mut ___E,
872 out_: &mut ::core::mem::MaybeUninit<crate::wire::CSsid>,
873 _: (),
874 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
875 ::fidl_next::munge! {
876 let crate::wire::CSsid {
877 len,
878 data,
879
880 } = out_;
881 }
882
883 ::fidl_next::Encode::encode(&self.len, encoder_, len, ())?;
884
885 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(len.as_mut_ptr()) };
886
887 ::fidl_next::Encode::encode(&self.data, encoder_, data, ())?;
888
889 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(data.as_mut_ptr()) };
890
891 Ok(())
892 }
893 }
894
895 unsafe impl<___E>
896 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::CSsid>, ___E>
897 for CSsid
898 where
899 ___E: ::fidl_next::Encoder + ?Sized,
900 CSsid: ::fidl_next::Encode<crate::wire::CSsid, ___E>,
901 {
902 #[inline]
903 fn encode_option(
904 this: ::core::option::Option<Self>,
905 encoder: &mut ___E,
906 out: &mut ::core::mem::MaybeUninit<::fidl_next::wire::Box<'static, crate::wire::CSsid>>,
907 _: (),
908 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
909 if let Some(inner) = this {
910 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
911 ::fidl_next::wire::Box::encode_present(out);
912 } else {
913 ::fidl_next::wire::Box::encode_absent(out);
914 }
915
916 Ok(())
917 }
918 }
919
920 unsafe impl<'a, ___E>
921 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::CSsid>, ___E>
922 for &'a CSsid
923 where
924 ___E: ::fidl_next::Encoder + ?Sized,
925 &'a CSsid: ::fidl_next::Encode<crate::wire::CSsid, ___E>,
926 {
927 #[inline]
928 fn encode_option(
929 this: ::core::option::Option<Self>,
930 encoder: &mut ___E,
931 out: &mut ::core::mem::MaybeUninit<::fidl_next::wire::Box<'static, crate::wire::CSsid>>,
932 _: (),
933 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
934 if let Some(inner) = this {
935 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
936 ::fidl_next::wire::Box::encode_present(out);
937 } else {
938 ::fidl_next::wire::Box::encode_absent(out);
939 }
940
941 Ok(())
942 }
943 }
944
945 impl ::fidl_next::FromWire<crate::wire::CSsid> for CSsid {
946 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<crate::wire::CSsid, Self> = unsafe {
947 ::fidl_next::CopyOptimization::enable_if(
948 true && <u8 as ::fidl_next::FromWire<u8>>::COPY_OPTIMIZATION.is_enabled()
949 && <[u8; 32] as ::fidl_next::FromWire<[u8; 32]>>::COPY_OPTIMIZATION
950 .is_enabled(),
951 )
952 };
953
954 #[inline]
955 fn from_wire(wire: crate::wire::CSsid) -> Self {
956 Self {
957 len: ::fidl_next::FromWire::from_wire(wire.len),
958
959 data: ::fidl_next::FromWire::from_wire(wire.data),
960 }
961 }
962 }
963
964 impl ::fidl_next::FromWireRef<crate::wire::CSsid> for CSsid {
965 #[inline]
966 fn from_wire_ref(wire: &crate::wire::CSsid) -> Self {
967 Self {
968 len: ::fidl_next::FromWireRef::from_wire_ref(&wire.len),
969
970 data: ::fidl_next::FromWireRef::from_wire_ref(&wire.data),
971 }
972 }
973 }
974
975 #[doc = " IEEE Std 802.11-2016, 9.4.2.25.2\n"]
976 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
977 #[repr(u32)]
978 pub enum CipherSuiteType {
979 UseGroup = 0,
980 Wep40 = 1,
981 Tkip = 2,
982 Reserved3 = 3,
983 Ccmp128 = 4,
984 Wep104 = 5,
985 BipCmac128 = 6,
986 GroupAddressedNotAllowed = 7,
987 Gcmp128 = 8,
988 Gcmp256 = 9,
989 Ccmp256 = 10,
990 BipGmac128 = 11,
991 BipGmac256 = 12,
992 BipCmac256 = 13,
993 Reserved14To255 = 14,
994 UnknownOrdinal_(u32) = 15,
995 }
996 impl ::std::convert::From<u32> for CipherSuiteType {
997 fn from(value: u32) -> Self {
998 match value {
999 0 => Self::UseGroup,
1000 1 => Self::Wep40,
1001 2 => Self::Tkip,
1002 3 => Self::Reserved3,
1003 4 => Self::Ccmp128,
1004 5 => Self::Wep104,
1005 6 => Self::BipCmac128,
1006 7 => Self::GroupAddressedNotAllowed,
1007 8 => Self::Gcmp128,
1008 9 => Self::Gcmp256,
1009 10 => Self::Ccmp256,
1010 11 => Self::BipGmac128,
1011 12 => Self::BipGmac256,
1012 13 => Self::BipCmac256,
1013 14 => Self::Reserved14To255,
1014
1015 _ => Self::UnknownOrdinal_(value),
1016 }
1017 }
1018 }
1019
1020 impl ::std::convert::From<CipherSuiteType> for u32 {
1021 fn from(value: CipherSuiteType) -> Self {
1022 match value {
1023 CipherSuiteType::UseGroup => 0,
1024 CipherSuiteType::Wep40 => 1,
1025 CipherSuiteType::Tkip => 2,
1026 CipherSuiteType::Reserved3 => 3,
1027 CipherSuiteType::Ccmp128 => 4,
1028 CipherSuiteType::Wep104 => 5,
1029 CipherSuiteType::BipCmac128 => 6,
1030 CipherSuiteType::GroupAddressedNotAllowed => 7,
1031 CipherSuiteType::Gcmp128 => 8,
1032 CipherSuiteType::Gcmp256 => 9,
1033 CipherSuiteType::Ccmp256 => 10,
1034 CipherSuiteType::BipGmac128 => 11,
1035 CipherSuiteType::BipGmac256 => 12,
1036 CipherSuiteType::BipCmac256 => 13,
1037 CipherSuiteType::Reserved14To255 => 14,
1038
1039 CipherSuiteType::UnknownOrdinal_(value) => value,
1040 }
1041 }
1042 }
1043
1044 unsafe impl<___E> ::fidl_next::Encode<crate::wire::CipherSuiteType, ___E> for CipherSuiteType
1045 where
1046 ___E: ?Sized,
1047 {
1048 #[inline]
1049 fn encode(
1050 self,
1051 encoder: &mut ___E,
1052 out: &mut ::core::mem::MaybeUninit<crate::wire::CipherSuiteType>,
1053 _: (),
1054 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1055 ::fidl_next::Encode::encode(&self, encoder, out, ())
1056 }
1057 }
1058
1059 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::CipherSuiteType, ___E>
1060 for &'a CipherSuiteType
1061 where
1062 ___E: ?Sized,
1063 {
1064 #[inline]
1065 fn encode(
1066 self,
1067 encoder: &mut ___E,
1068 out: &mut ::core::mem::MaybeUninit<crate::wire::CipherSuiteType>,
1069 _: (),
1070 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1071 ::fidl_next::munge!(let crate::wire::CipherSuiteType { value } = out);
1072 let _ = value.write(::fidl_next::wire::Uint32::from(match *self {
1073 CipherSuiteType::UseGroup => 0,
1074
1075 CipherSuiteType::Wep40 => 1,
1076
1077 CipherSuiteType::Tkip => 2,
1078
1079 CipherSuiteType::Reserved3 => 3,
1080
1081 CipherSuiteType::Ccmp128 => 4,
1082
1083 CipherSuiteType::Wep104 => 5,
1084
1085 CipherSuiteType::BipCmac128 => 6,
1086
1087 CipherSuiteType::GroupAddressedNotAllowed => 7,
1088
1089 CipherSuiteType::Gcmp128 => 8,
1090
1091 CipherSuiteType::Gcmp256 => 9,
1092
1093 CipherSuiteType::Ccmp256 => 10,
1094
1095 CipherSuiteType::BipGmac128 => 11,
1096
1097 CipherSuiteType::BipGmac256 => 12,
1098
1099 CipherSuiteType::BipCmac256 => 13,
1100
1101 CipherSuiteType::Reserved14To255 => 14,
1102
1103 CipherSuiteType::UnknownOrdinal_(value) => value,
1104 }));
1105
1106 Ok(())
1107 }
1108 }
1109
1110 impl ::core::convert::From<crate::wire::CipherSuiteType> for CipherSuiteType {
1111 fn from(wire: crate::wire::CipherSuiteType) -> Self {
1112 match u32::from(wire.value) {
1113 0 => Self::UseGroup,
1114
1115 1 => Self::Wep40,
1116
1117 2 => Self::Tkip,
1118
1119 3 => Self::Reserved3,
1120
1121 4 => Self::Ccmp128,
1122
1123 5 => Self::Wep104,
1124
1125 6 => Self::BipCmac128,
1126
1127 7 => Self::GroupAddressedNotAllowed,
1128
1129 8 => Self::Gcmp128,
1130
1131 9 => Self::Gcmp256,
1132
1133 10 => Self::Ccmp256,
1134
1135 11 => Self::BipGmac128,
1136
1137 12 => Self::BipGmac256,
1138
1139 13 => Self::BipCmac256,
1140
1141 14 => Self::Reserved14To255,
1142
1143 value => Self::UnknownOrdinal_(value),
1144 }
1145 }
1146 }
1147
1148 impl ::fidl_next::FromWire<crate::wire::CipherSuiteType> for CipherSuiteType {
1149 #[inline]
1150 fn from_wire(wire: crate::wire::CipherSuiteType) -> Self {
1151 Self::from(wire)
1152 }
1153 }
1154
1155 impl ::fidl_next::FromWireRef<crate::wire::CipherSuiteType> for CipherSuiteType {
1156 #[inline]
1157 fn from_wire_ref(wire: &crate::wire::CipherSuiteType) -> Self {
1158 Self::from(*wire)
1159 }
1160 }
1161
1162 #[doc = " HT and VHT guard interval.\n See IEEE 802.11-2016 Table 19-1 and Table 21-1.\n"]
1163 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
1164 #[repr(u8)]
1165 pub enum GuardInterval {
1166 LongGi = 1,
1167 ShortGi = 2,
1168 }
1169 impl ::core::convert::TryFrom<u8> for GuardInterval {
1170 type Error = ::fidl_next::UnknownStrictEnumMemberError;
1171 fn try_from(
1172 value: u8,
1173 ) -> ::core::result::Result<Self, ::fidl_next::UnknownStrictEnumMemberError> {
1174 match value {
1175 1 => Ok(Self::LongGi),
1176 2 => Ok(Self::ShortGi),
1177
1178 _ => Err(::fidl_next::UnknownStrictEnumMemberError::new(value.into())),
1179 }
1180 }
1181 }
1182
1183 impl ::std::convert::From<GuardInterval> for u8 {
1184 fn from(value: GuardInterval) -> Self {
1185 match value {
1186 GuardInterval::LongGi => 1,
1187 GuardInterval::ShortGi => 2,
1188 }
1189 }
1190 }
1191
1192 unsafe impl<___E> ::fidl_next::Encode<crate::wire::GuardInterval, ___E> for GuardInterval
1193 where
1194 ___E: ?Sized,
1195 {
1196 #[inline]
1197 fn encode(
1198 self,
1199 encoder: &mut ___E,
1200 out: &mut ::core::mem::MaybeUninit<crate::wire::GuardInterval>,
1201 _: (),
1202 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1203 ::fidl_next::Encode::encode(&self, encoder, out, ())
1204 }
1205 }
1206
1207 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::GuardInterval, ___E> for &'a GuardInterval
1208 where
1209 ___E: ?Sized,
1210 {
1211 #[inline]
1212 fn encode(
1213 self,
1214 encoder: &mut ___E,
1215 out: &mut ::core::mem::MaybeUninit<crate::wire::GuardInterval>,
1216 _: (),
1217 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1218 ::fidl_next::munge!(let crate::wire::GuardInterval { value } = out);
1219 let _ = value.write(u8::from(match *self {
1220 GuardInterval::LongGi => 1,
1221
1222 GuardInterval::ShortGi => 2,
1223 }));
1224
1225 Ok(())
1226 }
1227 }
1228
1229 impl ::core::convert::From<crate::wire::GuardInterval> for GuardInterval {
1230 fn from(wire: crate::wire::GuardInterval) -> Self {
1231 match u8::from(wire.value) {
1232 1 => Self::LongGi,
1233
1234 2 => Self::ShortGi,
1235
1236 _ => unsafe { ::core::hint::unreachable_unchecked() },
1237 }
1238 }
1239 }
1240
1241 impl ::fidl_next::FromWire<crate::wire::GuardInterval> for GuardInterval {
1242 #[inline]
1243 fn from_wire(wire: crate::wire::GuardInterval) -> Self {
1244 Self::from(wire)
1245 }
1246 }
1247
1248 impl ::fidl_next::FromWireRef<crate::wire::GuardInterval> for GuardInterval {
1249 #[inline]
1250 fn from_wire_ref(wire: &crate::wire::GuardInterval) -> Self {
1251 Self::from(*wire)
1252 }
1253 }
1254
1255 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
1256 #[repr(C)]
1257 pub struct HtCapabilities {
1258 pub bytes: [u8; 26],
1259 }
1260
1261 unsafe impl<___E> ::fidl_next::Encode<crate::wire::HtCapabilities, ___E> for HtCapabilities
1262 where
1263 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1264 {
1265 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, crate::wire::HtCapabilities> = unsafe {
1266 ::fidl_next::CopyOptimization::enable_if(
1267 true && <[u8; 26] as ::fidl_next::Encode<[u8; 26], ___E>>::COPY_OPTIMIZATION
1268 .is_enabled(),
1269 )
1270 };
1271
1272 #[inline]
1273 fn encode(
1274 self,
1275 encoder_: &mut ___E,
1276 out_: &mut ::core::mem::MaybeUninit<crate::wire::HtCapabilities>,
1277 _: (),
1278 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1279 ::fidl_next::munge! {
1280 let crate::wire::HtCapabilities {
1281 bytes,
1282
1283 } = out_;
1284 }
1285
1286 ::fidl_next::Encode::encode(self.bytes, encoder_, bytes, ())?;
1287
1288 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bytes.as_mut_ptr()) };
1289
1290 Ok(())
1291 }
1292 }
1293
1294 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::HtCapabilities, ___E> for &'a HtCapabilities
1295 where
1296 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1297 {
1298 #[inline]
1299 fn encode(
1300 self,
1301 encoder_: &mut ___E,
1302 out_: &mut ::core::mem::MaybeUninit<crate::wire::HtCapabilities>,
1303 _: (),
1304 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1305 ::fidl_next::munge! {
1306 let crate::wire::HtCapabilities {
1307 bytes,
1308
1309 } = out_;
1310 }
1311
1312 ::fidl_next::Encode::encode(&self.bytes, encoder_, bytes, ())?;
1313
1314 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bytes.as_mut_ptr()) };
1315
1316 Ok(())
1317 }
1318 }
1319
1320 unsafe impl<___E>
1321 ::fidl_next::EncodeOption<
1322 ::fidl_next::wire::Box<'static, crate::wire::HtCapabilities>,
1323 ___E,
1324 > for HtCapabilities
1325 where
1326 ___E: ::fidl_next::Encoder + ?Sized,
1327 HtCapabilities: ::fidl_next::Encode<crate::wire::HtCapabilities, ___E>,
1328 {
1329 #[inline]
1330 fn encode_option(
1331 this: ::core::option::Option<Self>,
1332 encoder: &mut ___E,
1333 out: &mut ::core::mem::MaybeUninit<
1334 ::fidl_next::wire::Box<'static, crate::wire::HtCapabilities>,
1335 >,
1336 _: (),
1337 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1338 if let Some(inner) = this {
1339 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
1340 ::fidl_next::wire::Box::encode_present(out);
1341 } else {
1342 ::fidl_next::wire::Box::encode_absent(out);
1343 }
1344
1345 Ok(())
1346 }
1347 }
1348
1349 unsafe impl<'a, ___E>
1350 ::fidl_next::EncodeOption<
1351 ::fidl_next::wire::Box<'static, crate::wire::HtCapabilities>,
1352 ___E,
1353 > for &'a HtCapabilities
1354 where
1355 ___E: ::fidl_next::Encoder + ?Sized,
1356 &'a HtCapabilities: ::fidl_next::Encode<crate::wire::HtCapabilities, ___E>,
1357 {
1358 #[inline]
1359 fn encode_option(
1360 this: ::core::option::Option<Self>,
1361 encoder: &mut ___E,
1362 out: &mut ::core::mem::MaybeUninit<
1363 ::fidl_next::wire::Box<'static, crate::wire::HtCapabilities>,
1364 >,
1365 _: (),
1366 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1367 if let Some(inner) = this {
1368 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
1369 ::fidl_next::wire::Box::encode_present(out);
1370 } else {
1371 ::fidl_next::wire::Box::encode_absent(out);
1372 }
1373
1374 Ok(())
1375 }
1376 }
1377
1378 impl ::fidl_next::FromWire<crate::wire::HtCapabilities> for HtCapabilities {
1379 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<crate::wire::HtCapabilities, Self> = unsafe {
1380 ::fidl_next::CopyOptimization::enable_if(
1381 true && <[u8; 26] as ::fidl_next::FromWire<[u8; 26]>>::COPY_OPTIMIZATION
1382 .is_enabled(),
1383 )
1384 };
1385
1386 #[inline]
1387 fn from_wire(wire: crate::wire::HtCapabilities) -> Self {
1388 Self { bytes: ::fidl_next::FromWire::from_wire(wire.bytes) }
1389 }
1390 }
1391
1392 impl ::fidl_next::FromWireRef<crate::wire::HtCapabilities> for HtCapabilities {
1393 #[inline]
1394 fn from_wire_ref(wire: &crate::wire::HtCapabilities) -> Self {
1395 Self { bytes: ::fidl_next::FromWireRef::from_wire_ref(&wire.bytes) }
1396 }
1397 }
1398
1399 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
1400 #[repr(C)]
1401 pub struct HtOperation {
1402 pub bytes: [u8; 22],
1403 }
1404
1405 unsafe impl<___E> ::fidl_next::Encode<crate::wire::HtOperation, ___E> for HtOperation
1406 where
1407 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1408 {
1409 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, crate::wire::HtOperation> = unsafe {
1410 ::fidl_next::CopyOptimization::enable_if(
1411 true && <[u8; 22] as ::fidl_next::Encode<[u8; 22], ___E>>::COPY_OPTIMIZATION
1412 .is_enabled(),
1413 )
1414 };
1415
1416 #[inline]
1417 fn encode(
1418 self,
1419 encoder_: &mut ___E,
1420 out_: &mut ::core::mem::MaybeUninit<crate::wire::HtOperation>,
1421 _: (),
1422 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1423 ::fidl_next::munge! {
1424 let crate::wire::HtOperation {
1425 bytes,
1426
1427 } = out_;
1428 }
1429
1430 ::fidl_next::Encode::encode(self.bytes, encoder_, bytes, ())?;
1431
1432 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bytes.as_mut_ptr()) };
1433
1434 Ok(())
1435 }
1436 }
1437
1438 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::HtOperation, ___E> for &'a HtOperation
1439 where
1440 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1441 {
1442 #[inline]
1443 fn encode(
1444 self,
1445 encoder_: &mut ___E,
1446 out_: &mut ::core::mem::MaybeUninit<crate::wire::HtOperation>,
1447 _: (),
1448 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1449 ::fidl_next::munge! {
1450 let crate::wire::HtOperation {
1451 bytes,
1452
1453 } = out_;
1454 }
1455
1456 ::fidl_next::Encode::encode(&self.bytes, encoder_, bytes, ())?;
1457
1458 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bytes.as_mut_ptr()) };
1459
1460 Ok(())
1461 }
1462 }
1463
1464 unsafe impl<___E>
1465 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::HtOperation>, ___E>
1466 for HtOperation
1467 where
1468 ___E: ::fidl_next::Encoder + ?Sized,
1469 HtOperation: ::fidl_next::Encode<crate::wire::HtOperation, ___E>,
1470 {
1471 #[inline]
1472 fn encode_option(
1473 this: ::core::option::Option<Self>,
1474 encoder: &mut ___E,
1475 out: &mut ::core::mem::MaybeUninit<
1476 ::fidl_next::wire::Box<'static, crate::wire::HtOperation>,
1477 >,
1478 _: (),
1479 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1480 if let Some(inner) = this {
1481 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
1482 ::fidl_next::wire::Box::encode_present(out);
1483 } else {
1484 ::fidl_next::wire::Box::encode_absent(out);
1485 }
1486
1487 Ok(())
1488 }
1489 }
1490
1491 unsafe impl<'a, ___E>
1492 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::HtOperation>, ___E>
1493 for &'a HtOperation
1494 where
1495 ___E: ::fidl_next::Encoder + ?Sized,
1496 &'a HtOperation: ::fidl_next::Encode<crate::wire::HtOperation, ___E>,
1497 {
1498 #[inline]
1499 fn encode_option(
1500 this: ::core::option::Option<Self>,
1501 encoder: &mut ___E,
1502 out: &mut ::core::mem::MaybeUninit<
1503 ::fidl_next::wire::Box<'static, crate::wire::HtOperation>,
1504 >,
1505 _: (),
1506 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1507 if let Some(inner) = this {
1508 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
1509 ::fidl_next::wire::Box::encode_present(out);
1510 } else {
1511 ::fidl_next::wire::Box::encode_absent(out);
1512 }
1513
1514 Ok(())
1515 }
1516 }
1517
1518 impl ::fidl_next::FromWire<crate::wire::HtOperation> for HtOperation {
1519 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<crate::wire::HtOperation, Self> = unsafe {
1520 ::fidl_next::CopyOptimization::enable_if(
1521 true && <[u8; 22] as ::fidl_next::FromWire<[u8; 22]>>::COPY_OPTIMIZATION
1522 .is_enabled(),
1523 )
1524 };
1525
1526 #[inline]
1527 fn from_wire(wire: crate::wire::HtOperation) -> Self {
1528 Self { bytes: ::fidl_next::FromWire::from_wire(wire.bytes) }
1529 }
1530 }
1531
1532 impl ::fidl_next::FromWireRef<crate::wire::HtOperation> for HtOperation {
1533 #[inline]
1534 fn from_wire_ref(wire: &crate::wire::HtOperation) -> Self {
1535 Self { bytes: ::fidl_next::FromWireRef::from_wire_ref(&wire.bytes) }
1536 }
1537 }
1538
1539 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
1540 #[repr(u8)]
1541 pub enum KeyType {
1542 Pairwise = 1,
1543 Group = 2,
1544 Igtk = 3,
1545 Peer = 4,
1546 UnknownOrdinal_(u8) = 5,
1547 }
1548 impl ::std::convert::From<u8> for KeyType {
1549 fn from(value: u8) -> Self {
1550 match value {
1551 1 => Self::Pairwise,
1552 2 => Self::Group,
1553 3 => Self::Igtk,
1554 4 => Self::Peer,
1555
1556 _ => Self::UnknownOrdinal_(value),
1557 }
1558 }
1559 }
1560
1561 impl ::std::convert::From<KeyType> for u8 {
1562 fn from(value: KeyType) -> Self {
1563 match value {
1564 KeyType::Pairwise => 1,
1565 KeyType::Group => 2,
1566 KeyType::Igtk => 3,
1567 KeyType::Peer => 4,
1568
1569 KeyType::UnknownOrdinal_(value) => value,
1570 }
1571 }
1572 }
1573
1574 unsafe impl<___E> ::fidl_next::Encode<crate::wire::KeyType, ___E> for KeyType
1575 where
1576 ___E: ?Sized,
1577 {
1578 #[inline]
1579 fn encode(
1580 self,
1581 encoder: &mut ___E,
1582 out: &mut ::core::mem::MaybeUninit<crate::wire::KeyType>,
1583 _: (),
1584 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1585 ::fidl_next::Encode::encode(&self, encoder, out, ())
1586 }
1587 }
1588
1589 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::KeyType, ___E> for &'a KeyType
1590 where
1591 ___E: ?Sized,
1592 {
1593 #[inline]
1594 fn encode(
1595 self,
1596 encoder: &mut ___E,
1597 out: &mut ::core::mem::MaybeUninit<crate::wire::KeyType>,
1598 _: (),
1599 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1600 ::fidl_next::munge!(let crate::wire::KeyType { value } = out);
1601 let _ = value.write(u8::from(match *self {
1602 KeyType::Pairwise => 1,
1603
1604 KeyType::Group => 2,
1605
1606 KeyType::Igtk => 3,
1607
1608 KeyType::Peer => 4,
1609
1610 KeyType::UnknownOrdinal_(value) => value,
1611 }));
1612
1613 Ok(())
1614 }
1615 }
1616
1617 impl ::core::convert::From<crate::wire::KeyType> for KeyType {
1618 fn from(wire: crate::wire::KeyType) -> Self {
1619 match u8::from(wire.value) {
1620 1 => Self::Pairwise,
1621
1622 2 => Self::Group,
1623
1624 3 => Self::Igtk,
1625
1626 4 => Self::Peer,
1627
1628 value => Self::UnknownOrdinal_(value),
1629 }
1630 }
1631 }
1632
1633 impl ::fidl_next::FromWire<crate::wire::KeyType> for KeyType {
1634 #[inline]
1635 fn from_wire(wire: crate::wire::KeyType) -> Self {
1636 Self::from(wire)
1637 }
1638 }
1639
1640 impl ::fidl_next::FromWireRef<crate::wire::KeyType> for KeyType {
1641 #[inline]
1642 fn from_wire_ref(wire: &crate::wire::KeyType) -> Self {
1643 Self::from(*wire)
1644 }
1645 }
1646
1647 #[doc = " 802.11 reason codes. These values are common throughout the standard.\n IEEE Std 802.11-2016, 9.4.1.7, Table 9-45\n"]
1648 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
1649 #[repr(u16)]
1650 pub enum ReasonCode {
1651 UnspecifiedReason = 1,
1652 InvalidAuthentication = 2,
1653 LeavingNetworkDeauth = 3,
1654 ReasonInactivity = 4,
1655 NoMoreStas = 5,
1656 InvalidClass2Frame = 6,
1657 InvalidClass3Frame = 7,
1658 LeavingNetworkDisassoc = 8,
1659 NotAuthenticated = 9,
1660 UnacceptablePowerCapability = 10,
1661 UnacceptableSupportedChannels = 11,
1662 BssTransitionDisassoc = 12,
1663 ReasonInvalidElement = 13,
1664 MicFailure = 14,
1665 FourwayHandshakeTimeout = 15,
1666 GkHandshakeTimeout = 16,
1667 HandshakeElementMismatch = 17,
1668 ReasonInvalidGroupCipher = 18,
1669 ReasonInvalidPairwiseCipher = 19,
1670 ReasonInvalidAkmp = 20,
1671 UnsupportedRsneVersion = 21,
1672 InvalidRsneCapabilities = 22,
1673 Ieee8021XAuthFailed = 23,
1674 ReasonCipherOutOfPolicy = 24,
1675 TdlsPeerUnreachable = 25,
1676 TdlsUnspecifiedReason = 26,
1677 SspRequestedDisassoc = 27,
1678 NoSspRoamingAgreement = 28,
1679 BadCipherOrAkm = 29,
1680 NotAuthorizedThisLocation = 30,
1681 ServiceChangePrecludesTs = 31,
1682 UnspecifiedQosReason = 32,
1683 NotEnoughBandwidth = 33,
1684 MissingAcks = 34,
1685 ExceededTxop = 35,
1686 StaLeaving = 36,
1687 EndTsBaDls = 37,
1688 UnknownTsBa = 38,
1689 Timeout = 39,
1690 PeerkeyMismatch = 45,
1691 PeerInitiated = 46,
1692 ApInitiated = 47,
1693 ReasonInvalidFtActionFrameCount = 48,
1694 ReasonInvalidPmkid = 49,
1695 ReasonInvalidMde = 50,
1696 ReasonInvalidFte = 51,
1697 MeshPeeringCanceled = 52,
1698 MeshMaxPeers = 53,
1699 MeshConfigurationPolicyViolation = 54,
1700 MeshCloseRcvd = 55,
1701 MeshMaxRetries = 56,
1702 MeshConfirmTimeout = 57,
1703 MeshInvalidGtk = 58,
1704 MeshInconsistentParameters = 59,
1705 MeshInvalidSecurityCapability = 60,
1706 MeshPathErrorNoProxyInformation = 61,
1707 MeshPathErrorNoForwardingInformation = 62,
1708 MeshPathErrorDestinationUnreachable = 63,
1709 MacAddressAlreadyExistsInMbss = 64,
1710 MeshChannelSwitchRegulatoryRequirements = 65,
1711 MeshChannelSwitchUnspecified = 66,
1712 MlmeLinkFailed = 128,
1713 FwRxStalled = 129,
1714 FwHighWmeRxErrRate = 130,
1715 UnknownOrdinal_(u16) = 131,
1716 }
1717 impl ::std::convert::From<u16> for ReasonCode {
1718 fn from(value: u16) -> Self {
1719 match value {
1720 1 => Self::UnspecifiedReason,
1721 2 => Self::InvalidAuthentication,
1722 3 => Self::LeavingNetworkDeauth,
1723 4 => Self::ReasonInactivity,
1724 5 => Self::NoMoreStas,
1725 6 => Self::InvalidClass2Frame,
1726 7 => Self::InvalidClass3Frame,
1727 8 => Self::LeavingNetworkDisassoc,
1728 9 => Self::NotAuthenticated,
1729 10 => Self::UnacceptablePowerCapability,
1730 11 => Self::UnacceptableSupportedChannels,
1731 12 => Self::BssTransitionDisassoc,
1732 13 => Self::ReasonInvalidElement,
1733 14 => Self::MicFailure,
1734 15 => Self::FourwayHandshakeTimeout,
1735 16 => Self::GkHandshakeTimeout,
1736 17 => Self::HandshakeElementMismatch,
1737 18 => Self::ReasonInvalidGroupCipher,
1738 19 => Self::ReasonInvalidPairwiseCipher,
1739 20 => Self::ReasonInvalidAkmp,
1740 21 => Self::UnsupportedRsneVersion,
1741 22 => Self::InvalidRsneCapabilities,
1742 23 => Self::Ieee8021XAuthFailed,
1743 24 => Self::ReasonCipherOutOfPolicy,
1744 25 => Self::TdlsPeerUnreachable,
1745 26 => Self::TdlsUnspecifiedReason,
1746 27 => Self::SspRequestedDisassoc,
1747 28 => Self::NoSspRoamingAgreement,
1748 29 => Self::BadCipherOrAkm,
1749 30 => Self::NotAuthorizedThisLocation,
1750 31 => Self::ServiceChangePrecludesTs,
1751 32 => Self::UnspecifiedQosReason,
1752 33 => Self::NotEnoughBandwidth,
1753 34 => Self::MissingAcks,
1754 35 => Self::ExceededTxop,
1755 36 => Self::StaLeaving,
1756 37 => Self::EndTsBaDls,
1757 38 => Self::UnknownTsBa,
1758 39 => Self::Timeout,
1759 45 => Self::PeerkeyMismatch,
1760 46 => Self::PeerInitiated,
1761 47 => Self::ApInitiated,
1762 48 => Self::ReasonInvalidFtActionFrameCount,
1763 49 => Self::ReasonInvalidPmkid,
1764 50 => Self::ReasonInvalidMde,
1765 51 => Self::ReasonInvalidFte,
1766 52 => Self::MeshPeeringCanceled,
1767 53 => Self::MeshMaxPeers,
1768 54 => Self::MeshConfigurationPolicyViolation,
1769 55 => Self::MeshCloseRcvd,
1770 56 => Self::MeshMaxRetries,
1771 57 => Self::MeshConfirmTimeout,
1772 58 => Self::MeshInvalidGtk,
1773 59 => Self::MeshInconsistentParameters,
1774 60 => Self::MeshInvalidSecurityCapability,
1775 61 => Self::MeshPathErrorNoProxyInformation,
1776 62 => Self::MeshPathErrorNoForwardingInformation,
1777 63 => Self::MeshPathErrorDestinationUnreachable,
1778 64 => Self::MacAddressAlreadyExistsInMbss,
1779 65 => Self::MeshChannelSwitchRegulatoryRequirements,
1780 66 => Self::MeshChannelSwitchUnspecified,
1781 128 => Self::MlmeLinkFailed,
1782 129 => Self::FwRxStalled,
1783 130 => Self::FwHighWmeRxErrRate,
1784
1785 _ => Self::UnknownOrdinal_(value),
1786 }
1787 }
1788 }
1789
1790 impl ::std::convert::From<ReasonCode> for u16 {
1791 fn from(value: ReasonCode) -> Self {
1792 match value {
1793 ReasonCode::UnspecifiedReason => 1,
1794 ReasonCode::InvalidAuthentication => 2,
1795 ReasonCode::LeavingNetworkDeauth => 3,
1796 ReasonCode::ReasonInactivity => 4,
1797 ReasonCode::NoMoreStas => 5,
1798 ReasonCode::InvalidClass2Frame => 6,
1799 ReasonCode::InvalidClass3Frame => 7,
1800 ReasonCode::LeavingNetworkDisassoc => 8,
1801 ReasonCode::NotAuthenticated => 9,
1802 ReasonCode::UnacceptablePowerCapability => 10,
1803 ReasonCode::UnacceptableSupportedChannels => 11,
1804 ReasonCode::BssTransitionDisassoc => 12,
1805 ReasonCode::ReasonInvalidElement => 13,
1806 ReasonCode::MicFailure => 14,
1807 ReasonCode::FourwayHandshakeTimeout => 15,
1808 ReasonCode::GkHandshakeTimeout => 16,
1809 ReasonCode::HandshakeElementMismatch => 17,
1810 ReasonCode::ReasonInvalidGroupCipher => 18,
1811 ReasonCode::ReasonInvalidPairwiseCipher => 19,
1812 ReasonCode::ReasonInvalidAkmp => 20,
1813 ReasonCode::UnsupportedRsneVersion => 21,
1814 ReasonCode::InvalidRsneCapabilities => 22,
1815 ReasonCode::Ieee8021XAuthFailed => 23,
1816 ReasonCode::ReasonCipherOutOfPolicy => 24,
1817 ReasonCode::TdlsPeerUnreachable => 25,
1818 ReasonCode::TdlsUnspecifiedReason => 26,
1819 ReasonCode::SspRequestedDisassoc => 27,
1820 ReasonCode::NoSspRoamingAgreement => 28,
1821 ReasonCode::BadCipherOrAkm => 29,
1822 ReasonCode::NotAuthorizedThisLocation => 30,
1823 ReasonCode::ServiceChangePrecludesTs => 31,
1824 ReasonCode::UnspecifiedQosReason => 32,
1825 ReasonCode::NotEnoughBandwidth => 33,
1826 ReasonCode::MissingAcks => 34,
1827 ReasonCode::ExceededTxop => 35,
1828 ReasonCode::StaLeaving => 36,
1829 ReasonCode::EndTsBaDls => 37,
1830 ReasonCode::UnknownTsBa => 38,
1831 ReasonCode::Timeout => 39,
1832 ReasonCode::PeerkeyMismatch => 45,
1833 ReasonCode::PeerInitiated => 46,
1834 ReasonCode::ApInitiated => 47,
1835 ReasonCode::ReasonInvalidFtActionFrameCount => 48,
1836 ReasonCode::ReasonInvalidPmkid => 49,
1837 ReasonCode::ReasonInvalidMde => 50,
1838 ReasonCode::ReasonInvalidFte => 51,
1839 ReasonCode::MeshPeeringCanceled => 52,
1840 ReasonCode::MeshMaxPeers => 53,
1841 ReasonCode::MeshConfigurationPolicyViolation => 54,
1842 ReasonCode::MeshCloseRcvd => 55,
1843 ReasonCode::MeshMaxRetries => 56,
1844 ReasonCode::MeshConfirmTimeout => 57,
1845 ReasonCode::MeshInvalidGtk => 58,
1846 ReasonCode::MeshInconsistentParameters => 59,
1847 ReasonCode::MeshInvalidSecurityCapability => 60,
1848 ReasonCode::MeshPathErrorNoProxyInformation => 61,
1849 ReasonCode::MeshPathErrorNoForwardingInformation => 62,
1850 ReasonCode::MeshPathErrorDestinationUnreachable => 63,
1851 ReasonCode::MacAddressAlreadyExistsInMbss => 64,
1852 ReasonCode::MeshChannelSwitchRegulatoryRequirements => 65,
1853 ReasonCode::MeshChannelSwitchUnspecified => 66,
1854 ReasonCode::MlmeLinkFailed => 128,
1855 ReasonCode::FwRxStalled => 129,
1856 ReasonCode::FwHighWmeRxErrRate => 130,
1857
1858 ReasonCode::UnknownOrdinal_(value) => value,
1859 }
1860 }
1861 }
1862
1863 unsafe impl<___E> ::fidl_next::Encode<crate::wire::ReasonCode, ___E> for ReasonCode
1864 where
1865 ___E: ?Sized,
1866 {
1867 #[inline]
1868 fn encode(
1869 self,
1870 encoder: &mut ___E,
1871 out: &mut ::core::mem::MaybeUninit<crate::wire::ReasonCode>,
1872 _: (),
1873 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1874 ::fidl_next::Encode::encode(&self, encoder, out, ())
1875 }
1876 }
1877
1878 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::ReasonCode, ___E> for &'a ReasonCode
1879 where
1880 ___E: ?Sized,
1881 {
1882 #[inline]
1883 fn encode(
1884 self,
1885 encoder: &mut ___E,
1886 out: &mut ::core::mem::MaybeUninit<crate::wire::ReasonCode>,
1887 _: (),
1888 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1889 ::fidl_next::munge!(let crate::wire::ReasonCode { value } = out);
1890 let _ = value.write(::fidl_next::wire::Uint16::from(match *self {
1891 ReasonCode::UnspecifiedReason => 1,
1892
1893 ReasonCode::InvalidAuthentication => 2,
1894
1895 ReasonCode::LeavingNetworkDeauth => 3,
1896
1897 ReasonCode::ReasonInactivity => 4,
1898
1899 ReasonCode::NoMoreStas => 5,
1900
1901 ReasonCode::InvalidClass2Frame => 6,
1902
1903 ReasonCode::InvalidClass3Frame => 7,
1904
1905 ReasonCode::LeavingNetworkDisassoc => 8,
1906
1907 ReasonCode::NotAuthenticated => 9,
1908
1909 ReasonCode::UnacceptablePowerCapability => 10,
1910
1911 ReasonCode::UnacceptableSupportedChannels => 11,
1912
1913 ReasonCode::BssTransitionDisassoc => 12,
1914
1915 ReasonCode::ReasonInvalidElement => 13,
1916
1917 ReasonCode::MicFailure => 14,
1918
1919 ReasonCode::FourwayHandshakeTimeout => 15,
1920
1921 ReasonCode::GkHandshakeTimeout => 16,
1922
1923 ReasonCode::HandshakeElementMismatch => 17,
1924
1925 ReasonCode::ReasonInvalidGroupCipher => 18,
1926
1927 ReasonCode::ReasonInvalidPairwiseCipher => 19,
1928
1929 ReasonCode::ReasonInvalidAkmp => 20,
1930
1931 ReasonCode::UnsupportedRsneVersion => 21,
1932
1933 ReasonCode::InvalidRsneCapabilities => 22,
1934
1935 ReasonCode::Ieee8021XAuthFailed => 23,
1936
1937 ReasonCode::ReasonCipherOutOfPolicy => 24,
1938
1939 ReasonCode::TdlsPeerUnreachable => 25,
1940
1941 ReasonCode::TdlsUnspecifiedReason => 26,
1942
1943 ReasonCode::SspRequestedDisassoc => 27,
1944
1945 ReasonCode::NoSspRoamingAgreement => 28,
1946
1947 ReasonCode::BadCipherOrAkm => 29,
1948
1949 ReasonCode::NotAuthorizedThisLocation => 30,
1950
1951 ReasonCode::ServiceChangePrecludesTs => 31,
1952
1953 ReasonCode::UnspecifiedQosReason => 32,
1954
1955 ReasonCode::NotEnoughBandwidth => 33,
1956
1957 ReasonCode::MissingAcks => 34,
1958
1959 ReasonCode::ExceededTxop => 35,
1960
1961 ReasonCode::StaLeaving => 36,
1962
1963 ReasonCode::EndTsBaDls => 37,
1964
1965 ReasonCode::UnknownTsBa => 38,
1966
1967 ReasonCode::Timeout => 39,
1968
1969 ReasonCode::PeerkeyMismatch => 45,
1970
1971 ReasonCode::PeerInitiated => 46,
1972
1973 ReasonCode::ApInitiated => 47,
1974
1975 ReasonCode::ReasonInvalidFtActionFrameCount => 48,
1976
1977 ReasonCode::ReasonInvalidPmkid => 49,
1978
1979 ReasonCode::ReasonInvalidMde => 50,
1980
1981 ReasonCode::ReasonInvalidFte => 51,
1982
1983 ReasonCode::MeshPeeringCanceled => 52,
1984
1985 ReasonCode::MeshMaxPeers => 53,
1986
1987 ReasonCode::MeshConfigurationPolicyViolation => 54,
1988
1989 ReasonCode::MeshCloseRcvd => 55,
1990
1991 ReasonCode::MeshMaxRetries => 56,
1992
1993 ReasonCode::MeshConfirmTimeout => 57,
1994
1995 ReasonCode::MeshInvalidGtk => 58,
1996
1997 ReasonCode::MeshInconsistentParameters => 59,
1998
1999 ReasonCode::MeshInvalidSecurityCapability => 60,
2000
2001 ReasonCode::MeshPathErrorNoProxyInformation => 61,
2002
2003 ReasonCode::MeshPathErrorNoForwardingInformation => 62,
2004
2005 ReasonCode::MeshPathErrorDestinationUnreachable => 63,
2006
2007 ReasonCode::MacAddressAlreadyExistsInMbss => 64,
2008
2009 ReasonCode::MeshChannelSwitchRegulatoryRequirements => 65,
2010
2011 ReasonCode::MeshChannelSwitchUnspecified => 66,
2012
2013 ReasonCode::MlmeLinkFailed => 128,
2014
2015 ReasonCode::FwRxStalled => 129,
2016
2017 ReasonCode::FwHighWmeRxErrRate => 130,
2018
2019 ReasonCode::UnknownOrdinal_(value) => value,
2020 }));
2021
2022 Ok(())
2023 }
2024 }
2025
2026 impl ::core::convert::From<crate::wire::ReasonCode> for ReasonCode {
2027 fn from(wire: crate::wire::ReasonCode) -> Self {
2028 match u16::from(wire.value) {
2029 1 => Self::UnspecifiedReason,
2030
2031 2 => Self::InvalidAuthentication,
2032
2033 3 => Self::LeavingNetworkDeauth,
2034
2035 4 => Self::ReasonInactivity,
2036
2037 5 => Self::NoMoreStas,
2038
2039 6 => Self::InvalidClass2Frame,
2040
2041 7 => Self::InvalidClass3Frame,
2042
2043 8 => Self::LeavingNetworkDisassoc,
2044
2045 9 => Self::NotAuthenticated,
2046
2047 10 => Self::UnacceptablePowerCapability,
2048
2049 11 => Self::UnacceptableSupportedChannels,
2050
2051 12 => Self::BssTransitionDisassoc,
2052
2053 13 => Self::ReasonInvalidElement,
2054
2055 14 => Self::MicFailure,
2056
2057 15 => Self::FourwayHandshakeTimeout,
2058
2059 16 => Self::GkHandshakeTimeout,
2060
2061 17 => Self::HandshakeElementMismatch,
2062
2063 18 => Self::ReasonInvalidGroupCipher,
2064
2065 19 => Self::ReasonInvalidPairwiseCipher,
2066
2067 20 => Self::ReasonInvalidAkmp,
2068
2069 21 => Self::UnsupportedRsneVersion,
2070
2071 22 => Self::InvalidRsneCapabilities,
2072
2073 23 => Self::Ieee8021XAuthFailed,
2074
2075 24 => Self::ReasonCipherOutOfPolicy,
2076
2077 25 => Self::TdlsPeerUnreachable,
2078
2079 26 => Self::TdlsUnspecifiedReason,
2080
2081 27 => Self::SspRequestedDisassoc,
2082
2083 28 => Self::NoSspRoamingAgreement,
2084
2085 29 => Self::BadCipherOrAkm,
2086
2087 30 => Self::NotAuthorizedThisLocation,
2088
2089 31 => Self::ServiceChangePrecludesTs,
2090
2091 32 => Self::UnspecifiedQosReason,
2092
2093 33 => Self::NotEnoughBandwidth,
2094
2095 34 => Self::MissingAcks,
2096
2097 35 => Self::ExceededTxop,
2098
2099 36 => Self::StaLeaving,
2100
2101 37 => Self::EndTsBaDls,
2102
2103 38 => Self::UnknownTsBa,
2104
2105 39 => Self::Timeout,
2106
2107 45 => Self::PeerkeyMismatch,
2108
2109 46 => Self::PeerInitiated,
2110
2111 47 => Self::ApInitiated,
2112
2113 48 => Self::ReasonInvalidFtActionFrameCount,
2114
2115 49 => Self::ReasonInvalidPmkid,
2116
2117 50 => Self::ReasonInvalidMde,
2118
2119 51 => Self::ReasonInvalidFte,
2120
2121 52 => Self::MeshPeeringCanceled,
2122
2123 53 => Self::MeshMaxPeers,
2124
2125 54 => Self::MeshConfigurationPolicyViolation,
2126
2127 55 => Self::MeshCloseRcvd,
2128
2129 56 => Self::MeshMaxRetries,
2130
2131 57 => Self::MeshConfirmTimeout,
2132
2133 58 => Self::MeshInvalidGtk,
2134
2135 59 => Self::MeshInconsistentParameters,
2136
2137 60 => Self::MeshInvalidSecurityCapability,
2138
2139 61 => Self::MeshPathErrorNoProxyInformation,
2140
2141 62 => Self::MeshPathErrorNoForwardingInformation,
2142
2143 63 => Self::MeshPathErrorDestinationUnreachable,
2144
2145 64 => Self::MacAddressAlreadyExistsInMbss,
2146
2147 65 => Self::MeshChannelSwitchRegulatoryRequirements,
2148
2149 66 => Self::MeshChannelSwitchUnspecified,
2150
2151 128 => Self::MlmeLinkFailed,
2152
2153 129 => Self::FwRxStalled,
2154
2155 130 => Self::FwHighWmeRxErrRate,
2156
2157 value => Self::UnknownOrdinal_(value),
2158 }
2159 }
2160 }
2161
2162 impl ::fidl_next::FromWire<crate::wire::ReasonCode> for ReasonCode {
2163 #[inline]
2164 fn from_wire(wire: crate::wire::ReasonCode) -> Self {
2165 Self::from(wire)
2166 }
2167 }
2168
2169 impl ::fidl_next::FromWireRef<crate::wire::ReasonCode> for ReasonCode {
2170 #[inline]
2171 fn from_wire_ref(wire: &crate::wire::ReasonCode) -> Self {
2172 Self::from(*wire)
2173 }
2174 }
2175
2176 #[doc = " IEEE Std 802.11-2020 6.3.19.1.2\n"]
2177 #[derive(Debug, Default, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
2178 pub struct SetKeyDescriptor {
2179 pub key: ::core::option::Option<::std::vec::Vec<u8>>,
2180
2181 pub key_id: ::core::option::Option<u16>,
2182
2183 pub key_type: ::core::option::Option<crate::natural::KeyType>,
2184
2185 pub peer_addr: ::core::option::Option<[u8; 6]>,
2186
2187 pub rsc: ::core::option::Option<u64>,
2188
2189 pub cipher_oui: ::core::option::Option<[u8; 3]>,
2190
2191 pub cipher_type: ::core::option::Option<crate::natural::CipherSuiteType>,
2192 }
2193
2194 impl SetKeyDescriptor {
2195 fn __max_ordinal(&self) -> usize {
2196 if self.cipher_type.is_some() {
2197 return 7;
2198 }
2199
2200 if self.cipher_oui.is_some() {
2201 return 6;
2202 }
2203
2204 if self.rsc.is_some() {
2205 return 5;
2206 }
2207
2208 if self.peer_addr.is_some() {
2209 return 4;
2210 }
2211
2212 if self.key_type.is_some() {
2213 return 3;
2214 }
2215
2216 if self.key_id.is_some() {
2217 return 2;
2218 }
2219
2220 if self.key.is_some() {
2221 return 1;
2222 }
2223
2224 0
2225 }
2226 }
2227
2228 unsafe impl<___E> ::fidl_next::Encode<crate::wire::SetKeyDescriptor<'static>, ___E>
2229 for SetKeyDescriptor
2230 where
2231 ___E: ::fidl_next::Encoder + ?Sized,
2232 {
2233 #[inline]
2234 fn encode(
2235 mut self,
2236 encoder: &mut ___E,
2237 out: &mut ::core::mem::MaybeUninit<crate::wire::SetKeyDescriptor<'static>>,
2238 _: (),
2239 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2240 ::fidl_next::munge!(let crate::wire::SetKeyDescriptor { table } = out);
2241
2242 let max_ord = self.__max_ordinal();
2243
2244 let mut out = ::core::mem::MaybeUninit::<::fidl_next::wire::Envelope>::uninit();
2245 ::fidl_next::Wire::zero_padding(&mut out);
2246
2247 let mut preallocated = ::fidl_next::EncoderExt::preallocate::<
2248 ::fidl_next::wire::Envelope,
2249 >(encoder, max_ord);
2250
2251 for i in 1..=max_ord {
2252 match i {
2253 7 => {
2254 if let Some(value) = self.cipher_type.take() {
2255 ::fidl_next::wire::Envelope::encode_value::<
2256 crate::wire::CipherSuiteType,
2257 ___E,
2258 >(
2259 value, preallocated.encoder, &mut out, ()
2260 )?;
2261 } else {
2262 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2263 }
2264 }
2265
2266 6 => {
2267 if let Some(value) = self.cipher_oui.take() {
2268 ::fidl_next::wire::Envelope::encode_value::<[u8; 3], ___E>(
2269 value,
2270 preallocated.encoder,
2271 &mut out,
2272 (),
2273 )?;
2274 } else {
2275 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2276 }
2277 }
2278
2279 5 => {
2280 if let Some(value) = self.rsc.take() {
2281 ::fidl_next::wire::Envelope::encode_value::<
2282 ::fidl_next::wire::Uint64,
2283 ___E,
2284 >(
2285 value, preallocated.encoder, &mut out, ()
2286 )?;
2287 } else {
2288 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2289 }
2290 }
2291
2292 4 => {
2293 if let Some(value) = self.peer_addr.take() {
2294 ::fidl_next::wire::Envelope::encode_value::<[u8; 6], ___E>(
2295 value,
2296 preallocated.encoder,
2297 &mut out,
2298 (),
2299 )?;
2300 } else {
2301 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2302 }
2303 }
2304
2305 3 => {
2306 if let Some(value) = self.key_type.take() {
2307 ::fidl_next::wire::Envelope::encode_value::<crate::wire::KeyType, ___E>(
2308 value,
2309 preallocated.encoder,
2310 &mut out,
2311 (),
2312 )?;
2313 } else {
2314 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2315 }
2316 }
2317
2318 2 => {
2319 if let Some(value) = self.key_id.take() {
2320 ::fidl_next::wire::Envelope::encode_value::<
2321 ::fidl_next::wire::Uint16,
2322 ___E,
2323 >(
2324 value, preallocated.encoder, &mut out, ()
2325 )?;
2326 } else {
2327 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2328 }
2329 }
2330
2331 1 => {
2332 if let Some(value) = self.key.take() {
2333 ::fidl_next::wire::Envelope::encode_value::<
2334 ::fidl_next::wire::Vector<'static, u8>,
2335 ___E,
2336 >(
2337 value, preallocated.encoder, &mut out, (32, ())
2338 )?;
2339 } else {
2340 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2341 }
2342 }
2343
2344 _ => ::fidl_next::wire::Envelope::encode_zero(&mut out),
2345 }
2346 unsafe {
2347 preallocated.write_next(out.assume_init_ref());
2348 }
2349 }
2350
2351 ::fidl_next::wire::Table::encode_len(table, max_ord);
2352
2353 Ok(())
2354 }
2355 }
2356
2357 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::SetKeyDescriptor<'static>, ___E>
2358 for &'a SetKeyDescriptor
2359 where
2360 ___E: ::fidl_next::Encoder + ?Sized,
2361 {
2362 #[inline]
2363 fn encode(
2364 self,
2365 encoder: &mut ___E,
2366 out: &mut ::core::mem::MaybeUninit<crate::wire::SetKeyDescriptor<'static>>,
2367 _: (),
2368 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2369 ::fidl_next::munge!(let crate::wire::SetKeyDescriptor { table } = out);
2370
2371 let max_ord = self.__max_ordinal();
2372
2373 let mut out = ::core::mem::MaybeUninit::<::fidl_next::wire::Envelope>::uninit();
2374 ::fidl_next::Wire::zero_padding(&mut out);
2375
2376 let mut preallocated = ::fidl_next::EncoderExt::preallocate::<
2377 ::fidl_next::wire::Envelope,
2378 >(encoder, max_ord);
2379
2380 for i in 1..=max_ord {
2381 match i {
2382 7 => {
2383 if let Some(value) = &self.cipher_type {
2384 ::fidl_next::wire::Envelope::encode_value::<
2385 crate::wire::CipherSuiteType,
2386 ___E,
2387 >(
2388 value, preallocated.encoder, &mut out, ()
2389 )?;
2390 } else {
2391 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2392 }
2393 }
2394
2395 6 => {
2396 if let Some(value) = &self.cipher_oui {
2397 ::fidl_next::wire::Envelope::encode_value::<[u8; 3], ___E>(
2398 value,
2399 preallocated.encoder,
2400 &mut out,
2401 (),
2402 )?;
2403 } else {
2404 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2405 }
2406 }
2407
2408 5 => {
2409 if let Some(value) = &self.rsc {
2410 ::fidl_next::wire::Envelope::encode_value::<
2411 ::fidl_next::wire::Uint64,
2412 ___E,
2413 >(
2414 value, preallocated.encoder, &mut out, ()
2415 )?;
2416 } else {
2417 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2418 }
2419 }
2420
2421 4 => {
2422 if let Some(value) = &self.peer_addr {
2423 ::fidl_next::wire::Envelope::encode_value::<[u8; 6], ___E>(
2424 value,
2425 preallocated.encoder,
2426 &mut out,
2427 (),
2428 )?;
2429 } else {
2430 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2431 }
2432 }
2433
2434 3 => {
2435 if let Some(value) = &self.key_type {
2436 ::fidl_next::wire::Envelope::encode_value::<crate::wire::KeyType, ___E>(
2437 value,
2438 preallocated.encoder,
2439 &mut out,
2440 (),
2441 )?;
2442 } else {
2443 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2444 }
2445 }
2446
2447 2 => {
2448 if let Some(value) = &self.key_id {
2449 ::fidl_next::wire::Envelope::encode_value::<
2450 ::fidl_next::wire::Uint16,
2451 ___E,
2452 >(
2453 value, preallocated.encoder, &mut out, ()
2454 )?;
2455 } else {
2456 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2457 }
2458 }
2459
2460 1 => {
2461 if let Some(value) = &self.key {
2462 ::fidl_next::wire::Envelope::encode_value::<
2463 ::fidl_next::wire::Vector<'static, u8>,
2464 ___E,
2465 >(
2466 value, preallocated.encoder, &mut out, (32, ())
2467 )?;
2468 } else {
2469 ::fidl_next::wire::Envelope::encode_zero(&mut out)
2470 }
2471 }
2472
2473 _ => ::fidl_next::wire::Envelope::encode_zero(&mut out),
2474 }
2475 unsafe {
2476 preallocated.write_next(out.assume_init_ref());
2477 }
2478 }
2479
2480 ::fidl_next::wire::Table::encode_len(table, max_ord);
2481
2482 Ok(())
2483 }
2484 }
2485
2486 impl<'de> ::fidl_next::FromWire<crate::wire::SetKeyDescriptor<'de>> for SetKeyDescriptor {
2487 #[inline]
2488 fn from_wire(wire_: crate::wire::SetKeyDescriptor<'de>) -> Self {
2489 let wire_ = ::core::mem::ManuallyDrop::new(wire_);
2490
2491 let key = wire_.table.get(1);
2492
2493 let key_id = wire_.table.get(2);
2494
2495 let key_type = wire_.table.get(3);
2496
2497 let peer_addr = wire_.table.get(4);
2498
2499 let rsc = wire_.table.get(5);
2500
2501 let cipher_oui = wire_.table.get(6);
2502
2503 let cipher_type = wire_.table.get(7);
2504
2505 Self {
2506 key: key.map(|envelope| {
2507 ::fidl_next::FromWire::from_wire(unsafe {
2508 envelope.read_unchecked::<::fidl_next::wire::Vector<'de, u8>>()
2509 })
2510 }),
2511
2512 key_id: key_id.map(|envelope| {
2513 ::fidl_next::FromWire::from_wire(unsafe {
2514 envelope.read_unchecked::<::fidl_next::wire::Uint16>()
2515 })
2516 }),
2517
2518 key_type: key_type.map(|envelope| {
2519 ::fidl_next::FromWire::from_wire(unsafe {
2520 envelope.read_unchecked::<crate::wire::KeyType>()
2521 })
2522 }),
2523
2524 peer_addr: peer_addr.map(|envelope| {
2525 ::fidl_next::FromWire::from_wire(unsafe {
2526 envelope.read_unchecked::<[u8; 6]>()
2527 })
2528 }),
2529
2530 rsc: rsc.map(|envelope| {
2531 ::fidl_next::FromWire::from_wire(unsafe {
2532 envelope.read_unchecked::<::fidl_next::wire::Uint64>()
2533 })
2534 }),
2535
2536 cipher_oui: cipher_oui.map(|envelope| {
2537 ::fidl_next::FromWire::from_wire(unsafe {
2538 envelope.read_unchecked::<[u8; 3]>()
2539 })
2540 }),
2541
2542 cipher_type: cipher_type.map(|envelope| {
2543 ::fidl_next::FromWire::from_wire(unsafe {
2544 envelope.read_unchecked::<crate::wire::CipherSuiteType>()
2545 })
2546 }),
2547 }
2548 }
2549 }
2550
2551 impl<'de> ::fidl_next::FromWireRef<crate::wire::SetKeyDescriptor<'de>> for SetKeyDescriptor {
2552 #[inline]
2553 fn from_wire_ref(wire: &crate::wire::SetKeyDescriptor<'de>) -> Self {
2554 Self {
2555 key: wire.table.get(1).map(|envelope| {
2556 ::fidl_next::FromWireRef::from_wire_ref(unsafe {
2557 envelope.deref_unchecked::<::fidl_next::wire::Vector<'de, u8>>()
2558 })
2559 }),
2560
2561 key_id: wire.table.get(2).map(|envelope| {
2562 ::fidl_next::FromWireRef::from_wire_ref(unsafe {
2563 envelope.deref_unchecked::<::fidl_next::wire::Uint16>()
2564 })
2565 }),
2566
2567 key_type: wire.table.get(3).map(|envelope| {
2568 ::fidl_next::FromWireRef::from_wire_ref(unsafe {
2569 envelope.deref_unchecked::<crate::wire::KeyType>()
2570 })
2571 }),
2572
2573 peer_addr: wire.table.get(4).map(|envelope| {
2574 ::fidl_next::FromWireRef::from_wire_ref(unsafe {
2575 envelope.deref_unchecked::<[u8; 6]>()
2576 })
2577 }),
2578
2579 rsc: wire.table.get(5).map(|envelope| {
2580 ::fidl_next::FromWireRef::from_wire_ref(unsafe {
2581 envelope.deref_unchecked::<::fidl_next::wire::Uint64>()
2582 })
2583 }),
2584
2585 cipher_oui: wire.table.get(6).map(|envelope| {
2586 ::fidl_next::FromWireRef::from_wire_ref(unsafe {
2587 envelope.deref_unchecked::<[u8; 3]>()
2588 })
2589 }),
2590
2591 cipher_type: wire.table.get(7).map(|envelope| {
2592 ::fidl_next::FromWireRef::from_wire_ref(unsafe {
2593 envelope.deref_unchecked::<crate::wire::CipherSuiteType>()
2594 })
2595 }),
2596 }
2597 }
2598 }
2599
2600 pub type Ssid = ::std::vec::Vec<u8>;
2601
2602 #[doc = " 802.11 status codes. These values are common throughout the standard.\n IEEE Std 802.11-2016, 9.4.1.9, Table 9-46\n"]
2603 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
2604 #[repr(u16)]
2605 pub enum StatusCode {
2606 Success = 0,
2607 RefusedReasonUnspecified = 1,
2608 TdlsRejectedAlternativeProvided = 2,
2609 TdlsRejected = 3,
2610 SecurityDisabled = 5,
2611 UnacceptableLifetime = 6,
2612 NotInSameBss = 7,
2613 RefusedCapabilitiesMismatch = 10,
2614 DeniedNoAssociationExists = 11,
2615 DeniedOtherReason = 12,
2616 UnsupportedAuthAlgorithm = 13,
2617 TransactionSequenceError = 14,
2618 ChallengeFailure = 15,
2619 RejectedSequenceTimeout = 16,
2620 DeniedNoMoreStas = 17,
2621 RefusedBasicRatesMismatch = 18,
2622 DeniedNoShortPreambleSupport = 19,
2623 RejectedSpectrumManagementRequired = 22,
2624 RejectedBadPowerCapability = 23,
2625 RejectedBadSupportedChannels = 24,
2626 DeniedNoShortSlotTimeSupport = 25,
2627 DeniedNoHtSupport = 27,
2628 R0KhUnreachable = 28,
2629 DeniedPcoTimeNotSupported = 29,
2630 RefusedTemporarily = 30,
2631 RobustManagementPolicyViolation = 31,
2632 UnspecifiedQosFailure = 32,
2633 DeniedInsufficientBandwidth = 33,
2634 DeniedPoorChannelConditions = 34,
2635 DeniedQosNotSupported = 35,
2636 RequestDeclined = 37,
2637 InvalidParameters = 38,
2638 RejectedWithSuggestedChanges = 39,
2639 StatusInvalidElement = 40,
2640 StatusInvalidGroupCipher = 41,
2641 StatusInvalidPairwiseCipher = 42,
2642 StatusInvalidAkmp = 43,
2643 UnsupportedRsneVersion = 44,
2644 InvalidRsneCapabilities = 45,
2645 StatusCipherOutOfPolicy = 46,
2646 RejectedForDelayPeriod = 47,
2647 DlsNotAllowed = 48,
2648 NotPresent = 49,
2649 NotQosSta = 50,
2650 DeniedListenIntervalTooLarge = 51,
2651 StatusInvalidFtActionFrameCount = 52,
2652 StatusInvalidPmkid = 53,
2653 StatusInvalidMde = 54,
2654 StatusInvalidFte = 55,
2655 RequestedTclasNotSupportedByAp = 56,
2656 InsufficientTclasProcessingResources = 57,
2657 TryAnotherBss = 58,
2658 GasAdvertisementProtocolNotSupported = 59,
2659 NoOutstandingGasRequest = 60,
2660 GasResponseNotReceivedFromServer = 61,
2661 GasQueryTimeout = 62,
2662 GasQueryResponseTooLarge = 63,
2663 RejectedHomeWithSuggestedChanges = 64,
2664 ServerUnreachable = 65,
2665 RejectedForSspPermissions = 67,
2666 RefusedUnauthenticatedAccessNotSupported = 68,
2667 InvalidRsne = 72,
2668 UApsdCoexistanceNotSupported = 73,
2669 UApsdCoexModeNotSupported = 74,
2670 BadIntervalWithUApsdCoex = 75,
2671 AntiCloggingTokenRequired = 76,
2672 UnsupportedFiniteCyclicGroup = 77,
2673 CannotFindAlternativeTbtt = 78,
2674 TransmissionFailure = 79,
2675 RequestedTclasNotSupported = 80,
2676 TclasResourcesExhausted = 81,
2677 RejectedWithSuggestedBssTransition = 82,
2678 RejectWithSchedule = 83,
2679 RejectNoWakeupSpecified = 84,
2680 SuccessPowerSaveMode = 85,
2681 PendingAdmittingFstSession = 86,
2682 PerformingFstNow = 87,
2683 PendingGapInBaWindow = 88,
2684 RejectUPidSetting = 89,
2685 RefusedExternalReason = 92,
2686 RefusedApOutOfMemory = 93,
2687 RejectedEmergencyServicesNotSupported = 94,
2688 QueryResponseOutstanding = 95,
2689 RejectDseBand = 96,
2690 TclasProcessingTerminated = 97,
2691 TsScheduleConflict = 98,
2692 DeniedWithSuggestedBandAndChannel = 99,
2693 MccaopReservationConflict = 100,
2694 MafLimitExceeded = 101,
2695 MccaTrackLimitExceeded = 102,
2696 DeniedDueToSpectrumManagement = 103,
2697 DeniedVhtNotSupported = 104,
2698 EnablementDenied = 105,
2699 RestrictionFromAuthorizedGdb = 106,
2700 AuthorizationDeenabled = 107,
2701 EnergyLimitedOperationNotSupported = 108,
2702 RejectedNdpBlockAckSuggested = 109,
2703 RejectedMaxAwayDurationUnacceptable = 110,
2704 FlowControlOperationSupported = 111,
2705 FilsAuthenticationFailure = 112,
2706 UnknownAuthenticationServer = 113,
2707 DeniedNotificationPeriodAllocation = 116,
2708 DeniedChannelSplitting = 117,
2709 DeniedAllocation = 118,
2710 CmmgFeaturesNotSupported = 119,
2711 GasFragmentNotAvailable = 120,
2712 SuccessCagVersionsMatch = 121,
2713 GlkNotAuthorized = 122,
2714 UnknownPasswordIdentifier = 123,
2715 DeniedLocalMacAddressPolicyViolation = 125,
2716 SaeHashToElement = 126,
2717 TclasProcessingTerminatedInsufficientQos = 128,
2718 TclasProcessingTerminatedPolicyConflict = 129,
2719 JoinFailure = 256,
2720 SpuriousDeauthOrDisassoc = 257,
2721 Canceled = 258,
2722 EstablishRsnaFailure = 259,
2723 OweHandshakeFailure = 260,
2724 NoAckFromPeer = 261,
2725 ResponseTimeout = 262,
2726 UnexpectedResponse = 263,
2727 InternalFailure = 264,
2728 UnknownOrdinal_(u16) = 265,
2729 }
2730 impl ::std::convert::From<u16> for StatusCode {
2731 fn from(value: u16) -> Self {
2732 match value {
2733 0 => Self::Success,
2734 1 => Self::RefusedReasonUnspecified,
2735 2 => Self::TdlsRejectedAlternativeProvided,
2736 3 => Self::TdlsRejected,
2737 5 => Self::SecurityDisabled,
2738 6 => Self::UnacceptableLifetime,
2739 7 => Self::NotInSameBss,
2740 10 => Self::RefusedCapabilitiesMismatch,
2741 11 => Self::DeniedNoAssociationExists,
2742 12 => Self::DeniedOtherReason,
2743 13 => Self::UnsupportedAuthAlgorithm,
2744 14 => Self::TransactionSequenceError,
2745 15 => Self::ChallengeFailure,
2746 16 => Self::RejectedSequenceTimeout,
2747 17 => Self::DeniedNoMoreStas,
2748 18 => Self::RefusedBasicRatesMismatch,
2749 19 => Self::DeniedNoShortPreambleSupport,
2750 22 => Self::RejectedSpectrumManagementRequired,
2751 23 => Self::RejectedBadPowerCapability,
2752 24 => Self::RejectedBadSupportedChannels,
2753 25 => Self::DeniedNoShortSlotTimeSupport,
2754 27 => Self::DeniedNoHtSupport,
2755 28 => Self::R0KhUnreachable,
2756 29 => Self::DeniedPcoTimeNotSupported,
2757 30 => Self::RefusedTemporarily,
2758 31 => Self::RobustManagementPolicyViolation,
2759 32 => Self::UnspecifiedQosFailure,
2760 33 => Self::DeniedInsufficientBandwidth,
2761 34 => Self::DeniedPoorChannelConditions,
2762 35 => Self::DeniedQosNotSupported,
2763 37 => Self::RequestDeclined,
2764 38 => Self::InvalidParameters,
2765 39 => Self::RejectedWithSuggestedChanges,
2766 40 => Self::StatusInvalidElement,
2767 41 => Self::StatusInvalidGroupCipher,
2768 42 => Self::StatusInvalidPairwiseCipher,
2769 43 => Self::StatusInvalidAkmp,
2770 44 => Self::UnsupportedRsneVersion,
2771 45 => Self::InvalidRsneCapabilities,
2772 46 => Self::StatusCipherOutOfPolicy,
2773 47 => Self::RejectedForDelayPeriod,
2774 48 => Self::DlsNotAllowed,
2775 49 => Self::NotPresent,
2776 50 => Self::NotQosSta,
2777 51 => Self::DeniedListenIntervalTooLarge,
2778 52 => Self::StatusInvalidFtActionFrameCount,
2779 53 => Self::StatusInvalidPmkid,
2780 54 => Self::StatusInvalidMde,
2781 55 => Self::StatusInvalidFte,
2782 56 => Self::RequestedTclasNotSupportedByAp,
2783 57 => Self::InsufficientTclasProcessingResources,
2784 58 => Self::TryAnotherBss,
2785 59 => Self::GasAdvertisementProtocolNotSupported,
2786 60 => Self::NoOutstandingGasRequest,
2787 61 => Self::GasResponseNotReceivedFromServer,
2788 62 => Self::GasQueryTimeout,
2789 63 => Self::GasQueryResponseTooLarge,
2790 64 => Self::RejectedHomeWithSuggestedChanges,
2791 65 => Self::ServerUnreachable,
2792 67 => Self::RejectedForSspPermissions,
2793 68 => Self::RefusedUnauthenticatedAccessNotSupported,
2794 72 => Self::InvalidRsne,
2795 73 => Self::UApsdCoexistanceNotSupported,
2796 74 => Self::UApsdCoexModeNotSupported,
2797 75 => Self::BadIntervalWithUApsdCoex,
2798 76 => Self::AntiCloggingTokenRequired,
2799 77 => Self::UnsupportedFiniteCyclicGroup,
2800 78 => Self::CannotFindAlternativeTbtt,
2801 79 => Self::TransmissionFailure,
2802 80 => Self::RequestedTclasNotSupported,
2803 81 => Self::TclasResourcesExhausted,
2804 82 => Self::RejectedWithSuggestedBssTransition,
2805 83 => Self::RejectWithSchedule,
2806 84 => Self::RejectNoWakeupSpecified,
2807 85 => Self::SuccessPowerSaveMode,
2808 86 => Self::PendingAdmittingFstSession,
2809 87 => Self::PerformingFstNow,
2810 88 => Self::PendingGapInBaWindow,
2811 89 => Self::RejectUPidSetting,
2812 92 => Self::RefusedExternalReason,
2813 93 => Self::RefusedApOutOfMemory,
2814 94 => Self::RejectedEmergencyServicesNotSupported,
2815 95 => Self::QueryResponseOutstanding,
2816 96 => Self::RejectDseBand,
2817 97 => Self::TclasProcessingTerminated,
2818 98 => Self::TsScheduleConflict,
2819 99 => Self::DeniedWithSuggestedBandAndChannel,
2820 100 => Self::MccaopReservationConflict,
2821 101 => Self::MafLimitExceeded,
2822 102 => Self::MccaTrackLimitExceeded,
2823 103 => Self::DeniedDueToSpectrumManagement,
2824 104 => Self::DeniedVhtNotSupported,
2825 105 => Self::EnablementDenied,
2826 106 => Self::RestrictionFromAuthorizedGdb,
2827 107 => Self::AuthorizationDeenabled,
2828 108 => Self::EnergyLimitedOperationNotSupported,
2829 109 => Self::RejectedNdpBlockAckSuggested,
2830 110 => Self::RejectedMaxAwayDurationUnacceptable,
2831 111 => Self::FlowControlOperationSupported,
2832 112 => Self::FilsAuthenticationFailure,
2833 113 => Self::UnknownAuthenticationServer,
2834 116 => Self::DeniedNotificationPeriodAllocation,
2835 117 => Self::DeniedChannelSplitting,
2836 118 => Self::DeniedAllocation,
2837 119 => Self::CmmgFeaturesNotSupported,
2838 120 => Self::GasFragmentNotAvailable,
2839 121 => Self::SuccessCagVersionsMatch,
2840 122 => Self::GlkNotAuthorized,
2841 123 => Self::UnknownPasswordIdentifier,
2842 125 => Self::DeniedLocalMacAddressPolicyViolation,
2843 126 => Self::SaeHashToElement,
2844 128 => Self::TclasProcessingTerminatedInsufficientQos,
2845 129 => Self::TclasProcessingTerminatedPolicyConflict,
2846 256 => Self::JoinFailure,
2847 257 => Self::SpuriousDeauthOrDisassoc,
2848 258 => Self::Canceled,
2849 259 => Self::EstablishRsnaFailure,
2850 260 => Self::OweHandshakeFailure,
2851 261 => Self::NoAckFromPeer,
2852 262 => Self::ResponseTimeout,
2853 263 => Self::UnexpectedResponse,
2854 264 => Self::InternalFailure,
2855
2856 _ => Self::UnknownOrdinal_(value),
2857 }
2858 }
2859 }
2860
2861 impl ::std::convert::From<StatusCode> for u16 {
2862 fn from(value: StatusCode) -> Self {
2863 match value {
2864 StatusCode::Success => 0,
2865 StatusCode::RefusedReasonUnspecified => 1,
2866 StatusCode::TdlsRejectedAlternativeProvided => 2,
2867 StatusCode::TdlsRejected => 3,
2868 StatusCode::SecurityDisabled => 5,
2869 StatusCode::UnacceptableLifetime => 6,
2870 StatusCode::NotInSameBss => 7,
2871 StatusCode::RefusedCapabilitiesMismatch => 10,
2872 StatusCode::DeniedNoAssociationExists => 11,
2873 StatusCode::DeniedOtherReason => 12,
2874 StatusCode::UnsupportedAuthAlgorithm => 13,
2875 StatusCode::TransactionSequenceError => 14,
2876 StatusCode::ChallengeFailure => 15,
2877 StatusCode::RejectedSequenceTimeout => 16,
2878 StatusCode::DeniedNoMoreStas => 17,
2879 StatusCode::RefusedBasicRatesMismatch => 18,
2880 StatusCode::DeniedNoShortPreambleSupport => 19,
2881 StatusCode::RejectedSpectrumManagementRequired => 22,
2882 StatusCode::RejectedBadPowerCapability => 23,
2883 StatusCode::RejectedBadSupportedChannels => 24,
2884 StatusCode::DeniedNoShortSlotTimeSupport => 25,
2885 StatusCode::DeniedNoHtSupport => 27,
2886 StatusCode::R0KhUnreachable => 28,
2887 StatusCode::DeniedPcoTimeNotSupported => 29,
2888 StatusCode::RefusedTemporarily => 30,
2889 StatusCode::RobustManagementPolicyViolation => 31,
2890 StatusCode::UnspecifiedQosFailure => 32,
2891 StatusCode::DeniedInsufficientBandwidth => 33,
2892 StatusCode::DeniedPoorChannelConditions => 34,
2893 StatusCode::DeniedQosNotSupported => 35,
2894 StatusCode::RequestDeclined => 37,
2895 StatusCode::InvalidParameters => 38,
2896 StatusCode::RejectedWithSuggestedChanges => 39,
2897 StatusCode::StatusInvalidElement => 40,
2898 StatusCode::StatusInvalidGroupCipher => 41,
2899 StatusCode::StatusInvalidPairwiseCipher => 42,
2900 StatusCode::StatusInvalidAkmp => 43,
2901 StatusCode::UnsupportedRsneVersion => 44,
2902 StatusCode::InvalidRsneCapabilities => 45,
2903 StatusCode::StatusCipherOutOfPolicy => 46,
2904 StatusCode::RejectedForDelayPeriod => 47,
2905 StatusCode::DlsNotAllowed => 48,
2906 StatusCode::NotPresent => 49,
2907 StatusCode::NotQosSta => 50,
2908 StatusCode::DeniedListenIntervalTooLarge => 51,
2909 StatusCode::StatusInvalidFtActionFrameCount => 52,
2910 StatusCode::StatusInvalidPmkid => 53,
2911 StatusCode::StatusInvalidMde => 54,
2912 StatusCode::StatusInvalidFte => 55,
2913 StatusCode::RequestedTclasNotSupportedByAp => 56,
2914 StatusCode::InsufficientTclasProcessingResources => 57,
2915 StatusCode::TryAnotherBss => 58,
2916 StatusCode::GasAdvertisementProtocolNotSupported => 59,
2917 StatusCode::NoOutstandingGasRequest => 60,
2918 StatusCode::GasResponseNotReceivedFromServer => 61,
2919 StatusCode::GasQueryTimeout => 62,
2920 StatusCode::GasQueryResponseTooLarge => 63,
2921 StatusCode::RejectedHomeWithSuggestedChanges => 64,
2922 StatusCode::ServerUnreachable => 65,
2923 StatusCode::RejectedForSspPermissions => 67,
2924 StatusCode::RefusedUnauthenticatedAccessNotSupported => 68,
2925 StatusCode::InvalidRsne => 72,
2926 StatusCode::UApsdCoexistanceNotSupported => 73,
2927 StatusCode::UApsdCoexModeNotSupported => 74,
2928 StatusCode::BadIntervalWithUApsdCoex => 75,
2929 StatusCode::AntiCloggingTokenRequired => 76,
2930 StatusCode::UnsupportedFiniteCyclicGroup => 77,
2931 StatusCode::CannotFindAlternativeTbtt => 78,
2932 StatusCode::TransmissionFailure => 79,
2933 StatusCode::RequestedTclasNotSupported => 80,
2934 StatusCode::TclasResourcesExhausted => 81,
2935 StatusCode::RejectedWithSuggestedBssTransition => 82,
2936 StatusCode::RejectWithSchedule => 83,
2937 StatusCode::RejectNoWakeupSpecified => 84,
2938 StatusCode::SuccessPowerSaveMode => 85,
2939 StatusCode::PendingAdmittingFstSession => 86,
2940 StatusCode::PerformingFstNow => 87,
2941 StatusCode::PendingGapInBaWindow => 88,
2942 StatusCode::RejectUPidSetting => 89,
2943 StatusCode::RefusedExternalReason => 92,
2944 StatusCode::RefusedApOutOfMemory => 93,
2945 StatusCode::RejectedEmergencyServicesNotSupported => 94,
2946 StatusCode::QueryResponseOutstanding => 95,
2947 StatusCode::RejectDseBand => 96,
2948 StatusCode::TclasProcessingTerminated => 97,
2949 StatusCode::TsScheduleConflict => 98,
2950 StatusCode::DeniedWithSuggestedBandAndChannel => 99,
2951 StatusCode::MccaopReservationConflict => 100,
2952 StatusCode::MafLimitExceeded => 101,
2953 StatusCode::MccaTrackLimitExceeded => 102,
2954 StatusCode::DeniedDueToSpectrumManagement => 103,
2955 StatusCode::DeniedVhtNotSupported => 104,
2956 StatusCode::EnablementDenied => 105,
2957 StatusCode::RestrictionFromAuthorizedGdb => 106,
2958 StatusCode::AuthorizationDeenabled => 107,
2959 StatusCode::EnergyLimitedOperationNotSupported => 108,
2960 StatusCode::RejectedNdpBlockAckSuggested => 109,
2961 StatusCode::RejectedMaxAwayDurationUnacceptable => 110,
2962 StatusCode::FlowControlOperationSupported => 111,
2963 StatusCode::FilsAuthenticationFailure => 112,
2964 StatusCode::UnknownAuthenticationServer => 113,
2965 StatusCode::DeniedNotificationPeriodAllocation => 116,
2966 StatusCode::DeniedChannelSplitting => 117,
2967 StatusCode::DeniedAllocation => 118,
2968 StatusCode::CmmgFeaturesNotSupported => 119,
2969 StatusCode::GasFragmentNotAvailable => 120,
2970 StatusCode::SuccessCagVersionsMatch => 121,
2971 StatusCode::GlkNotAuthorized => 122,
2972 StatusCode::UnknownPasswordIdentifier => 123,
2973 StatusCode::DeniedLocalMacAddressPolicyViolation => 125,
2974 StatusCode::SaeHashToElement => 126,
2975 StatusCode::TclasProcessingTerminatedInsufficientQos => 128,
2976 StatusCode::TclasProcessingTerminatedPolicyConflict => 129,
2977 StatusCode::JoinFailure => 256,
2978 StatusCode::SpuriousDeauthOrDisassoc => 257,
2979 StatusCode::Canceled => 258,
2980 StatusCode::EstablishRsnaFailure => 259,
2981 StatusCode::OweHandshakeFailure => 260,
2982 StatusCode::NoAckFromPeer => 261,
2983 StatusCode::ResponseTimeout => 262,
2984 StatusCode::UnexpectedResponse => 263,
2985 StatusCode::InternalFailure => 264,
2986
2987 StatusCode::UnknownOrdinal_(value) => value,
2988 }
2989 }
2990 }
2991
2992 unsafe impl<___E> ::fidl_next::Encode<crate::wire::StatusCode, ___E> for StatusCode
2993 where
2994 ___E: ?Sized,
2995 {
2996 #[inline]
2997 fn encode(
2998 self,
2999 encoder: &mut ___E,
3000 out: &mut ::core::mem::MaybeUninit<crate::wire::StatusCode>,
3001 _: (),
3002 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3003 ::fidl_next::Encode::encode(&self, encoder, out, ())
3004 }
3005 }
3006
3007 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::StatusCode, ___E> for &'a StatusCode
3008 where
3009 ___E: ?Sized,
3010 {
3011 #[inline]
3012 fn encode(
3013 self,
3014 encoder: &mut ___E,
3015 out: &mut ::core::mem::MaybeUninit<crate::wire::StatusCode>,
3016 _: (),
3017 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3018 ::fidl_next::munge!(let crate::wire::StatusCode { value } = out);
3019 let _ = value.write(::fidl_next::wire::Uint16::from(match *self {
3020 StatusCode::Success => 0,
3021
3022 StatusCode::RefusedReasonUnspecified => 1,
3023
3024 StatusCode::TdlsRejectedAlternativeProvided => 2,
3025
3026 StatusCode::TdlsRejected => 3,
3027
3028 StatusCode::SecurityDisabled => 5,
3029
3030 StatusCode::UnacceptableLifetime => 6,
3031
3032 StatusCode::NotInSameBss => 7,
3033
3034 StatusCode::RefusedCapabilitiesMismatch => 10,
3035
3036 StatusCode::DeniedNoAssociationExists => 11,
3037
3038 StatusCode::DeniedOtherReason => 12,
3039
3040 StatusCode::UnsupportedAuthAlgorithm => 13,
3041
3042 StatusCode::TransactionSequenceError => 14,
3043
3044 StatusCode::ChallengeFailure => 15,
3045
3046 StatusCode::RejectedSequenceTimeout => 16,
3047
3048 StatusCode::DeniedNoMoreStas => 17,
3049
3050 StatusCode::RefusedBasicRatesMismatch => 18,
3051
3052 StatusCode::DeniedNoShortPreambleSupport => 19,
3053
3054 StatusCode::RejectedSpectrumManagementRequired => 22,
3055
3056 StatusCode::RejectedBadPowerCapability => 23,
3057
3058 StatusCode::RejectedBadSupportedChannels => 24,
3059
3060 StatusCode::DeniedNoShortSlotTimeSupport => 25,
3061
3062 StatusCode::DeniedNoHtSupport => 27,
3063
3064 StatusCode::R0KhUnreachable => 28,
3065
3066 StatusCode::DeniedPcoTimeNotSupported => 29,
3067
3068 StatusCode::RefusedTemporarily => 30,
3069
3070 StatusCode::RobustManagementPolicyViolation => 31,
3071
3072 StatusCode::UnspecifiedQosFailure => 32,
3073
3074 StatusCode::DeniedInsufficientBandwidth => 33,
3075
3076 StatusCode::DeniedPoorChannelConditions => 34,
3077
3078 StatusCode::DeniedQosNotSupported => 35,
3079
3080 StatusCode::RequestDeclined => 37,
3081
3082 StatusCode::InvalidParameters => 38,
3083
3084 StatusCode::RejectedWithSuggestedChanges => 39,
3085
3086 StatusCode::StatusInvalidElement => 40,
3087
3088 StatusCode::StatusInvalidGroupCipher => 41,
3089
3090 StatusCode::StatusInvalidPairwiseCipher => 42,
3091
3092 StatusCode::StatusInvalidAkmp => 43,
3093
3094 StatusCode::UnsupportedRsneVersion => 44,
3095
3096 StatusCode::InvalidRsneCapabilities => 45,
3097
3098 StatusCode::StatusCipherOutOfPolicy => 46,
3099
3100 StatusCode::RejectedForDelayPeriod => 47,
3101
3102 StatusCode::DlsNotAllowed => 48,
3103
3104 StatusCode::NotPresent => 49,
3105
3106 StatusCode::NotQosSta => 50,
3107
3108 StatusCode::DeniedListenIntervalTooLarge => 51,
3109
3110 StatusCode::StatusInvalidFtActionFrameCount => 52,
3111
3112 StatusCode::StatusInvalidPmkid => 53,
3113
3114 StatusCode::StatusInvalidMde => 54,
3115
3116 StatusCode::StatusInvalidFte => 55,
3117
3118 StatusCode::RequestedTclasNotSupportedByAp => 56,
3119
3120 StatusCode::InsufficientTclasProcessingResources => 57,
3121
3122 StatusCode::TryAnotherBss => 58,
3123
3124 StatusCode::GasAdvertisementProtocolNotSupported => 59,
3125
3126 StatusCode::NoOutstandingGasRequest => 60,
3127
3128 StatusCode::GasResponseNotReceivedFromServer => 61,
3129
3130 StatusCode::GasQueryTimeout => 62,
3131
3132 StatusCode::GasQueryResponseTooLarge => 63,
3133
3134 StatusCode::RejectedHomeWithSuggestedChanges => 64,
3135
3136 StatusCode::ServerUnreachable => 65,
3137
3138 StatusCode::RejectedForSspPermissions => 67,
3139
3140 StatusCode::RefusedUnauthenticatedAccessNotSupported => 68,
3141
3142 StatusCode::InvalidRsne => 72,
3143
3144 StatusCode::UApsdCoexistanceNotSupported => 73,
3145
3146 StatusCode::UApsdCoexModeNotSupported => 74,
3147
3148 StatusCode::BadIntervalWithUApsdCoex => 75,
3149
3150 StatusCode::AntiCloggingTokenRequired => 76,
3151
3152 StatusCode::UnsupportedFiniteCyclicGroup => 77,
3153
3154 StatusCode::CannotFindAlternativeTbtt => 78,
3155
3156 StatusCode::TransmissionFailure => 79,
3157
3158 StatusCode::RequestedTclasNotSupported => 80,
3159
3160 StatusCode::TclasResourcesExhausted => 81,
3161
3162 StatusCode::RejectedWithSuggestedBssTransition => 82,
3163
3164 StatusCode::RejectWithSchedule => 83,
3165
3166 StatusCode::RejectNoWakeupSpecified => 84,
3167
3168 StatusCode::SuccessPowerSaveMode => 85,
3169
3170 StatusCode::PendingAdmittingFstSession => 86,
3171
3172 StatusCode::PerformingFstNow => 87,
3173
3174 StatusCode::PendingGapInBaWindow => 88,
3175
3176 StatusCode::RejectUPidSetting => 89,
3177
3178 StatusCode::RefusedExternalReason => 92,
3179
3180 StatusCode::RefusedApOutOfMemory => 93,
3181
3182 StatusCode::RejectedEmergencyServicesNotSupported => 94,
3183
3184 StatusCode::QueryResponseOutstanding => 95,
3185
3186 StatusCode::RejectDseBand => 96,
3187
3188 StatusCode::TclasProcessingTerminated => 97,
3189
3190 StatusCode::TsScheduleConflict => 98,
3191
3192 StatusCode::DeniedWithSuggestedBandAndChannel => 99,
3193
3194 StatusCode::MccaopReservationConflict => 100,
3195
3196 StatusCode::MafLimitExceeded => 101,
3197
3198 StatusCode::MccaTrackLimitExceeded => 102,
3199
3200 StatusCode::DeniedDueToSpectrumManagement => 103,
3201
3202 StatusCode::DeniedVhtNotSupported => 104,
3203
3204 StatusCode::EnablementDenied => 105,
3205
3206 StatusCode::RestrictionFromAuthorizedGdb => 106,
3207
3208 StatusCode::AuthorizationDeenabled => 107,
3209
3210 StatusCode::EnergyLimitedOperationNotSupported => 108,
3211
3212 StatusCode::RejectedNdpBlockAckSuggested => 109,
3213
3214 StatusCode::RejectedMaxAwayDurationUnacceptable => 110,
3215
3216 StatusCode::FlowControlOperationSupported => 111,
3217
3218 StatusCode::FilsAuthenticationFailure => 112,
3219
3220 StatusCode::UnknownAuthenticationServer => 113,
3221
3222 StatusCode::DeniedNotificationPeriodAllocation => 116,
3223
3224 StatusCode::DeniedChannelSplitting => 117,
3225
3226 StatusCode::DeniedAllocation => 118,
3227
3228 StatusCode::CmmgFeaturesNotSupported => 119,
3229
3230 StatusCode::GasFragmentNotAvailable => 120,
3231
3232 StatusCode::SuccessCagVersionsMatch => 121,
3233
3234 StatusCode::GlkNotAuthorized => 122,
3235
3236 StatusCode::UnknownPasswordIdentifier => 123,
3237
3238 StatusCode::DeniedLocalMacAddressPolicyViolation => 125,
3239
3240 StatusCode::SaeHashToElement => 126,
3241
3242 StatusCode::TclasProcessingTerminatedInsufficientQos => 128,
3243
3244 StatusCode::TclasProcessingTerminatedPolicyConflict => 129,
3245
3246 StatusCode::JoinFailure => 256,
3247
3248 StatusCode::SpuriousDeauthOrDisassoc => 257,
3249
3250 StatusCode::Canceled => 258,
3251
3252 StatusCode::EstablishRsnaFailure => 259,
3253
3254 StatusCode::OweHandshakeFailure => 260,
3255
3256 StatusCode::NoAckFromPeer => 261,
3257
3258 StatusCode::ResponseTimeout => 262,
3259
3260 StatusCode::UnexpectedResponse => 263,
3261
3262 StatusCode::InternalFailure => 264,
3263
3264 StatusCode::UnknownOrdinal_(value) => value,
3265 }));
3266
3267 Ok(())
3268 }
3269 }
3270
3271 impl ::core::convert::From<crate::wire::StatusCode> for StatusCode {
3272 fn from(wire: crate::wire::StatusCode) -> Self {
3273 match u16::from(wire.value) {
3274 0 => Self::Success,
3275
3276 1 => Self::RefusedReasonUnspecified,
3277
3278 2 => Self::TdlsRejectedAlternativeProvided,
3279
3280 3 => Self::TdlsRejected,
3281
3282 5 => Self::SecurityDisabled,
3283
3284 6 => Self::UnacceptableLifetime,
3285
3286 7 => Self::NotInSameBss,
3287
3288 10 => Self::RefusedCapabilitiesMismatch,
3289
3290 11 => Self::DeniedNoAssociationExists,
3291
3292 12 => Self::DeniedOtherReason,
3293
3294 13 => Self::UnsupportedAuthAlgorithm,
3295
3296 14 => Self::TransactionSequenceError,
3297
3298 15 => Self::ChallengeFailure,
3299
3300 16 => Self::RejectedSequenceTimeout,
3301
3302 17 => Self::DeniedNoMoreStas,
3303
3304 18 => Self::RefusedBasicRatesMismatch,
3305
3306 19 => Self::DeniedNoShortPreambleSupport,
3307
3308 22 => Self::RejectedSpectrumManagementRequired,
3309
3310 23 => Self::RejectedBadPowerCapability,
3311
3312 24 => Self::RejectedBadSupportedChannels,
3313
3314 25 => Self::DeniedNoShortSlotTimeSupport,
3315
3316 27 => Self::DeniedNoHtSupport,
3317
3318 28 => Self::R0KhUnreachable,
3319
3320 29 => Self::DeniedPcoTimeNotSupported,
3321
3322 30 => Self::RefusedTemporarily,
3323
3324 31 => Self::RobustManagementPolicyViolation,
3325
3326 32 => Self::UnspecifiedQosFailure,
3327
3328 33 => Self::DeniedInsufficientBandwidth,
3329
3330 34 => Self::DeniedPoorChannelConditions,
3331
3332 35 => Self::DeniedQosNotSupported,
3333
3334 37 => Self::RequestDeclined,
3335
3336 38 => Self::InvalidParameters,
3337
3338 39 => Self::RejectedWithSuggestedChanges,
3339
3340 40 => Self::StatusInvalidElement,
3341
3342 41 => Self::StatusInvalidGroupCipher,
3343
3344 42 => Self::StatusInvalidPairwiseCipher,
3345
3346 43 => Self::StatusInvalidAkmp,
3347
3348 44 => Self::UnsupportedRsneVersion,
3349
3350 45 => Self::InvalidRsneCapabilities,
3351
3352 46 => Self::StatusCipherOutOfPolicy,
3353
3354 47 => Self::RejectedForDelayPeriod,
3355
3356 48 => Self::DlsNotAllowed,
3357
3358 49 => Self::NotPresent,
3359
3360 50 => Self::NotQosSta,
3361
3362 51 => Self::DeniedListenIntervalTooLarge,
3363
3364 52 => Self::StatusInvalidFtActionFrameCount,
3365
3366 53 => Self::StatusInvalidPmkid,
3367
3368 54 => Self::StatusInvalidMde,
3369
3370 55 => Self::StatusInvalidFte,
3371
3372 56 => Self::RequestedTclasNotSupportedByAp,
3373
3374 57 => Self::InsufficientTclasProcessingResources,
3375
3376 58 => Self::TryAnotherBss,
3377
3378 59 => Self::GasAdvertisementProtocolNotSupported,
3379
3380 60 => Self::NoOutstandingGasRequest,
3381
3382 61 => Self::GasResponseNotReceivedFromServer,
3383
3384 62 => Self::GasQueryTimeout,
3385
3386 63 => Self::GasQueryResponseTooLarge,
3387
3388 64 => Self::RejectedHomeWithSuggestedChanges,
3389
3390 65 => Self::ServerUnreachable,
3391
3392 67 => Self::RejectedForSspPermissions,
3393
3394 68 => Self::RefusedUnauthenticatedAccessNotSupported,
3395
3396 72 => Self::InvalidRsne,
3397
3398 73 => Self::UApsdCoexistanceNotSupported,
3399
3400 74 => Self::UApsdCoexModeNotSupported,
3401
3402 75 => Self::BadIntervalWithUApsdCoex,
3403
3404 76 => Self::AntiCloggingTokenRequired,
3405
3406 77 => Self::UnsupportedFiniteCyclicGroup,
3407
3408 78 => Self::CannotFindAlternativeTbtt,
3409
3410 79 => Self::TransmissionFailure,
3411
3412 80 => Self::RequestedTclasNotSupported,
3413
3414 81 => Self::TclasResourcesExhausted,
3415
3416 82 => Self::RejectedWithSuggestedBssTransition,
3417
3418 83 => Self::RejectWithSchedule,
3419
3420 84 => Self::RejectNoWakeupSpecified,
3421
3422 85 => Self::SuccessPowerSaveMode,
3423
3424 86 => Self::PendingAdmittingFstSession,
3425
3426 87 => Self::PerformingFstNow,
3427
3428 88 => Self::PendingGapInBaWindow,
3429
3430 89 => Self::RejectUPidSetting,
3431
3432 92 => Self::RefusedExternalReason,
3433
3434 93 => Self::RefusedApOutOfMemory,
3435
3436 94 => Self::RejectedEmergencyServicesNotSupported,
3437
3438 95 => Self::QueryResponseOutstanding,
3439
3440 96 => Self::RejectDseBand,
3441
3442 97 => Self::TclasProcessingTerminated,
3443
3444 98 => Self::TsScheduleConflict,
3445
3446 99 => Self::DeniedWithSuggestedBandAndChannel,
3447
3448 100 => Self::MccaopReservationConflict,
3449
3450 101 => Self::MafLimitExceeded,
3451
3452 102 => Self::MccaTrackLimitExceeded,
3453
3454 103 => Self::DeniedDueToSpectrumManagement,
3455
3456 104 => Self::DeniedVhtNotSupported,
3457
3458 105 => Self::EnablementDenied,
3459
3460 106 => Self::RestrictionFromAuthorizedGdb,
3461
3462 107 => Self::AuthorizationDeenabled,
3463
3464 108 => Self::EnergyLimitedOperationNotSupported,
3465
3466 109 => Self::RejectedNdpBlockAckSuggested,
3467
3468 110 => Self::RejectedMaxAwayDurationUnacceptable,
3469
3470 111 => Self::FlowControlOperationSupported,
3471
3472 112 => Self::FilsAuthenticationFailure,
3473
3474 113 => Self::UnknownAuthenticationServer,
3475
3476 116 => Self::DeniedNotificationPeriodAllocation,
3477
3478 117 => Self::DeniedChannelSplitting,
3479
3480 118 => Self::DeniedAllocation,
3481
3482 119 => Self::CmmgFeaturesNotSupported,
3483
3484 120 => Self::GasFragmentNotAvailable,
3485
3486 121 => Self::SuccessCagVersionsMatch,
3487
3488 122 => Self::GlkNotAuthorized,
3489
3490 123 => Self::UnknownPasswordIdentifier,
3491
3492 125 => Self::DeniedLocalMacAddressPolicyViolation,
3493
3494 126 => Self::SaeHashToElement,
3495
3496 128 => Self::TclasProcessingTerminatedInsufficientQos,
3497
3498 129 => Self::TclasProcessingTerminatedPolicyConflict,
3499
3500 256 => Self::JoinFailure,
3501
3502 257 => Self::SpuriousDeauthOrDisassoc,
3503
3504 258 => Self::Canceled,
3505
3506 259 => Self::EstablishRsnaFailure,
3507
3508 260 => Self::OweHandshakeFailure,
3509
3510 261 => Self::NoAckFromPeer,
3511
3512 262 => Self::ResponseTimeout,
3513
3514 263 => Self::UnexpectedResponse,
3515
3516 264 => Self::InternalFailure,
3517
3518 value => Self::UnknownOrdinal_(value),
3519 }
3520 }
3521 }
3522
3523 impl ::fidl_next::FromWire<crate::wire::StatusCode> for StatusCode {
3524 #[inline]
3525 fn from_wire(wire: crate::wire::StatusCode) -> Self {
3526 Self::from(wire)
3527 }
3528 }
3529
3530 impl ::fidl_next::FromWireRef<crate::wire::StatusCode> for StatusCode {
3531 #[inline]
3532 fn from_wire_ref(wire: &crate::wire::StatusCode) -> Self {
3533 Self::from(*wire)
3534 }
3535 }
3536
3537 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
3538 #[repr(C)]
3539 pub struct VhtCapabilities {
3540 pub bytes: [u8; 12],
3541 }
3542
3543 unsafe impl<___E> ::fidl_next::Encode<crate::wire::VhtCapabilities, ___E> for VhtCapabilities
3544 where
3545 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
3546 {
3547 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, crate::wire::VhtCapabilities> = unsafe {
3548 ::fidl_next::CopyOptimization::enable_if(
3549 true && <[u8; 12] as ::fidl_next::Encode<[u8; 12], ___E>>::COPY_OPTIMIZATION
3550 .is_enabled(),
3551 )
3552 };
3553
3554 #[inline]
3555 fn encode(
3556 self,
3557 encoder_: &mut ___E,
3558 out_: &mut ::core::mem::MaybeUninit<crate::wire::VhtCapabilities>,
3559 _: (),
3560 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3561 ::fidl_next::munge! {
3562 let crate::wire::VhtCapabilities {
3563 bytes,
3564
3565 } = out_;
3566 }
3567
3568 ::fidl_next::Encode::encode(self.bytes, encoder_, bytes, ())?;
3569
3570 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bytes.as_mut_ptr()) };
3571
3572 Ok(())
3573 }
3574 }
3575
3576 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::VhtCapabilities, ___E>
3577 for &'a VhtCapabilities
3578 where
3579 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
3580 {
3581 #[inline]
3582 fn encode(
3583 self,
3584 encoder_: &mut ___E,
3585 out_: &mut ::core::mem::MaybeUninit<crate::wire::VhtCapabilities>,
3586 _: (),
3587 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3588 ::fidl_next::munge! {
3589 let crate::wire::VhtCapabilities {
3590 bytes,
3591
3592 } = out_;
3593 }
3594
3595 ::fidl_next::Encode::encode(&self.bytes, encoder_, bytes, ())?;
3596
3597 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bytes.as_mut_ptr()) };
3598
3599 Ok(())
3600 }
3601 }
3602
3603 unsafe impl<___E>
3604 ::fidl_next::EncodeOption<
3605 ::fidl_next::wire::Box<'static, crate::wire::VhtCapabilities>,
3606 ___E,
3607 > for VhtCapabilities
3608 where
3609 ___E: ::fidl_next::Encoder + ?Sized,
3610 VhtCapabilities: ::fidl_next::Encode<crate::wire::VhtCapabilities, ___E>,
3611 {
3612 #[inline]
3613 fn encode_option(
3614 this: ::core::option::Option<Self>,
3615 encoder: &mut ___E,
3616 out: &mut ::core::mem::MaybeUninit<
3617 ::fidl_next::wire::Box<'static, crate::wire::VhtCapabilities>,
3618 >,
3619 _: (),
3620 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3621 if let Some(inner) = this {
3622 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
3623 ::fidl_next::wire::Box::encode_present(out);
3624 } else {
3625 ::fidl_next::wire::Box::encode_absent(out);
3626 }
3627
3628 Ok(())
3629 }
3630 }
3631
3632 unsafe impl<'a, ___E>
3633 ::fidl_next::EncodeOption<
3634 ::fidl_next::wire::Box<'static, crate::wire::VhtCapabilities>,
3635 ___E,
3636 > for &'a VhtCapabilities
3637 where
3638 ___E: ::fidl_next::Encoder + ?Sized,
3639 &'a VhtCapabilities: ::fidl_next::Encode<crate::wire::VhtCapabilities, ___E>,
3640 {
3641 #[inline]
3642 fn encode_option(
3643 this: ::core::option::Option<Self>,
3644 encoder: &mut ___E,
3645 out: &mut ::core::mem::MaybeUninit<
3646 ::fidl_next::wire::Box<'static, crate::wire::VhtCapabilities>,
3647 >,
3648 _: (),
3649 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3650 if let Some(inner) = this {
3651 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
3652 ::fidl_next::wire::Box::encode_present(out);
3653 } else {
3654 ::fidl_next::wire::Box::encode_absent(out);
3655 }
3656
3657 Ok(())
3658 }
3659 }
3660
3661 impl ::fidl_next::FromWire<crate::wire::VhtCapabilities> for VhtCapabilities {
3662 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<crate::wire::VhtCapabilities, Self> = unsafe {
3663 ::fidl_next::CopyOptimization::enable_if(
3664 true && <[u8; 12] as ::fidl_next::FromWire<[u8; 12]>>::COPY_OPTIMIZATION
3665 .is_enabled(),
3666 )
3667 };
3668
3669 #[inline]
3670 fn from_wire(wire: crate::wire::VhtCapabilities) -> Self {
3671 Self { bytes: ::fidl_next::FromWire::from_wire(wire.bytes) }
3672 }
3673 }
3674
3675 impl ::fidl_next::FromWireRef<crate::wire::VhtCapabilities> for VhtCapabilities {
3676 #[inline]
3677 fn from_wire_ref(wire: &crate::wire::VhtCapabilities) -> Self {
3678 Self { bytes: ::fidl_next::FromWireRef::from_wire_ref(&wire.bytes) }
3679 }
3680 }
3681
3682 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
3683 #[repr(C)]
3684 pub struct VhtOperation {
3685 pub bytes: [u8; 5],
3686 }
3687
3688 unsafe impl<___E> ::fidl_next::Encode<crate::wire::VhtOperation, ___E> for VhtOperation
3689 where
3690 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
3691 {
3692 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, crate::wire::VhtOperation> = unsafe {
3693 ::fidl_next::CopyOptimization::enable_if(
3694 true && <[u8; 5] as ::fidl_next::Encode<[u8; 5], ___E>>::COPY_OPTIMIZATION
3695 .is_enabled(),
3696 )
3697 };
3698
3699 #[inline]
3700 fn encode(
3701 self,
3702 encoder_: &mut ___E,
3703 out_: &mut ::core::mem::MaybeUninit<crate::wire::VhtOperation>,
3704 _: (),
3705 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3706 ::fidl_next::munge! {
3707 let crate::wire::VhtOperation {
3708 bytes,
3709
3710 } = out_;
3711 }
3712
3713 ::fidl_next::Encode::encode(self.bytes, encoder_, bytes, ())?;
3714
3715 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bytes.as_mut_ptr()) };
3716
3717 Ok(())
3718 }
3719 }
3720
3721 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::VhtOperation, ___E> for &'a VhtOperation
3722 where
3723 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
3724 {
3725 #[inline]
3726 fn encode(
3727 self,
3728 encoder_: &mut ___E,
3729 out_: &mut ::core::mem::MaybeUninit<crate::wire::VhtOperation>,
3730 _: (),
3731 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3732 ::fidl_next::munge! {
3733 let crate::wire::VhtOperation {
3734 bytes,
3735
3736 } = out_;
3737 }
3738
3739 ::fidl_next::Encode::encode(&self.bytes, encoder_, bytes, ())?;
3740
3741 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(bytes.as_mut_ptr()) };
3742
3743 Ok(())
3744 }
3745 }
3746
3747 unsafe impl<___E>
3748 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::VhtOperation>, ___E>
3749 for VhtOperation
3750 where
3751 ___E: ::fidl_next::Encoder + ?Sized,
3752 VhtOperation: ::fidl_next::Encode<crate::wire::VhtOperation, ___E>,
3753 {
3754 #[inline]
3755 fn encode_option(
3756 this: ::core::option::Option<Self>,
3757 encoder: &mut ___E,
3758 out: &mut ::core::mem::MaybeUninit<
3759 ::fidl_next::wire::Box<'static, crate::wire::VhtOperation>,
3760 >,
3761 _: (),
3762 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3763 if let Some(inner) = this {
3764 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
3765 ::fidl_next::wire::Box::encode_present(out);
3766 } else {
3767 ::fidl_next::wire::Box::encode_absent(out);
3768 }
3769
3770 Ok(())
3771 }
3772 }
3773
3774 unsafe impl<'a, ___E>
3775 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::VhtOperation>, ___E>
3776 for &'a VhtOperation
3777 where
3778 ___E: ::fidl_next::Encoder + ?Sized,
3779 &'a VhtOperation: ::fidl_next::Encode<crate::wire::VhtOperation, ___E>,
3780 {
3781 #[inline]
3782 fn encode_option(
3783 this: ::core::option::Option<Self>,
3784 encoder: &mut ___E,
3785 out: &mut ::core::mem::MaybeUninit<
3786 ::fidl_next::wire::Box<'static, crate::wire::VhtOperation>,
3787 >,
3788 _: (),
3789 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3790 if let Some(inner) = this {
3791 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
3792 ::fidl_next::wire::Box::encode_present(out);
3793 } else {
3794 ::fidl_next::wire::Box::encode_absent(out);
3795 }
3796
3797 Ok(())
3798 }
3799 }
3800
3801 impl ::fidl_next::FromWire<crate::wire::VhtOperation> for VhtOperation {
3802 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<crate::wire::VhtOperation, Self> = unsafe {
3803 ::fidl_next::CopyOptimization::enable_if(
3804 true && <[u8; 5] as ::fidl_next::FromWire<[u8; 5]>>::COPY_OPTIMIZATION.is_enabled(),
3805 )
3806 };
3807
3808 #[inline]
3809 fn from_wire(wire: crate::wire::VhtOperation) -> Self {
3810 Self { bytes: ::fidl_next::FromWire::from_wire(wire.bytes) }
3811 }
3812 }
3813
3814 impl ::fidl_next::FromWireRef<crate::wire::VhtOperation> for VhtOperation {
3815 #[inline]
3816 fn from_wire_ref(wire: &crate::wire::VhtOperation) -> Self {
3817 Self { bytes: ::fidl_next::FromWireRef::from_wire_ref(&wire.bytes) }
3818 }
3819 }
3820
3821 #[doc = " IEEE Std 802.11-2020 9.4.2.173\n"]
3822 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
3823 #[repr(u32)]
3824 pub enum WlanAccessCategory {
3825 Background = 1,
3826 BestEffort = 2,
3827 Video = 3,
3828 Voice = 4,
3829 }
3830 impl ::core::convert::TryFrom<u32> for WlanAccessCategory {
3831 type Error = ::fidl_next::UnknownStrictEnumMemberError;
3832 fn try_from(
3833 value: u32,
3834 ) -> ::core::result::Result<Self, ::fidl_next::UnknownStrictEnumMemberError> {
3835 match value {
3836 1 => Ok(Self::Background),
3837 2 => Ok(Self::BestEffort),
3838 3 => Ok(Self::Video),
3839 4 => Ok(Self::Voice),
3840
3841 _ => Err(::fidl_next::UnknownStrictEnumMemberError::new(value.into())),
3842 }
3843 }
3844 }
3845
3846 impl ::std::convert::From<WlanAccessCategory> for u32 {
3847 fn from(value: WlanAccessCategory) -> Self {
3848 match value {
3849 WlanAccessCategory::Background => 1,
3850 WlanAccessCategory::BestEffort => 2,
3851 WlanAccessCategory::Video => 3,
3852 WlanAccessCategory::Voice => 4,
3853 }
3854 }
3855 }
3856
3857 unsafe impl<___E> ::fidl_next::Encode<crate::wire::WlanAccessCategory, ___E> for WlanAccessCategory
3858 where
3859 ___E: ?Sized,
3860 {
3861 #[inline]
3862 fn encode(
3863 self,
3864 encoder: &mut ___E,
3865 out: &mut ::core::mem::MaybeUninit<crate::wire::WlanAccessCategory>,
3866 _: (),
3867 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3868 ::fidl_next::Encode::encode(&self, encoder, out, ())
3869 }
3870 }
3871
3872 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::WlanAccessCategory, ___E>
3873 for &'a WlanAccessCategory
3874 where
3875 ___E: ?Sized,
3876 {
3877 #[inline]
3878 fn encode(
3879 self,
3880 encoder: &mut ___E,
3881 out: &mut ::core::mem::MaybeUninit<crate::wire::WlanAccessCategory>,
3882 _: (),
3883 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3884 ::fidl_next::munge!(let crate::wire::WlanAccessCategory { value } = out);
3885 let _ = value.write(::fidl_next::wire::Uint32::from(match *self {
3886 WlanAccessCategory::Background => 1,
3887
3888 WlanAccessCategory::BestEffort => 2,
3889
3890 WlanAccessCategory::Video => 3,
3891
3892 WlanAccessCategory::Voice => 4,
3893 }));
3894
3895 Ok(())
3896 }
3897 }
3898
3899 impl ::core::convert::From<crate::wire::WlanAccessCategory> for WlanAccessCategory {
3900 fn from(wire: crate::wire::WlanAccessCategory) -> Self {
3901 match u32::from(wire.value) {
3902 1 => Self::Background,
3903
3904 2 => Self::BestEffort,
3905
3906 3 => Self::Video,
3907
3908 4 => Self::Voice,
3909
3910 _ => unsafe { ::core::hint::unreachable_unchecked() },
3911 }
3912 }
3913 }
3914
3915 impl ::fidl_next::FromWire<crate::wire::WlanAccessCategory> for WlanAccessCategory {
3916 #[inline]
3917 fn from_wire(wire: crate::wire::WlanAccessCategory) -> Self {
3918 Self::from(wire)
3919 }
3920 }
3921
3922 impl ::fidl_next::FromWireRef<crate::wire::WlanAccessCategory> for WlanAccessCategory {
3923 #[inline]
3924 fn from_wire_ref(wire: &crate::wire::WlanAccessCategory) -> Self {
3925 Self::from(*wire)
3926 }
3927 }
3928
3929 #[doc = " Channel information derived from the DSSS parameter set, HT operation,\n and VHT operation IEs, as well as the primary channel on which a frame\n is received.\n\n IEEE Std 802.11-2016, 9.4.2.4 - DSSS Parameter Set element\n IEEE Std 802.11-2016, 9.4.2.57 - HT Operation element\n IEEE Std 802.11-2016, 9.4.2.159 - VHT Operation element\n"]
3930 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
3931 pub struct WlanChannel {
3932 pub primary: u8,
3933
3934 pub cbw: crate::natural::ChannelBandwidth,
3935
3936 pub secondary80: u8,
3937 }
3938
3939 unsafe impl<___E> ::fidl_next::Encode<crate::wire::WlanChannel, ___E> for WlanChannel
3940 where
3941 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
3942 {
3943 #[inline]
3944 fn encode(
3945 self,
3946 encoder_: &mut ___E,
3947 out_: &mut ::core::mem::MaybeUninit<crate::wire::WlanChannel>,
3948 _: (),
3949 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3950 ::fidl_next::munge! {
3951 let crate::wire::WlanChannel {
3952 primary,
3953 cbw,
3954 secondary80,
3955
3956 } = out_;
3957 }
3958
3959 ::fidl_next::Encode::encode(self.primary, encoder_, primary, ())?;
3960
3961 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(primary.as_mut_ptr()) };
3962
3963 ::fidl_next::Encode::encode(self.cbw, encoder_, cbw, ())?;
3964
3965 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(cbw.as_mut_ptr()) };
3966
3967 ::fidl_next::Encode::encode(self.secondary80, encoder_, secondary80, ())?;
3968
3969 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(secondary80.as_mut_ptr()) };
3970
3971 Ok(())
3972 }
3973 }
3974
3975 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::WlanChannel, ___E> for &'a WlanChannel
3976 where
3977 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
3978 {
3979 #[inline]
3980 fn encode(
3981 self,
3982 encoder_: &mut ___E,
3983 out_: &mut ::core::mem::MaybeUninit<crate::wire::WlanChannel>,
3984 _: (),
3985 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
3986 ::fidl_next::munge! {
3987 let crate::wire::WlanChannel {
3988 primary,
3989 cbw,
3990 secondary80,
3991
3992 } = out_;
3993 }
3994
3995 ::fidl_next::Encode::encode(&self.primary, encoder_, primary, ())?;
3996
3997 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(primary.as_mut_ptr()) };
3998
3999 ::fidl_next::Encode::encode(&self.cbw, encoder_, cbw, ())?;
4000
4001 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(cbw.as_mut_ptr()) };
4002
4003 ::fidl_next::Encode::encode(&self.secondary80, encoder_, secondary80, ())?;
4004
4005 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(secondary80.as_mut_ptr()) };
4006
4007 Ok(())
4008 }
4009 }
4010
4011 unsafe impl<___E>
4012 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::WlanChannel>, ___E>
4013 for WlanChannel
4014 where
4015 ___E: ::fidl_next::Encoder + ?Sized,
4016 WlanChannel: ::fidl_next::Encode<crate::wire::WlanChannel, ___E>,
4017 {
4018 #[inline]
4019 fn encode_option(
4020 this: ::core::option::Option<Self>,
4021 encoder: &mut ___E,
4022 out: &mut ::core::mem::MaybeUninit<
4023 ::fidl_next::wire::Box<'static, crate::wire::WlanChannel>,
4024 >,
4025 _: (),
4026 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
4027 if let Some(inner) = this {
4028 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
4029 ::fidl_next::wire::Box::encode_present(out);
4030 } else {
4031 ::fidl_next::wire::Box::encode_absent(out);
4032 }
4033
4034 Ok(())
4035 }
4036 }
4037
4038 unsafe impl<'a, ___E>
4039 ::fidl_next::EncodeOption<::fidl_next::wire::Box<'static, crate::wire::WlanChannel>, ___E>
4040 for &'a WlanChannel
4041 where
4042 ___E: ::fidl_next::Encoder + ?Sized,
4043 &'a WlanChannel: ::fidl_next::Encode<crate::wire::WlanChannel, ___E>,
4044 {
4045 #[inline]
4046 fn encode_option(
4047 this: ::core::option::Option<Self>,
4048 encoder: &mut ___E,
4049 out: &mut ::core::mem::MaybeUninit<
4050 ::fidl_next::wire::Box<'static, crate::wire::WlanChannel>,
4051 >,
4052 _: (),
4053 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
4054 if let Some(inner) = this {
4055 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
4056 ::fidl_next::wire::Box::encode_present(out);
4057 } else {
4058 ::fidl_next::wire::Box::encode_absent(out);
4059 }
4060
4061 Ok(())
4062 }
4063 }
4064
4065 impl ::fidl_next::FromWire<crate::wire::WlanChannel> for WlanChannel {
4066 #[inline]
4067 fn from_wire(wire: crate::wire::WlanChannel) -> Self {
4068 Self {
4069 primary: ::fidl_next::FromWire::from_wire(wire.primary),
4070
4071 cbw: ::fidl_next::FromWire::from_wire(wire.cbw),
4072
4073 secondary80: ::fidl_next::FromWire::from_wire(wire.secondary80),
4074 }
4075 }
4076 }
4077
4078 impl ::fidl_next::FromWireRef<crate::wire::WlanChannel> for WlanChannel {
4079 #[inline]
4080 fn from_wire_ref(wire: &crate::wire::WlanChannel) -> Self {
4081 Self {
4082 primary: ::fidl_next::FromWireRef::from_wire_ref(&wire.primary),
4083
4084 cbw: ::fidl_next::FromWireRef::from_wire_ref(&wire.cbw),
4085
4086 secondary80: ::fidl_next::FromWireRef::from_wire_ref(&wire.secondary80),
4087 }
4088 }
4089 }
4090
4091 #[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
4092 #[repr(u32)]
4093 pub enum WlanPhyType {
4094 Dsss = 1,
4095 Hr = 2,
4096 Ofdm = 3,
4097 Erp = 4,
4098 Ht = 5,
4099 Dmg = 6,
4100 Vht = 7,
4101 Tvht = 8,
4102 S1G = 9,
4103 Cdmg = 10,
4104 Cmmg = 11,
4105 He = 12,
4106 UnknownOrdinal_(u32) = 13,
4107 }
4108 impl ::std::convert::From<u32> for WlanPhyType {
4109 fn from(value: u32) -> Self {
4110 match value {
4111 1 => Self::Dsss,
4112 2 => Self::Hr,
4113 3 => Self::Ofdm,
4114 4 => Self::Erp,
4115 5 => Self::Ht,
4116 6 => Self::Dmg,
4117 7 => Self::Vht,
4118 8 => Self::Tvht,
4119 9 => Self::S1G,
4120 10 => Self::Cdmg,
4121 11 => Self::Cmmg,
4122 12 => Self::He,
4123
4124 _ => Self::UnknownOrdinal_(value),
4125 }
4126 }
4127 }
4128
4129 impl ::std::convert::From<WlanPhyType> for u32 {
4130 fn from(value: WlanPhyType) -> Self {
4131 match value {
4132 WlanPhyType::Dsss => 1,
4133 WlanPhyType::Hr => 2,
4134 WlanPhyType::Ofdm => 3,
4135 WlanPhyType::Erp => 4,
4136 WlanPhyType::Ht => 5,
4137 WlanPhyType::Dmg => 6,
4138 WlanPhyType::Vht => 7,
4139 WlanPhyType::Tvht => 8,
4140 WlanPhyType::S1G => 9,
4141 WlanPhyType::Cdmg => 10,
4142 WlanPhyType::Cmmg => 11,
4143 WlanPhyType::He => 12,
4144
4145 WlanPhyType::UnknownOrdinal_(value) => value,
4146 }
4147 }
4148 }
4149
4150 unsafe impl<___E> ::fidl_next::Encode<crate::wire::WlanPhyType, ___E> for WlanPhyType
4151 where
4152 ___E: ?Sized,
4153 {
4154 #[inline]
4155 fn encode(
4156 self,
4157 encoder: &mut ___E,
4158 out: &mut ::core::mem::MaybeUninit<crate::wire::WlanPhyType>,
4159 _: (),
4160 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
4161 ::fidl_next::Encode::encode(&self, encoder, out, ())
4162 }
4163 }
4164
4165 unsafe impl<'a, ___E> ::fidl_next::Encode<crate::wire::WlanPhyType, ___E> for &'a WlanPhyType
4166 where
4167 ___E: ?Sized,
4168 {
4169 #[inline]
4170 fn encode(
4171 self,
4172 encoder: &mut ___E,
4173 out: &mut ::core::mem::MaybeUninit<crate::wire::WlanPhyType>,
4174 _: (),
4175 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
4176 ::fidl_next::munge!(let crate::wire::WlanPhyType { value } = out);
4177 let _ = value.write(::fidl_next::wire::Uint32::from(match *self {
4178 WlanPhyType::Dsss => 1,
4179
4180 WlanPhyType::Hr => 2,
4181
4182 WlanPhyType::Ofdm => 3,
4183
4184 WlanPhyType::Erp => 4,
4185
4186 WlanPhyType::Ht => 5,
4187
4188 WlanPhyType::Dmg => 6,
4189
4190 WlanPhyType::Vht => 7,
4191
4192 WlanPhyType::Tvht => 8,
4193
4194 WlanPhyType::S1G => 9,
4195
4196 WlanPhyType::Cdmg => 10,
4197
4198 WlanPhyType::Cmmg => 11,
4199
4200 WlanPhyType::He => 12,
4201
4202 WlanPhyType::UnknownOrdinal_(value) => value,
4203 }));
4204
4205 Ok(())
4206 }
4207 }
4208
4209 impl ::core::convert::From<crate::wire::WlanPhyType> for WlanPhyType {
4210 fn from(wire: crate::wire::WlanPhyType) -> Self {
4211 match u32::from(wire.value) {
4212 1 => Self::Dsss,
4213
4214 2 => Self::Hr,
4215
4216 3 => Self::Ofdm,
4217
4218 4 => Self::Erp,
4219
4220 5 => Self::Ht,
4221
4222 6 => Self::Dmg,
4223
4224 7 => Self::Vht,
4225
4226 8 => Self::Tvht,
4227
4228 9 => Self::S1G,
4229
4230 10 => Self::Cdmg,
4231
4232 11 => Self::Cmmg,
4233
4234 12 => Self::He,
4235
4236 value => Self::UnknownOrdinal_(value),
4237 }
4238 }
4239 }
4240
4241 impl ::fidl_next::FromWire<crate::wire::WlanPhyType> for WlanPhyType {
4242 #[inline]
4243 fn from_wire(wire: crate::wire::WlanPhyType) -> Self {
4244 Self::from(wire)
4245 }
4246 }
4247
4248 impl ::fidl_next::FromWireRef<crate::wire::WlanPhyType> for WlanPhyType {
4249 #[inline]
4250 fn from_wire_ref(wire: &crate::wire::WlanPhyType) -> Self {
4251 Self::from(*wire)
4252 }
4253 }
4254}
4255
4256pub mod wire {
4257
4258 pub type MacAddr = [u8; 6];
4260
4261 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
4263 #[repr(transparent)]
4264 pub struct BssType {
4265 pub(crate) value: ::fidl_next::wire::Uint32,
4266 }
4267
4268 impl ::fidl_next::Constrained for BssType {
4269 type Constraint = ();
4270
4271 fn validate(
4272 _: ::fidl_next::Slot<'_, Self>,
4273 _: Self::Constraint,
4274 ) -> Result<(), ::fidl_next::ValidationError> {
4275 Ok(())
4276 }
4277 }
4278
4279 unsafe impl ::fidl_next::Wire for BssType {
4280 type Narrowed<'de> = Self;
4281
4282 #[inline]
4283 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
4284 }
4286 }
4287
4288 impl BssType {
4289 pub const UNKNOWN: BssType = BssType { value: ::fidl_next::wire::Uint32(0) };
4290
4291 pub const INFRASTRUCTURE: BssType = BssType { value: ::fidl_next::wire::Uint32(1) };
4292
4293 pub const INDEPENDENT: BssType = BssType { value: ::fidl_next::wire::Uint32(2) };
4294
4295 pub const MESH: BssType = BssType { value: ::fidl_next::wire::Uint32(3) };
4296
4297 pub const PERSONAL: BssType = BssType { value: ::fidl_next::wire::Uint32(4) };
4298 }
4299
4300 unsafe impl<___D> ::fidl_next::Decode<___D> for BssType
4301 where
4302 ___D: ?Sized,
4303 {
4304 fn decode(
4305 slot: ::fidl_next::Slot<'_, Self>,
4306 _: &mut ___D,
4307 _: (),
4308 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4309 Ok(())
4310 }
4311 }
4312
4313 impl ::core::convert::From<crate::natural::BssType> for BssType {
4314 fn from(natural: crate::natural::BssType) -> Self {
4315 match natural {
4316 crate::natural::BssType::Unknown => BssType::UNKNOWN,
4317
4318 crate::natural::BssType::Infrastructure => BssType::INFRASTRUCTURE,
4319
4320 crate::natural::BssType::Independent => BssType::INDEPENDENT,
4321
4322 crate::natural::BssType::Mesh => BssType::MESH,
4323
4324 crate::natural::BssType::Personal => BssType::PERSONAL,
4325
4326 crate::natural::BssType::UnknownOrdinal_(value) => {
4327 BssType { value: ::fidl_next::wire::Uint32::from(value) }
4328 }
4329 }
4330 }
4331 }
4332
4333 impl ::fidl_next::IntoNatural for BssType {
4334 type Natural = crate::natural::BssType;
4335 }
4336
4337 pub type CapabilityInfo = ::fidl_next::wire::Uint16;
4339
4340 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
4342 #[repr(transparent)]
4343 pub struct WlanBand {
4344 pub(crate) value: u8,
4345 }
4346
4347 impl ::fidl_next::Constrained for WlanBand {
4348 type Constraint = ();
4349
4350 fn validate(
4351 _: ::fidl_next::Slot<'_, Self>,
4352 _: Self::Constraint,
4353 ) -> Result<(), ::fidl_next::ValidationError> {
4354 Ok(())
4355 }
4356 }
4357
4358 unsafe impl ::fidl_next::Wire for WlanBand {
4359 type Narrowed<'de> = Self;
4360
4361 #[inline]
4362 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
4363 }
4365 }
4366
4367 impl WlanBand {
4368 pub const TWO_GHZ: WlanBand = WlanBand { value: 0 };
4369
4370 pub const FIVE_GHZ: WlanBand = WlanBand { value: 1 };
4371 }
4372
4373 unsafe impl<___D> ::fidl_next::Decode<___D> for WlanBand
4374 where
4375 ___D: ?Sized,
4376 {
4377 fn decode(
4378 slot: ::fidl_next::Slot<'_, Self>,
4379 _: &mut ___D,
4380 _: (),
4381 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4382 Ok(())
4383 }
4384 }
4385
4386 impl ::core::convert::From<crate::natural::WlanBand> for WlanBand {
4387 fn from(natural: crate::natural::WlanBand) -> Self {
4388 match natural {
4389 crate::natural::WlanBand::TwoGhz => WlanBand::TWO_GHZ,
4390
4391 crate::natural::WlanBand::FiveGhz => WlanBand::FIVE_GHZ,
4392
4393 crate::natural::WlanBand::UnknownOrdinal_(value) => {
4394 WlanBand { value: u8::from(value) }
4395 }
4396 }
4397 }
4398 }
4399
4400 impl ::fidl_next::IntoNatural for WlanBand {
4401 type Natural = crate::natural::WlanBand;
4402 }
4403
4404 #[derive(Clone, Debug)]
4406 #[repr(C)]
4407 pub struct ChannelNumber {
4408 pub band: crate::wire::WlanBand,
4409
4410 pub number: u8,
4411 }
4412
4413 static_assertions::const_assert_eq!(std::mem::size_of::<ChannelNumber>(), 2);
4414 static_assertions::const_assert_eq!(std::mem::align_of::<ChannelNumber>(), 1);
4415
4416 static_assertions::const_assert_eq!(std::mem::offset_of!(ChannelNumber, band), 0);
4417
4418 static_assertions::const_assert_eq!(std::mem::offset_of!(ChannelNumber, number), 1);
4419
4420 impl ::fidl_next::Constrained for ChannelNumber {
4421 type Constraint = ();
4422
4423 fn validate(
4424 _: ::fidl_next::Slot<'_, Self>,
4425 _: Self::Constraint,
4426 ) -> Result<(), ::fidl_next::ValidationError> {
4427 Ok(())
4428 }
4429 }
4430
4431 unsafe impl ::fidl_next::Wire for ChannelNumber {
4432 type Narrowed<'de> = ChannelNumber;
4433
4434 #[inline]
4435 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4436 ::fidl_next::munge! {
4437 let Self {
4438 band,
4439 number,
4440
4441 } = &mut *out_;
4442 }
4443
4444 ::fidl_next::Wire::zero_padding(band);
4445
4446 ::fidl_next::Wire::zero_padding(number);
4447 }
4448 }
4449
4450 unsafe impl<___D> ::fidl_next::Decode<___D> for ChannelNumber
4451 where
4452 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4453 {
4454 fn decode(
4455 slot_: ::fidl_next::Slot<'_, Self>,
4456 decoder_: &mut ___D,
4457 _: (),
4458 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4459 ::fidl_next::munge! {
4460 let Self {
4461 mut band,
4462 mut number,
4463
4464 } = slot_;
4465 }
4466
4467 let _field = band.as_mut();
4468
4469 ::fidl_next::Decode::decode(band.as_mut(), decoder_, ())?;
4470
4471 let _field = number.as_mut();
4472
4473 ::fidl_next::Decode::decode(number.as_mut(), decoder_, ())?;
4474
4475 Ok(())
4476 }
4477 }
4478
4479 impl ::fidl_next::IntoNatural for ChannelNumber {
4480 type Natural = crate::natural::ChannelNumber;
4481 }
4482
4483 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
4485 #[repr(transparent)]
4486 pub struct ChannelBandwidth {
4487 pub(crate) value: ::fidl_next::wire::Uint32,
4488 }
4489
4490 impl ::fidl_next::Constrained for ChannelBandwidth {
4491 type Constraint = ();
4492
4493 fn validate(
4494 _: ::fidl_next::Slot<'_, Self>,
4495 _: Self::Constraint,
4496 ) -> Result<(), ::fidl_next::ValidationError> {
4497 Ok(())
4498 }
4499 }
4500
4501 unsafe impl ::fidl_next::Wire for ChannelBandwidth {
4502 type Narrowed<'de> = Self;
4503
4504 #[inline]
4505 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
4506 }
4508 }
4509
4510 impl ChannelBandwidth {
4511 pub const CBW20: ChannelBandwidth =
4512 ChannelBandwidth { value: ::fidl_next::wire::Uint32(1) };
4513
4514 pub const CBW40: ChannelBandwidth =
4515 ChannelBandwidth { value: ::fidl_next::wire::Uint32(2) };
4516
4517 pub const CBW40_BELOW: ChannelBandwidth =
4518 ChannelBandwidth { value: ::fidl_next::wire::Uint32(3) };
4519
4520 pub const CBW80: ChannelBandwidth =
4521 ChannelBandwidth { value: ::fidl_next::wire::Uint32(4) };
4522
4523 pub const CBW160: ChannelBandwidth =
4524 ChannelBandwidth { value: ::fidl_next::wire::Uint32(5) };
4525
4526 pub const CBW80_P80: ChannelBandwidth =
4527 ChannelBandwidth { value: ::fidl_next::wire::Uint32(6) };
4528 }
4529
4530 unsafe impl<___D> ::fidl_next::Decode<___D> for ChannelBandwidth
4531 where
4532 ___D: ?Sized,
4533 {
4534 fn decode(
4535 slot: ::fidl_next::Slot<'_, Self>,
4536 _: &mut ___D,
4537 _: (),
4538 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4539 Ok(())
4540 }
4541 }
4542
4543 impl ::core::convert::From<crate::natural::ChannelBandwidth> for ChannelBandwidth {
4544 fn from(natural: crate::natural::ChannelBandwidth) -> Self {
4545 match natural {
4546 crate::natural::ChannelBandwidth::Cbw20 => ChannelBandwidth::CBW20,
4547
4548 crate::natural::ChannelBandwidth::Cbw40 => ChannelBandwidth::CBW40,
4549
4550 crate::natural::ChannelBandwidth::Cbw40Below => ChannelBandwidth::CBW40_BELOW,
4551
4552 crate::natural::ChannelBandwidth::Cbw80 => ChannelBandwidth::CBW80,
4553
4554 crate::natural::ChannelBandwidth::Cbw160 => ChannelBandwidth::CBW160,
4555
4556 crate::natural::ChannelBandwidth::Cbw80P80 => ChannelBandwidth::CBW80_P80,
4557
4558 crate::natural::ChannelBandwidth::UnknownOrdinal_(value) => {
4559 ChannelBandwidth { value: ::fidl_next::wire::Uint32::from(value) }
4560 }
4561 }
4562 }
4563 }
4564
4565 impl ::fidl_next::IntoNatural for ChannelBandwidth {
4566 type Natural = crate::natural::ChannelBandwidth;
4567 }
4568
4569 #[derive(Debug)]
4571 #[repr(C)]
4572 pub struct BssDescription<'de> {
4573 pub bssid: [u8; 6],
4574
4575 pub bss_type: crate::wire::BssType,
4576
4577 pub beacon_period: ::fidl_next::wire::Uint16,
4578
4579 pub capability_info: ::fidl_next::wire::Uint16,
4580
4581 pub ies: ::fidl_next::wire::Vector<'de, u8>,
4582
4583 pub primary: crate::wire::ChannelNumber,
4584
4585 pub bandwidth: crate::wire::ChannelBandwidth,
4586
4587 pub vht_secondary_80_channel: crate::wire::ChannelNumber,
4588
4589 pub rssi_dbm: i8,
4590
4591 pub snr_db: i8,
4592 }
4593
4594 static_assertions::const_assert_eq!(std::mem::size_of::<BssDescription<'_>>(), 48);
4595 static_assertions::const_assert_eq!(std::mem::align_of::<BssDescription<'_>>(), 8);
4596
4597 static_assertions::const_assert_eq!(std::mem::offset_of!(BssDescription<'_>, bssid), 0);
4598
4599 static_assertions::const_assert_eq!(std::mem::offset_of!(BssDescription<'_>, bss_type), 8);
4600
4601 static_assertions::const_assert_eq!(
4602 std::mem::offset_of!(BssDescription<'_>, beacon_period),
4603 12
4604 );
4605
4606 static_assertions::const_assert_eq!(
4607 std::mem::offset_of!(BssDescription<'_>, capability_info),
4608 14
4609 );
4610
4611 static_assertions::const_assert_eq!(std::mem::offset_of!(BssDescription<'_>, ies), 16);
4612
4613 static_assertions::const_assert_eq!(std::mem::offset_of!(BssDescription<'_>, primary), 32);
4614
4615 static_assertions::const_assert_eq!(std::mem::offset_of!(BssDescription<'_>, bandwidth), 36);
4616
4617 static_assertions::const_assert_eq!(
4618 std::mem::offset_of!(BssDescription<'_>, vht_secondary_80_channel),
4619 40
4620 );
4621
4622 static_assertions::const_assert_eq!(std::mem::offset_of!(BssDescription<'_>, rssi_dbm), 42);
4623
4624 static_assertions::const_assert_eq!(std::mem::offset_of!(BssDescription<'_>, snr_db), 43);
4625
4626 impl ::fidl_next::Constrained for BssDescription<'_> {
4627 type Constraint = ();
4628
4629 fn validate(
4630 _: ::fidl_next::Slot<'_, Self>,
4631 _: Self::Constraint,
4632 ) -> Result<(), ::fidl_next::ValidationError> {
4633 Ok(())
4634 }
4635 }
4636
4637 unsafe impl ::fidl_next::Wire for BssDescription<'static> {
4638 type Narrowed<'de> = BssDescription<'de>;
4639
4640 #[inline]
4641 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4642 ::fidl_next::munge! {
4643 let Self {
4644 bssid,
4645 bss_type,
4646 beacon_period,
4647 capability_info,
4648 ies,
4649 primary,
4650 bandwidth,
4651 vht_secondary_80_channel,
4652 rssi_dbm,
4653 snr_db,
4654
4655 } = &mut *out_;
4656 }
4657
4658 ::fidl_next::Wire::zero_padding(bssid);
4659
4660 ::fidl_next::Wire::zero_padding(bss_type);
4661
4662 ::fidl_next::Wire::zero_padding(beacon_period);
4663
4664 ::fidl_next::Wire::zero_padding(capability_info);
4665
4666 ::fidl_next::Wire::zero_padding(ies);
4667
4668 ::fidl_next::Wire::zero_padding(primary);
4669
4670 ::fidl_next::Wire::zero_padding(bandwidth);
4671
4672 ::fidl_next::Wire::zero_padding(vht_secondary_80_channel);
4673
4674 ::fidl_next::Wire::zero_padding(rssi_dbm);
4675
4676 ::fidl_next::Wire::zero_padding(snr_db);
4677
4678 unsafe {
4679 out_.as_mut_ptr().cast::<u8>().add(44).write_bytes(0, 4);
4680 }
4681
4682 unsafe {
4683 out_.as_mut_ptr().cast::<u8>().add(34).write_bytes(0, 2);
4684 }
4685
4686 unsafe {
4687 out_.as_mut_ptr().cast::<u8>().add(6).write_bytes(0, 2);
4688 }
4689 }
4690 }
4691
4692 unsafe impl<'de, ___D> ::fidl_next::Decode<___D> for BssDescription<'de>
4693 where
4694 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4695 ___D: ::fidl_next::Decoder<'de>,
4696 {
4697 fn decode(
4698 slot_: ::fidl_next::Slot<'_, Self>,
4699 decoder_: &mut ___D,
4700 _: (),
4701 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4702 if slot_.as_bytes()[44..48] != [0u8; 4] {
4703 return Err(::fidl_next::DecodeError::InvalidPadding);
4704 }
4705
4706 if slot_.as_bytes()[34..36] != [0u8; 2] {
4707 return Err(::fidl_next::DecodeError::InvalidPadding);
4708 }
4709
4710 if slot_.as_bytes()[6..8] != [0u8; 2] {
4711 return Err(::fidl_next::DecodeError::InvalidPadding);
4712 }
4713
4714 ::fidl_next::munge! {
4715 let Self {
4716 mut bssid,
4717 mut bss_type,
4718 mut beacon_period,
4719 mut capability_info,
4720 mut ies,
4721 mut primary,
4722 mut bandwidth,
4723 mut vht_secondary_80_channel,
4724 mut rssi_dbm,
4725 mut snr_db,
4726
4727 } = slot_;
4728 }
4729
4730 let _field = bssid.as_mut();
4731
4732 ::fidl_next::Decode::decode(bssid.as_mut(), decoder_, ())?;
4733
4734 let _field = bss_type.as_mut();
4735
4736 ::fidl_next::Decode::decode(bss_type.as_mut(), decoder_, ())?;
4737
4738 let _field = beacon_period.as_mut();
4739
4740 ::fidl_next::Decode::decode(beacon_period.as_mut(), decoder_, ())?;
4741
4742 let _field = capability_info.as_mut();
4743
4744 ::fidl_next::Decode::decode(capability_info.as_mut(), decoder_, ())?;
4745
4746 let _field = ies.as_mut();
4747 ::fidl_next::Constrained::validate(_field, (4294967295, ()))?;
4748 ::fidl_next::Decode::decode(ies.as_mut(), decoder_, (4294967295, ()))?;
4749
4750 let _field = primary.as_mut();
4751
4752 ::fidl_next::Decode::decode(primary.as_mut(), decoder_, ())?;
4753
4754 let _field = bandwidth.as_mut();
4755
4756 ::fidl_next::Decode::decode(bandwidth.as_mut(), decoder_, ())?;
4757
4758 let _field = vht_secondary_80_channel.as_mut();
4759
4760 ::fidl_next::Decode::decode(vht_secondary_80_channel.as_mut(), decoder_, ())?;
4761
4762 let _field = rssi_dbm.as_mut();
4763
4764 ::fidl_next::Decode::decode(rssi_dbm.as_mut(), decoder_, ())?;
4765
4766 let _field = snr_db.as_mut();
4767
4768 ::fidl_next::Decode::decode(snr_db.as_mut(), decoder_, ())?;
4769
4770 Ok(())
4771 }
4772 }
4773
4774 impl<'de> ::fidl_next::IntoNatural for BssDescription<'de> {
4775 type Natural = crate::natural::BssDescription;
4776 }
4777
4778 #[derive(Clone, Debug)]
4780 #[repr(C)]
4781 pub struct CSsid {
4782 pub len: u8,
4783
4784 pub data: [u8; 32],
4785 }
4786
4787 static_assertions::const_assert_eq!(std::mem::size_of::<CSsid>(), 33);
4788 static_assertions::const_assert_eq!(std::mem::align_of::<CSsid>(), 1);
4789
4790 static_assertions::const_assert_eq!(std::mem::offset_of!(CSsid, len), 0);
4791
4792 static_assertions::const_assert_eq!(std::mem::offset_of!(CSsid, data), 1);
4793
4794 impl ::fidl_next::Constrained for CSsid {
4795 type Constraint = ();
4796
4797 fn validate(
4798 _: ::fidl_next::Slot<'_, Self>,
4799 _: Self::Constraint,
4800 ) -> Result<(), ::fidl_next::ValidationError> {
4801 Ok(())
4802 }
4803 }
4804
4805 unsafe impl ::fidl_next::Wire for CSsid {
4806 type Narrowed<'de> = CSsid;
4807
4808 #[inline]
4809 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4810 ::fidl_next::munge! {
4811 let Self {
4812 len,
4813 data,
4814
4815 } = &mut *out_;
4816 }
4817
4818 ::fidl_next::Wire::zero_padding(len);
4819
4820 ::fidl_next::Wire::zero_padding(data);
4821 }
4822 }
4823
4824 unsafe impl<___D> ::fidl_next::Decode<___D> for CSsid
4825 where
4826 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4827 {
4828 fn decode(
4829 slot_: ::fidl_next::Slot<'_, Self>,
4830 decoder_: &mut ___D,
4831 _: (),
4832 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4833 ::fidl_next::munge! {
4834 let Self {
4835 mut len,
4836 mut data,
4837
4838 } = slot_;
4839 }
4840
4841 let _field = len.as_mut();
4842
4843 ::fidl_next::Decode::decode(len.as_mut(), decoder_, ())?;
4844
4845 let _field = data.as_mut();
4846
4847 ::fidl_next::Decode::decode(data.as_mut(), decoder_, ())?;
4848
4849 Ok(())
4850 }
4851 }
4852
4853 impl ::fidl_next::IntoNatural for CSsid {
4854 type Natural = crate::natural::CSsid;
4855 }
4856
4857 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
4859 #[repr(transparent)]
4860 pub struct CipherSuiteType {
4861 pub(crate) value: ::fidl_next::wire::Uint32,
4862 }
4863
4864 impl ::fidl_next::Constrained for CipherSuiteType {
4865 type Constraint = ();
4866
4867 fn validate(
4868 _: ::fidl_next::Slot<'_, Self>,
4869 _: Self::Constraint,
4870 ) -> Result<(), ::fidl_next::ValidationError> {
4871 Ok(())
4872 }
4873 }
4874
4875 unsafe impl ::fidl_next::Wire for CipherSuiteType {
4876 type Narrowed<'de> = Self;
4877
4878 #[inline]
4879 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
4880 }
4882 }
4883
4884 impl CipherSuiteType {
4885 pub const USE_GROUP: CipherSuiteType =
4886 CipherSuiteType { value: ::fidl_next::wire::Uint32(0) };
4887
4888 pub const WEP_40: CipherSuiteType = CipherSuiteType { value: ::fidl_next::wire::Uint32(1) };
4889
4890 pub const TKIP: CipherSuiteType = CipherSuiteType { value: ::fidl_next::wire::Uint32(2) };
4891
4892 pub const RESERVED_3: CipherSuiteType =
4893 CipherSuiteType { value: ::fidl_next::wire::Uint32(3) };
4894
4895 pub const CCMP_128: CipherSuiteType =
4896 CipherSuiteType { value: ::fidl_next::wire::Uint32(4) };
4897
4898 pub const WEP_104: CipherSuiteType =
4899 CipherSuiteType { value: ::fidl_next::wire::Uint32(5) };
4900
4901 pub const BIP_CMAC_128: CipherSuiteType =
4902 CipherSuiteType { value: ::fidl_next::wire::Uint32(6) };
4903
4904 pub const GROUP_ADDRESSED_NOT_ALLOWED: CipherSuiteType =
4905 CipherSuiteType { value: ::fidl_next::wire::Uint32(7) };
4906
4907 pub const GCMP_128: CipherSuiteType =
4908 CipherSuiteType { value: ::fidl_next::wire::Uint32(8) };
4909
4910 pub const GCMP_256: CipherSuiteType =
4911 CipherSuiteType { value: ::fidl_next::wire::Uint32(9) };
4912
4913 pub const CCMP_256: CipherSuiteType =
4914 CipherSuiteType { value: ::fidl_next::wire::Uint32(10) };
4915
4916 pub const BIP_GMAC_128: CipherSuiteType =
4917 CipherSuiteType { value: ::fidl_next::wire::Uint32(11) };
4918
4919 pub const BIP_GMAC_256: CipherSuiteType =
4920 CipherSuiteType { value: ::fidl_next::wire::Uint32(12) };
4921
4922 pub const BIP_CMAC_256: CipherSuiteType =
4923 CipherSuiteType { value: ::fidl_next::wire::Uint32(13) };
4924
4925 pub const RESERVED_14_TO_255: CipherSuiteType =
4926 CipherSuiteType { value: ::fidl_next::wire::Uint32(14) };
4927 }
4928
4929 unsafe impl<___D> ::fidl_next::Decode<___D> for CipherSuiteType
4930 where
4931 ___D: ?Sized,
4932 {
4933 fn decode(
4934 slot: ::fidl_next::Slot<'_, Self>,
4935 _: &mut ___D,
4936 _: (),
4937 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4938 Ok(())
4939 }
4940 }
4941
4942 impl ::core::convert::From<crate::natural::CipherSuiteType> for CipherSuiteType {
4943 fn from(natural: crate::natural::CipherSuiteType) -> Self {
4944 match natural {
4945 crate::natural::CipherSuiteType::UseGroup => CipherSuiteType::USE_GROUP,
4946
4947 crate::natural::CipherSuiteType::Wep40 => CipherSuiteType::WEP_40,
4948
4949 crate::natural::CipherSuiteType::Tkip => CipherSuiteType::TKIP,
4950
4951 crate::natural::CipherSuiteType::Reserved3 => CipherSuiteType::RESERVED_3,
4952
4953 crate::natural::CipherSuiteType::Ccmp128 => CipherSuiteType::CCMP_128,
4954
4955 crate::natural::CipherSuiteType::Wep104 => CipherSuiteType::WEP_104,
4956
4957 crate::natural::CipherSuiteType::BipCmac128 => CipherSuiteType::BIP_CMAC_128,
4958
4959 crate::natural::CipherSuiteType::GroupAddressedNotAllowed => {
4960 CipherSuiteType::GROUP_ADDRESSED_NOT_ALLOWED
4961 }
4962
4963 crate::natural::CipherSuiteType::Gcmp128 => CipherSuiteType::GCMP_128,
4964
4965 crate::natural::CipherSuiteType::Gcmp256 => CipherSuiteType::GCMP_256,
4966
4967 crate::natural::CipherSuiteType::Ccmp256 => CipherSuiteType::CCMP_256,
4968
4969 crate::natural::CipherSuiteType::BipGmac128 => CipherSuiteType::BIP_GMAC_128,
4970
4971 crate::natural::CipherSuiteType::BipGmac256 => CipherSuiteType::BIP_GMAC_256,
4972
4973 crate::natural::CipherSuiteType::BipCmac256 => CipherSuiteType::BIP_CMAC_256,
4974
4975 crate::natural::CipherSuiteType::Reserved14To255 => {
4976 CipherSuiteType::RESERVED_14_TO_255
4977 }
4978
4979 crate::natural::CipherSuiteType::UnknownOrdinal_(value) => {
4980 CipherSuiteType { value: ::fidl_next::wire::Uint32::from(value) }
4981 }
4982 }
4983 }
4984 }
4985
4986 impl ::fidl_next::IntoNatural for CipherSuiteType {
4987 type Natural = crate::natural::CipherSuiteType;
4988 }
4989
4990 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
4992 #[repr(transparent)]
4993 pub struct GuardInterval {
4994 pub(crate) value: u8,
4995 }
4996
4997 impl ::fidl_next::Constrained for GuardInterval {
4998 type Constraint = ();
4999
5000 fn validate(
5001 _: ::fidl_next::Slot<'_, Self>,
5002 _: Self::Constraint,
5003 ) -> Result<(), ::fidl_next::ValidationError> {
5004 Ok(())
5005 }
5006 }
5007
5008 unsafe impl ::fidl_next::Wire for GuardInterval {
5009 type Narrowed<'de> = Self;
5010
5011 #[inline]
5012 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
5013 }
5015 }
5016
5017 impl GuardInterval {
5018 pub const LONG_GI: GuardInterval = GuardInterval { value: 1 };
5019
5020 pub const SHORT_GI: GuardInterval = GuardInterval { value: 2 };
5021 }
5022
5023 unsafe impl<___D> ::fidl_next::Decode<___D> for GuardInterval
5024 where
5025 ___D: ?Sized,
5026 {
5027 fn decode(
5028 slot: ::fidl_next::Slot<'_, Self>,
5029 _: &mut ___D,
5030 _: (),
5031 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
5032 ::fidl_next::munge!(let Self { value } = slot);
5033
5034 match u8::from(*value) {
5035 1 | 2 => (),
5036 unknown => {
5037 return Err(::fidl_next::DecodeError::InvalidEnumOrdinal(unknown as i128));
5038 }
5039 }
5040
5041 Ok(())
5042 }
5043 }
5044
5045 impl ::core::convert::From<crate::natural::GuardInterval> for GuardInterval {
5046 fn from(natural: crate::natural::GuardInterval) -> Self {
5047 match natural {
5048 crate::natural::GuardInterval::LongGi => GuardInterval::LONG_GI,
5049
5050 crate::natural::GuardInterval::ShortGi => GuardInterval::SHORT_GI,
5051 }
5052 }
5053 }
5054
5055 impl ::fidl_next::IntoNatural for GuardInterval {
5056 type Natural = crate::natural::GuardInterval;
5057 }
5058
5059 #[derive(Clone, Debug)]
5061 #[repr(C)]
5062 pub struct HtCapabilities {
5063 pub bytes: [u8; 26],
5064 }
5065
5066 static_assertions::const_assert_eq!(std::mem::size_of::<HtCapabilities>(), 26);
5067 static_assertions::const_assert_eq!(std::mem::align_of::<HtCapabilities>(), 1);
5068
5069 static_assertions::const_assert_eq!(std::mem::offset_of!(HtCapabilities, bytes), 0);
5070
5071 impl ::fidl_next::Constrained for HtCapabilities {
5072 type Constraint = ();
5073
5074 fn validate(
5075 _: ::fidl_next::Slot<'_, Self>,
5076 _: Self::Constraint,
5077 ) -> Result<(), ::fidl_next::ValidationError> {
5078 Ok(())
5079 }
5080 }
5081
5082 unsafe impl ::fidl_next::Wire for HtCapabilities {
5083 type Narrowed<'de> = HtCapabilities;
5084
5085 #[inline]
5086 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
5087 ::fidl_next::munge! {
5088 let Self {
5089 bytes,
5090
5091 } = &mut *out_;
5092 }
5093
5094 ::fidl_next::Wire::zero_padding(bytes);
5095 }
5096 }
5097
5098 unsafe impl<___D> ::fidl_next::Decode<___D> for HtCapabilities
5099 where
5100 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
5101 {
5102 fn decode(
5103 slot_: ::fidl_next::Slot<'_, Self>,
5104 decoder_: &mut ___D,
5105 _: (),
5106 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
5107 ::fidl_next::munge! {
5108 let Self {
5109 mut bytes,
5110
5111 } = slot_;
5112 }
5113
5114 let _field = bytes.as_mut();
5115
5116 ::fidl_next::Decode::decode(bytes.as_mut(), decoder_, ())?;
5117
5118 Ok(())
5119 }
5120 }
5121
5122 impl ::fidl_next::IntoNatural for HtCapabilities {
5123 type Natural = crate::natural::HtCapabilities;
5124 }
5125
5126 #[derive(Clone, Debug)]
5128 #[repr(C)]
5129 pub struct HtOperation {
5130 pub bytes: [u8; 22],
5131 }
5132
5133 static_assertions::const_assert_eq!(std::mem::size_of::<HtOperation>(), 22);
5134 static_assertions::const_assert_eq!(std::mem::align_of::<HtOperation>(), 1);
5135
5136 static_assertions::const_assert_eq!(std::mem::offset_of!(HtOperation, bytes), 0);
5137
5138 impl ::fidl_next::Constrained for HtOperation {
5139 type Constraint = ();
5140
5141 fn validate(
5142 _: ::fidl_next::Slot<'_, Self>,
5143 _: Self::Constraint,
5144 ) -> Result<(), ::fidl_next::ValidationError> {
5145 Ok(())
5146 }
5147 }
5148
5149 unsafe impl ::fidl_next::Wire for HtOperation {
5150 type Narrowed<'de> = HtOperation;
5151
5152 #[inline]
5153 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
5154 ::fidl_next::munge! {
5155 let Self {
5156 bytes,
5157
5158 } = &mut *out_;
5159 }
5160
5161 ::fidl_next::Wire::zero_padding(bytes);
5162 }
5163 }
5164
5165 unsafe impl<___D> ::fidl_next::Decode<___D> for HtOperation
5166 where
5167 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
5168 {
5169 fn decode(
5170 slot_: ::fidl_next::Slot<'_, Self>,
5171 decoder_: &mut ___D,
5172 _: (),
5173 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
5174 ::fidl_next::munge! {
5175 let Self {
5176 mut bytes,
5177
5178 } = slot_;
5179 }
5180
5181 let _field = bytes.as_mut();
5182
5183 ::fidl_next::Decode::decode(bytes.as_mut(), decoder_, ())?;
5184
5185 Ok(())
5186 }
5187 }
5188
5189 impl ::fidl_next::IntoNatural for HtOperation {
5190 type Natural = crate::natural::HtOperation;
5191 }
5192
5193 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
5195 #[repr(transparent)]
5196 pub struct KeyType {
5197 pub(crate) value: u8,
5198 }
5199
5200 impl ::fidl_next::Constrained for KeyType {
5201 type Constraint = ();
5202
5203 fn validate(
5204 _: ::fidl_next::Slot<'_, Self>,
5205 _: Self::Constraint,
5206 ) -> Result<(), ::fidl_next::ValidationError> {
5207 Ok(())
5208 }
5209 }
5210
5211 unsafe impl ::fidl_next::Wire for KeyType {
5212 type Narrowed<'de> = Self;
5213
5214 #[inline]
5215 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
5216 }
5218 }
5219
5220 impl KeyType {
5221 pub const PAIRWISE: KeyType = KeyType { value: 1 };
5222
5223 pub const GROUP: KeyType = KeyType { value: 2 };
5224
5225 pub const IGTK: KeyType = KeyType { value: 3 };
5226
5227 pub const PEER: KeyType = KeyType { value: 4 };
5228 }
5229
5230 unsafe impl<___D> ::fidl_next::Decode<___D> for KeyType
5231 where
5232 ___D: ?Sized,
5233 {
5234 fn decode(
5235 slot: ::fidl_next::Slot<'_, Self>,
5236 _: &mut ___D,
5237 _: (),
5238 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
5239 Ok(())
5240 }
5241 }
5242
5243 impl ::core::convert::From<crate::natural::KeyType> for KeyType {
5244 fn from(natural: crate::natural::KeyType) -> Self {
5245 match natural {
5246 crate::natural::KeyType::Pairwise => KeyType::PAIRWISE,
5247
5248 crate::natural::KeyType::Group => KeyType::GROUP,
5249
5250 crate::natural::KeyType::Igtk => KeyType::IGTK,
5251
5252 crate::natural::KeyType::Peer => KeyType::PEER,
5253
5254 crate::natural::KeyType::UnknownOrdinal_(value) => {
5255 KeyType { value: u8::from(value) }
5256 }
5257 }
5258 }
5259 }
5260
5261 impl ::fidl_next::IntoNatural for KeyType {
5262 type Natural = crate::natural::KeyType;
5263 }
5264
5265 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
5267 #[repr(transparent)]
5268 pub struct ReasonCode {
5269 pub(crate) value: ::fidl_next::wire::Uint16,
5270 }
5271
5272 impl ::fidl_next::Constrained for ReasonCode {
5273 type Constraint = ();
5274
5275 fn validate(
5276 _: ::fidl_next::Slot<'_, Self>,
5277 _: Self::Constraint,
5278 ) -> Result<(), ::fidl_next::ValidationError> {
5279 Ok(())
5280 }
5281 }
5282
5283 unsafe impl ::fidl_next::Wire for ReasonCode {
5284 type Narrowed<'de> = Self;
5285
5286 #[inline]
5287 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
5288 }
5290 }
5291
5292 impl ReasonCode {
5293 pub const UNSPECIFIED_REASON: ReasonCode =
5294 ReasonCode { value: ::fidl_next::wire::Uint16(1) };
5295
5296 pub const INVALID_AUTHENTICATION: ReasonCode =
5297 ReasonCode { value: ::fidl_next::wire::Uint16(2) };
5298
5299 pub const LEAVING_NETWORK_DEAUTH: ReasonCode =
5300 ReasonCode { value: ::fidl_next::wire::Uint16(3) };
5301
5302 pub const REASON_INACTIVITY: ReasonCode =
5303 ReasonCode { value: ::fidl_next::wire::Uint16(4) };
5304
5305 pub const NO_MORE_STAS: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(5) };
5306
5307 pub const INVALID_CLASS2_FRAME: ReasonCode =
5308 ReasonCode { value: ::fidl_next::wire::Uint16(6) };
5309
5310 pub const INVALID_CLASS3_FRAME: ReasonCode =
5311 ReasonCode { value: ::fidl_next::wire::Uint16(7) };
5312
5313 pub const LEAVING_NETWORK_DISASSOC: ReasonCode =
5314 ReasonCode { value: ::fidl_next::wire::Uint16(8) };
5315
5316 pub const NOT_AUTHENTICATED: ReasonCode =
5317 ReasonCode { value: ::fidl_next::wire::Uint16(9) };
5318
5319 pub const UNACCEPTABLE_POWER_CAPABILITY: ReasonCode =
5320 ReasonCode { value: ::fidl_next::wire::Uint16(10) };
5321
5322 pub const UNACCEPTABLE_SUPPORTED_CHANNELS: ReasonCode =
5323 ReasonCode { value: ::fidl_next::wire::Uint16(11) };
5324
5325 pub const BSS_TRANSITION_DISASSOC: ReasonCode =
5326 ReasonCode { value: ::fidl_next::wire::Uint16(12) };
5327
5328 pub const REASON_INVALID_ELEMENT: ReasonCode =
5329 ReasonCode { value: ::fidl_next::wire::Uint16(13) };
5330
5331 pub const MIC_FAILURE: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(14) };
5332
5333 pub const FOURWAY_HANDSHAKE_TIMEOUT: ReasonCode =
5334 ReasonCode { value: ::fidl_next::wire::Uint16(15) };
5335
5336 pub const GK_HANDSHAKE_TIMEOUT: ReasonCode =
5337 ReasonCode { value: ::fidl_next::wire::Uint16(16) };
5338
5339 pub const HANDSHAKE_ELEMENT_MISMATCH: ReasonCode =
5340 ReasonCode { value: ::fidl_next::wire::Uint16(17) };
5341
5342 pub const REASON_INVALID_GROUP_CIPHER: ReasonCode =
5343 ReasonCode { value: ::fidl_next::wire::Uint16(18) };
5344
5345 pub const REASON_INVALID_PAIRWISE_CIPHER: ReasonCode =
5346 ReasonCode { value: ::fidl_next::wire::Uint16(19) };
5347
5348 pub const REASON_INVALID_AKMP: ReasonCode =
5349 ReasonCode { value: ::fidl_next::wire::Uint16(20) };
5350
5351 pub const UNSUPPORTED_RSNE_VERSION: ReasonCode =
5352 ReasonCode { value: ::fidl_next::wire::Uint16(21) };
5353
5354 pub const INVALID_RSNE_CAPABILITIES: ReasonCode =
5355 ReasonCode { value: ::fidl_next::wire::Uint16(22) };
5356
5357 pub const IEEE802_1_X_AUTH_FAILED: ReasonCode =
5358 ReasonCode { value: ::fidl_next::wire::Uint16(23) };
5359
5360 pub const REASON_CIPHER_OUT_OF_POLICY: ReasonCode =
5361 ReasonCode { value: ::fidl_next::wire::Uint16(24) };
5362
5363 pub const TDLS_PEER_UNREACHABLE: ReasonCode =
5364 ReasonCode { value: ::fidl_next::wire::Uint16(25) };
5365
5366 pub const TDLS_UNSPECIFIED_REASON: ReasonCode =
5367 ReasonCode { value: ::fidl_next::wire::Uint16(26) };
5368
5369 pub const SSP_REQUESTED_DISASSOC: ReasonCode =
5370 ReasonCode { value: ::fidl_next::wire::Uint16(27) };
5371
5372 pub const NO_SSP_ROAMING_AGREEMENT: ReasonCode =
5373 ReasonCode { value: ::fidl_next::wire::Uint16(28) };
5374
5375 pub const BAD_CIPHER_OR_AKM: ReasonCode =
5376 ReasonCode { value: ::fidl_next::wire::Uint16(29) };
5377
5378 pub const NOT_AUTHORIZED_THIS_LOCATION: ReasonCode =
5379 ReasonCode { value: ::fidl_next::wire::Uint16(30) };
5380
5381 pub const SERVICE_CHANGE_PRECLUDES_TS: ReasonCode =
5382 ReasonCode { value: ::fidl_next::wire::Uint16(31) };
5383
5384 pub const UNSPECIFIED_QOS_REASON: ReasonCode =
5385 ReasonCode { value: ::fidl_next::wire::Uint16(32) };
5386
5387 pub const NOT_ENOUGH_BANDWIDTH: ReasonCode =
5388 ReasonCode { value: ::fidl_next::wire::Uint16(33) };
5389
5390 pub const MISSING_ACKS: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(34) };
5391
5392 pub const EXCEEDED_TXOP: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(35) };
5393
5394 pub const STA_LEAVING: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(36) };
5395
5396 pub const END_TS_BA_DLS: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(37) };
5397
5398 pub const UNKNOWN_TS_BA: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(38) };
5399
5400 pub const TIMEOUT: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(39) };
5401
5402 pub const PEERKEY_MISMATCH: ReasonCode =
5403 ReasonCode { value: ::fidl_next::wire::Uint16(45) };
5404
5405 pub const PEER_INITIATED: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(46) };
5406
5407 pub const AP_INITIATED: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(47) };
5408
5409 pub const REASON_INVALID_FT_ACTION_FRAME_COUNT: ReasonCode =
5410 ReasonCode { value: ::fidl_next::wire::Uint16(48) };
5411
5412 pub const REASON_INVALID_PMKID: ReasonCode =
5413 ReasonCode { value: ::fidl_next::wire::Uint16(49) };
5414
5415 pub const REASON_INVALID_MDE: ReasonCode =
5416 ReasonCode { value: ::fidl_next::wire::Uint16(50) };
5417
5418 pub const REASON_INVALID_FTE: ReasonCode =
5419 ReasonCode { value: ::fidl_next::wire::Uint16(51) };
5420
5421 pub const MESH_PEERING_CANCELED: ReasonCode =
5422 ReasonCode { value: ::fidl_next::wire::Uint16(52) };
5423
5424 pub const MESH_MAX_PEERS: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(53) };
5425
5426 pub const MESH_CONFIGURATION_POLICY_VIOLATION: ReasonCode =
5427 ReasonCode { value: ::fidl_next::wire::Uint16(54) };
5428
5429 pub const MESH_CLOSE_RCVD: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(55) };
5430
5431 pub const MESH_MAX_RETRIES: ReasonCode =
5432 ReasonCode { value: ::fidl_next::wire::Uint16(56) };
5433
5434 pub const MESH_CONFIRM_TIMEOUT: ReasonCode =
5435 ReasonCode { value: ::fidl_next::wire::Uint16(57) };
5436
5437 pub const MESH_INVALID_GTK: ReasonCode =
5438 ReasonCode { value: ::fidl_next::wire::Uint16(58) };
5439
5440 pub const MESH_INCONSISTENT_PARAMETERS: ReasonCode =
5441 ReasonCode { value: ::fidl_next::wire::Uint16(59) };
5442
5443 pub const MESH_INVALID_SECURITY_CAPABILITY: ReasonCode =
5444 ReasonCode { value: ::fidl_next::wire::Uint16(60) };
5445
5446 pub const MESH_PATH_ERROR_NO_PROXY_INFORMATION: ReasonCode =
5447 ReasonCode { value: ::fidl_next::wire::Uint16(61) };
5448
5449 pub const MESH_PATH_ERROR_NO_FORWARDING_INFORMATION: ReasonCode =
5450 ReasonCode { value: ::fidl_next::wire::Uint16(62) };
5451
5452 pub const MESH_PATH_ERROR_DESTINATION_UNREACHABLE: ReasonCode =
5453 ReasonCode { value: ::fidl_next::wire::Uint16(63) };
5454
5455 pub const MAC_ADDRESS_ALREADY_EXISTS_IN_MBSS: ReasonCode =
5456 ReasonCode { value: ::fidl_next::wire::Uint16(64) };
5457
5458 pub const MESH_CHANNEL_SWITCH_REGULATORY_REQUIREMENTS: ReasonCode =
5459 ReasonCode { value: ::fidl_next::wire::Uint16(65) };
5460
5461 pub const MESH_CHANNEL_SWITCH_UNSPECIFIED: ReasonCode =
5462 ReasonCode { value: ::fidl_next::wire::Uint16(66) };
5463
5464 pub const MLME_LINK_FAILED: ReasonCode =
5465 ReasonCode { value: ::fidl_next::wire::Uint16(128) };
5466
5467 pub const FW_RX_STALLED: ReasonCode = ReasonCode { value: ::fidl_next::wire::Uint16(129) };
5468
5469 pub const FW_HIGH_WME_RX_ERR_RATE: ReasonCode =
5470 ReasonCode { value: ::fidl_next::wire::Uint16(130) };
5471 }
5472
5473 unsafe impl<___D> ::fidl_next::Decode<___D> for ReasonCode
5474 where
5475 ___D: ?Sized,
5476 {
5477 fn decode(
5478 slot: ::fidl_next::Slot<'_, Self>,
5479 _: &mut ___D,
5480 _: (),
5481 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
5482 Ok(())
5483 }
5484 }
5485
5486 impl ::core::convert::From<crate::natural::ReasonCode> for ReasonCode {
5487 fn from(natural: crate::natural::ReasonCode) -> Self {
5488 match natural {
5489 crate::natural::ReasonCode::UnspecifiedReason => ReasonCode::UNSPECIFIED_REASON,
5490
5491 crate::natural::ReasonCode::InvalidAuthentication => {
5492 ReasonCode::INVALID_AUTHENTICATION
5493 }
5494
5495 crate::natural::ReasonCode::LeavingNetworkDeauth => {
5496 ReasonCode::LEAVING_NETWORK_DEAUTH
5497 }
5498
5499 crate::natural::ReasonCode::ReasonInactivity => ReasonCode::REASON_INACTIVITY,
5500
5501 crate::natural::ReasonCode::NoMoreStas => ReasonCode::NO_MORE_STAS,
5502
5503 crate::natural::ReasonCode::InvalidClass2Frame => ReasonCode::INVALID_CLASS2_FRAME,
5504
5505 crate::natural::ReasonCode::InvalidClass3Frame => ReasonCode::INVALID_CLASS3_FRAME,
5506
5507 crate::natural::ReasonCode::LeavingNetworkDisassoc => {
5508 ReasonCode::LEAVING_NETWORK_DISASSOC
5509 }
5510
5511 crate::natural::ReasonCode::NotAuthenticated => ReasonCode::NOT_AUTHENTICATED,
5512
5513 crate::natural::ReasonCode::UnacceptablePowerCapability => {
5514 ReasonCode::UNACCEPTABLE_POWER_CAPABILITY
5515 }
5516
5517 crate::natural::ReasonCode::UnacceptableSupportedChannels => {
5518 ReasonCode::UNACCEPTABLE_SUPPORTED_CHANNELS
5519 }
5520
5521 crate::natural::ReasonCode::BssTransitionDisassoc => {
5522 ReasonCode::BSS_TRANSITION_DISASSOC
5523 }
5524
5525 crate::natural::ReasonCode::ReasonInvalidElement => {
5526 ReasonCode::REASON_INVALID_ELEMENT
5527 }
5528
5529 crate::natural::ReasonCode::MicFailure => ReasonCode::MIC_FAILURE,
5530
5531 crate::natural::ReasonCode::FourwayHandshakeTimeout => {
5532 ReasonCode::FOURWAY_HANDSHAKE_TIMEOUT
5533 }
5534
5535 crate::natural::ReasonCode::GkHandshakeTimeout => ReasonCode::GK_HANDSHAKE_TIMEOUT,
5536
5537 crate::natural::ReasonCode::HandshakeElementMismatch => {
5538 ReasonCode::HANDSHAKE_ELEMENT_MISMATCH
5539 }
5540
5541 crate::natural::ReasonCode::ReasonInvalidGroupCipher => {
5542 ReasonCode::REASON_INVALID_GROUP_CIPHER
5543 }
5544
5545 crate::natural::ReasonCode::ReasonInvalidPairwiseCipher => {
5546 ReasonCode::REASON_INVALID_PAIRWISE_CIPHER
5547 }
5548
5549 crate::natural::ReasonCode::ReasonInvalidAkmp => ReasonCode::REASON_INVALID_AKMP,
5550
5551 crate::natural::ReasonCode::UnsupportedRsneVersion => {
5552 ReasonCode::UNSUPPORTED_RSNE_VERSION
5553 }
5554
5555 crate::natural::ReasonCode::InvalidRsneCapabilities => {
5556 ReasonCode::INVALID_RSNE_CAPABILITIES
5557 }
5558
5559 crate::natural::ReasonCode::Ieee8021XAuthFailed => {
5560 ReasonCode::IEEE802_1_X_AUTH_FAILED
5561 }
5562
5563 crate::natural::ReasonCode::ReasonCipherOutOfPolicy => {
5564 ReasonCode::REASON_CIPHER_OUT_OF_POLICY
5565 }
5566
5567 crate::natural::ReasonCode::TdlsPeerUnreachable => {
5568 ReasonCode::TDLS_PEER_UNREACHABLE
5569 }
5570
5571 crate::natural::ReasonCode::TdlsUnspecifiedReason => {
5572 ReasonCode::TDLS_UNSPECIFIED_REASON
5573 }
5574
5575 crate::natural::ReasonCode::SspRequestedDisassoc => {
5576 ReasonCode::SSP_REQUESTED_DISASSOC
5577 }
5578
5579 crate::natural::ReasonCode::NoSspRoamingAgreement => {
5580 ReasonCode::NO_SSP_ROAMING_AGREEMENT
5581 }
5582
5583 crate::natural::ReasonCode::BadCipherOrAkm => ReasonCode::BAD_CIPHER_OR_AKM,
5584
5585 crate::natural::ReasonCode::NotAuthorizedThisLocation => {
5586 ReasonCode::NOT_AUTHORIZED_THIS_LOCATION
5587 }
5588
5589 crate::natural::ReasonCode::ServiceChangePrecludesTs => {
5590 ReasonCode::SERVICE_CHANGE_PRECLUDES_TS
5591 }
5592
5593 crate::natural::ReasonCode::UnspecifiedQosReason => {
5594 ReasonCode::UNSPECIFIED_QOS_REASON
5595 }
5596
5597 crate::natural::ReasonCode::NotEnoughBandwidth => ReasonCode::NOT_ENOUGH_BANDWIDTH,
5598
5599 crate::natural::ReasonCode::MissingAcks => ReasonCode::MISSING_ACKS,
5600
5601 crate::natural::ReasonCode::ExceededTxop => ReasonCode::EXCEEDED_TXOP,
5602
5603 crate::natural::ReasonCode::StaLeaving => ReasonCode::STA_LEAVING,
5604
5605 crate::natural::ReasonCode::EndTsBaDls => ReasonCode::END_TS_BA_DLS,
5606
5607 crate::natural::ReasonCode::UnknownTsBa => ReasonCode::UNKNOWN_TS_BA,
5608
5609 crate::natural::ReasonCode::Timeout => ReasonCode::TIMEOUT,
5610
5611 crate::natural::ReasonCode::PeerkeyMismatch => ReasonCode::PEERKEY_MISMATCH,
5612
5613 crate::natural::ReasonCode::PeerInitiated => ReasonCode::PEER_INITIATED,
5614
5615 crate::natural::ReasonCode::ApInitiated => ReasonCode::AP_INITIATED,
5616
5617 crate::natural::ReasonCode::ReasonInvalidFtActionFrameCount => {
5618 ReasonCode::REASON_INVALID_FT_ACTION_FRAME_COUNT
5619 }
5620
5621 crate::natural::ReasonCode::ReasonInvalidPmkid => ReasonCode::REASON_INVALID_PMKID,
5622
5623 crate::natural::ReasonCode::ReasonInvalidMde => ReasonCode::REASON_INVALID_MDE,
5624
5625 crate::natural::ReasonCode::ReasonInvalidFte => ReasonCode::REASON_INVALID_FTE,
5626
5627 crate::natural::ReasonCode::MeshPeeringCanceled => {
5628 ReasonCode::MESH_PEERING_CANCELED
5629 }
5630
5631 crate::natural::ReasonCode::MeshMaxPeers => ReasonCode::MESH_MAX_PEERS,
5632
5633 crate::natural::ReasonCode::MeshConfigurationPolicyViolation => {
5634 ReasonCode::MESH_CONFIGURATION_POLICY_VIOLATION
5635 }
5636
5637 crate::natural::ReasonCode::MeshCloseRcvd => ReasonCode::MESH_CLOSE_RCVD,
5638
5639 crate::natural::ReasonCode::MeshMaxRetries => ReasonCode::MESH_MAX_RETRIES,
5640
5641 crate::natural::ReasonCode::MeshConfirmTimeout => ReasonCode::MESH_CONFIRM_TIMEOUT,
5642
5643 crate::natural::ReasonCode::MeshInvalidGtk => ReasonCode::MESH_INVALID_GTK,
5644
5645 crate::natural::ReasonCode::MeshInconsistentParameters => {
5646 ReasonCode::MESH_INCONSISTENT_PARAMETERS
5647 }
5648
5649 crate::natural::ReasonCode::MeshInvalidSecurityCapability => {
5650 ReasonCode::MESH_INVALID_SECURITY_CAPABILITY
5651 }
5652
5653 crate::natural::ReasonCode::MeshPathErrorNoProxyInformation => {
5654 ReasonCode::MESH_PATH_ERROR_NO_PROXY_INFORMATION
5655 }
5656
5657 crate::natural::ReasonCode::MeshPathErrorNoForwardingInformation => {
5658 ReasonCode::MESH_PATH_ERROR_NO_FORWARDING_INFORMATION
5659 }
5660
5661 crate::natural::ReasonCode::MeshPathErrorDestinationUnreachable => {
5662 ReasonCode::MESH_PATH_ERROR_DESTINATION_UNREACHABLE
5663 }
5664
5665 crate::natural::ReasonCode::MacAddressAlreadyExistsInMbss => {
5666 ReasonCode::MAC_ADDRESS_ALREADY_EXISTS_IN_MBSS
5667 }
5668
5669 crate::natural::ReasonCode::MeshChannelSwitchRegulatoryRequirements => {
5670 ReasonCode::MESH_CHANNEL_SWITCH_REGULATORY_REQUIREMENTS
5671 }
5672
5673 crate::natural::ReasonCode::MeshChannelSwitchUnspecified => {
5674 ReasonCode::MESH_CHANNEL_SWITCH_UNSPECIFIED
5675 }
5676
5677 crate::natural::ReasonCode::MlmeLinkFailed => ReasonCode::MLME_LINK_FAILED,
5678
5679 crate::natural::ReasonCode::FwRxStalled => ReasonCode::FW_RX_STALLED,
5680
5681 crate::natural::ReasonCode::FwHighWmeRxErrRate => {
5682 ReasonCode::FW_HIGH_WME_RX_ERR_RATE
5683 }
5684
5685 crate::natural::ReasonCode::UnknownOrdinal_(value) => {
5686 ReasonCode { value: ::fidl_next::wire::Uint16::from(value) }
5687 }
5688 }
5689 }
5690 }
5691
5692 impl ::fidl_next::IntoNatural for ReasonCode {
5693 type Natural = crate::natural::ReasonCode;
5694 }
5695
5696 #[repr(C)]
5698 pub struct SetKeyDescriptor<'de> {
5699 pub(crate) table: ::fidl_next::wire::Table<'de>,
5700 }
5701
5702 impl<'de> Drop for SetKeyDescriptor<'de> {
5703 fn drop(&mut self) {
5704 let _ = self.table.get(1).map(|envelope| unsafe {
5705 envelope.read_unchecked::<::fidl_next::wire::Vector<'de, u8>>()
5706 });
5707
5708 let _ = self
5709 .table
5710 .get(2)
5711 .map(|envelope| unsafe { envelope.read_unchecked::<::fidl_next::wire::Uint16>() });
5712
5713 let _ = self
5714 .table
5715 .get(3)
5716 .map(|envelope| unsafe { envelope.read_unchecked::<crate::wire::KeyType>() });
5717
5718 let _ =
5719 self.table.get(4).map(|envelope| unsafe { envelope.read_unchecked::<[u8; 6]>() });
5720
5721 let _ = self
5722 .table
5723 .get(5)
5724 .map(|envelope| unsafe { envelope.read_unchecked::<::fidl_next::wire::Uint64>() });
5725
5726 let _ =
5727 self.table.get(6).map(|envelope| unsafe { envelope.read_unchecked::<[u8; 3]>() });
5728
5729 let _ = self.table.get(7).map(|envelope| unsafe {
5730 envelope.read_unchecked::<crate::wire::CipherSuiteType>()
5731 });
5732 }
5733 }
5734
5735 impl ::fidl_next::Constrained for SetKeyDescriptor<'_> {
5736 type Constraint = ();
5737
5738 fn validate(
5739 _: ::fidl_next::Slot<'_, Self>,
5740 _: Self::Constraint,
5741 ) -> Result<(), ::fidl_next::ValidationError> {
5742 Ok(())
5743 }
5744 }
5745
5746 unsafe impl ::fidl_next::Wire for SetKeyDescriptor<'static> {
5747 type Narrowed<'de> = SetKeyDescriptor<'de>;
5748
5749 #[inline]
5750 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
5751 ::fidl_next::munge!(let Self { table } = out);
5752 ::fidl_next::wire::Table::zero_padding(table);
5753 }
5754 }
5755
5756 unsafe impl<'de, ___D> ::fidl_next::Decode<___D> for SetKeyDescriptor<'de>
5757 where
5758 ___D: ::fidl_next::Decoder<'de> + ?Sized,
5759 {
5760 fn decode(
5761 slot: ::fidl_next::Slot<'_, Self>,
5762 decoder: &mut ___D,
5763 _: (),
5764 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
5765 ::fidl_next::munge!(let Self { table } = slot);
5766
5767 ::fidl_next::wire::Table::decode_with(table, decoder, |ordinal, mut slot, decoder| {
5768 match ordinal {
5769 0 => unsafe { ::core::hint::unreachable_unchecked() },
5770
5771 1 => {
5772 ::fidl_next::wire::Envelope::decode_as::<
5773 ___D,
5774 ::fidl_next::wire::Vector<'de, u8>,
5775 >(slot.as_mut(), decoder, (32, ()))?;
5776
5777 let value = unsafe {
5778 slot.deref_unchecked()
5779 .deref_unchecked::<::fidl_next::wire::Vector<'_, u8>>()
5780 };
5781
5782 if value.len() > 32 {
5783 return Err(::fidl_next::DecodeError::VectorTooLong {
5784 size: value.len() as u64,
5785 limit: 32,
5786 });
5787 }
5788
5789 Ok(())
5790 }
5791
5792 2 => {
5793 ::fidl_next::wire::Envelope::decode_as::<___D, ::fidl_next::wire::Uint16>(
5794 slot.as_mut(),
5795 decoder,
5796 (),
5797 )?;
5798
5799 Ok(())
5800 }
5801
5802 3 => {
5803 ::fidl_next::wire::Envelope::decode_as::<___D, crate::wire::KeyType>(
5804 slot.as_mut(),
5805 decoder,
5806 (),
5807 )?;
5808
5809 Ok(())
5810 }
5811
5812 4 => {
5813 ::fidl_next::wire::Envelope::decode_as::<___D, [u8; 6]>(
5814 slot.as_mut(),
5815 decoder,
5816 (),
5817 )?;
5818
5819 Ok(())
5820 }
5821
5822 5 => {
5823 ::fidl_next::wire::Envelope::decode_as::<___D, ::fidl_next::wire::Uint64>(
5824 slot.as_mut(),
5825 decoder,
5826 (),
5827 )?;
5828
5829 Ok(())
5830 }
5831
5832 6 => {
5833 ::fidl_next::wire::Envelope::decode_as::<___D, [u8; 3]>(
5834 slot.as_mut(),
5835 decoder,
5836 (),
5837 )?;
5838
5839 Ok(())
5840 }
5841
5842 7 => {
5843 ::fidl_next::wire::Envelope::decode_as::<___D, crate::wire::CipherSuiteType>(
5844 slot.as_mut(),
5845 decoder,
5846 (),
5847 )?;
5848
5849 Ok(())
5850 }
5851
5852 _ => ::fidl_next::wire::Envelope::decode_unknown(slot, decoder),
5853 }
5854 })
5855 }
5856 }
5857
5858 impl<'de> SetKeyDescriptor<'de> {
5859 pub fn key(&self) -> ::core::option::Option<&::fidl_next::wire::Vector<'de, u8>> {
5860 unsafe { Some(self.table.get(1)?.deref_unchecked()) }
5861 }
5862
5863 pub fn take_key(&mut self) -> ::core::option::Option<::fidl_next::wire::Vector<'de, u8>> {
5864 unsafe { Some(self.table.get_mut(1)?.take_unchecked()) }
5865 }
5866
5867 pub fn key_id(&self) -> ::core::option::Option<&::fidl_next::wire::Uint16> {
5868 unsafe { Some(self.table.get(2)?.deref_unchecked()) }
5869 }
5870
5871 pub fn take_key_id(&mut self) -> ::core::option::Option<::fidl_next::wire::Uint16> {
5872 unsafe { Some(self.table.get_mut(2)?.take_unchecked()) }
5873 }
5874
5875 pub fn key_type(&self) -> ::core::option::Option<&crate::wire::KeyType> {
5876 unsafe { Some(self.table.get(3)?.deref_unchecked()) }
5877 }
5878
5879 pub fn take_key_type(&mut self) -> ::core::option::Option<crate::wire::KeyType> {
5880 unsafe { Some(self.table.get_mut(3)?.take_unchecked()) }
5881 }
5882
5883 pub fn peer_addr(&self) -> ::core::option::Option<&[u8; 6]> {
5884 unsafe { Some(self.table.get(4)?.deref_unchecked()) }
5885 }
5886
5887 pub fn take_peer_addr(&mut self) -> ::core::option::Option<[u8; 6]> {
5888 unsafe { Some(self.table.get_mut(4)?.take_unchecked()) }
5889 }
5890
5891 pub fn rsc(&self) -> ::core::option::Option<&::fidl_next::wire::Uint64> {
5892 unsafe { Some(self.table.get(5)?.deref_unchecked()) }
5893 }
5894
5895 pub fn take_rsc(&mut self) -> ::core::option::Option<::fidl_next::wire::Uint64> {
5896 unsafe { Some(self.table.get_mut(5)?.take_unchecked()) }
5897 }
5898
5899 pub fn cipher_oui(&self) -> ::core::option::Option<&[u8; 3]> {
5900 unsafe { Some(self.table.get(6)?.deref_unchecked()) }
5901 }
5902
5903 pub fn take_cipher_oui(&mut self) -> ::core::option::Option<[u8; 3]> {
5904 unsafe { Some(self.table.get_mut(6)?.take_unchecked()) }
5905 }
5906
5907 pub fn cipher_type(&self) -> ::core::option::Option<&crate::wire::CipherSuiteType> {
5908 unsafe { Some(self.table.get(7)?.deref_unchecked()) }
5909 }
5910
5911 pub fn take_cipher_type(&mut self) -> ::core::option::Option<crate::wire::CipherSuiteType> {
5912 unsafe { Some(self.table.get_mut(7)?.take_unchecked()) }
5913 }
5914 }
5915
5916 impl<'de> ::core::fmt::Debug for SetKeyDescriptor<'de> {
5917 fn fmt(
5918 &self,
5919 f: &mut ::core::fmt::Formatter<'_>,
5920 ) -> ::core::result::Result<(), ::core::fmt::Error> {
5921 f.debug_struct("SetKeyDescriptor")
5922 .field("key", &self.key())
5923 .field("key_id", &self.key_id())
5924 .field("key_type", &self.key_type())
5925 .field("peer_addr", &self.peer_addr())
5926 .field("rsc", &self.rsc())
5927 .field("cipher_oui", &self.cipher_oui())
5928 .field("cipher_type", &self.cipher_type())
5929 .finish()
5930 }
5931 }
5932
5933 impl<'de> ::fidl_next::IntoNatural for SetKeyDescriptor<'de> {
5934 type Natural = crate::natural::SetKeyDescriptor;
5935 }
5936
5937 pub type Ssid<'de> = ::fidl_next::wire::Vector<'de, u8>;
5939
5940 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
5942 #[repr(transparent)]
5943 pub struct StatusCode {
5944 pub(crate) value: ::fidl_next::wire::Uint16,
5945 }
5946
5947 impl ::fidl_next::Constrained for StatusCode {
5948 type Constraint = ();
5949
5950 fn validate(
5951 _: ::fidl_next::Slot<'_, Self>,
5952 _: Self::Constraint,
5953 ) -> Result<(), ::fidl_next::ValidationError> {
5954 Ok(())
5955 }
5956 }
5957
5958 unsafe impl ::fidl_next::Wire for StatusCode {
5959 type Narrowed<'de> = Self;
5960
5961 #[inline]
5962 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
5963 }
5965 }
5966
5967 impl StatusCode {
5968 pub const SUCCESS: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(0) };
5969
5970 pub const REFUSED_REASON_UNSPECIFIED: StatusCode =
5971 StatusCode { value: ::fidl_next::wire::Uint16(1) };
5972
5973 pub const TDLS_REJECTED_ALTERNATIVE_PROVIDED: StatusCode =
5974 StatusCode { value: ::fidl_next::wire::Uint16(2) };
5975
5976 pub const TDLS_REJECTED: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(3) };
5977
5978 pub const SECURITY_DISABLED: StatusCode =
5979 StatusCode { value: ::fidl_next::wire::Uint16(5) };
5980
5981 pub const UNACCEPTABLE_LIFETIME: StatusCode =
5982 StatusCode { value: ::fidl_next::wire::Uint16(6) };
5983
5984 pub const NOT_IN_SAME_BSS: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(7) };
5985
5986 pub const REFUSED_CAPABILITIES_MISMATCH: StatusCode =
5987 StatusCode { value: ::fidl_next::wire::Uint16(10) };
5988
5989 pub const DENIED_NO_ASSOCIATION_EXISTS: StatusCode =
5990 StatusCode { value: ::fidl_next::wire::Uint16(11) };
5991
5992 pub const DENIED_OTHER_REASON: StatusCode =
5993 StatusCode { value: ::fidl_next::wire::Uint16(12) };
5994
5995 pub const UNSUPPORTED_AUTH_ALGORITHM: StatusCode =
5996 StatusCode { value: ::fidl_next::wire::Uint16(13) };
5997
5998 pub const TRANSACTION_SEQUENCE_ERROR: StatusCode =
5999 StatusCode { value: ::fidl_next::wire::Uint16(14) };
6000
6001 pub const CHALLENGE_FAILURE: StatusCode =
6002 StatusCode { value: ::fidl_next::wire::Uint16(15) };
6003
6004 pub const REJECTED_SEQUENCE_TIMEOUT: StatusCode =
6005 StatusCode { value: ::fidl_next::wire::Uint16(16) };
6006
6007 pub const DENIED_NO_MORE_STAS: StatusCode =
6008 StatusCode { value: ::fidl_next::wire::Uint16(17) };
6009
6010 pub const REFUSED_BASIC_RATES_MISMATCH: StatusCode =
6011 StatusCode { value: ::fidl_next::wire::Uint16(18) };
6012
6013 pub const DENIED_NO_SHORT_PREAMBLE_SUPPORT: StatusCode =
6014 StatusCode { value: ::fidl_next::wire::Uint16(19) };
6015
6016 pub const REJECTED_SPECTRUM_MANAGEMENT_REQUIRED: StatusCode =
6017 StatusCode { value: ::fidl_next::wire::Uint16(22) };
6018
6019 pub const REJECTED_BAD_POWER_CAPABILITY: StatusCode =
6020 StatusCode { value: ::fidl_next::wire::Uint16(23) };
6021
6022 pub const REJECTED_BAD_SUPPORTED_CHANNELS: StatusCode =
6023 StatusCode { value: ::fidl_next::wire::Uint16(24) };
6024
6025 pub const DENIED_NO_SHORT_SLOT_TIME_SUPPORT: StatusCode =
6026 StatusCode { value: ::fidl_next::wire::Uint16(25) };
6027
6028 pub const DENIED_NO_HT_SUPPORT: StatusCode =
6029 StatusCode { value: ::fidl_next::wire::Uint16(27) };
6030
6031 pub const R0_KH_UNREACHABLE: StatusCode =
6032 StatusCode { value: ::fidl_next::wire::Uint16(28) };
6033
6034 pub const DENIED_PCO_TIME_NOT_SUPPORTED: StatusCode =
6035 StatusCode { value: ::fidl_next::wire::Uint16(29) };
6036
6037 pub const REFUSED_TEMPORARILY: StatusCode =
6038 StatusCode { value: ::fidl_next::wire::Uint16(30) };
6039
6040 pub const ROBUST_MANAGEMENT_POLICY_VIOLATION: StatusCode =
6041 StatusCode { value: ::fidl_next::wire::Uint16(31) };
6042
6043 pub const UNSPECIFIED_QOS_FAILURE: StatusCode =
6044 StatusCode { value: ::fidl_next::wire::Uint16(32) };
6045
6046 pub const DENIED_INSUFFICIENT_BANDWIDTH: StatusCode =
6047 StatusCode { value: ::fidl_next::wire::Uint16(33) };
6048
6049 pub const DENIED_POOR_CHANNEL_CONDITIONS: StatusCode =
6050 StatusCode { value: ::fidl_next::wire::Uint16(34) };
6051
6052 pub const DENIED_QOS_NOT_SUPPORTED: StatusCode =
6053 StatusCode { value: ::fidl_next::wire::Uint16(35) };
6054
6055 pub const REQUEST_DECLINED: StatusCode =
6056 StatusCode { value: ::fidl_next::wire::Uint16(37) };
6057
6058 pub const INVALID_PARAMETERS: StatusCode =
6059 StatusCode { value: ::fidl_next::wire::Uint16(38) };
6060
6061 pub const REJECTED_WITH_SUGGESTED_CHANGES: StatusCode =
6062 StatusCode { value: ::fidl_next::wire::Uint16(39) };
6063
6064 pub const STATUS_INVALID_ELEMENT: StatusCode =
6065 StatusCode { value: ::fidl_next::wire::Uint16(40) };
6066
6067 pub const STATUS_INVALID_GROUP_CIPHER: StatusCode =
6068 StatusCode { value: ::fidl_next::wire::Uint16(41) };
6069
6070 pub const STATUS_INVALID_PAIRWISE_CIPHER: StatusCode =
6071 StatusCode { value: ::fidl_next::wire::Uint16(42) };
6072
6073 pub const STATUS_INVALID_AKMP: StatusCode =
6074 StatusCode { value: ::fidl_next::wire::Uint16(43) };
6075
6076 pub const UNSUPPORTED_RSNE_VERSION: StatusCode =
6077 StatusCode { value: ::fidl_next::wire::Uint16(44) };
6078
6079 pub const INVALID_RSNE_CAPABILITIES: StatusCode =
6080 StatusCode { value: ::fidl_next::wire::Uint16(45) };
6081
6082 pub const STATUS_CIPHER_OUT_OF_POLICY: StatusCode =
6083 StatusCode { value: ::fidl_next::wire::Uint16(46) };
6084
6085 pub const REJECTED_FOR_DELAY_PERIOD: StatusCode =
6086 StatusCode { value: ::fidl_next::wire::Uint16(47) };
6087
6088 pub const DLS_NOT_ALLOWED: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(48) };
6089
6090 pub const NOT_PRESENT: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(49) };
6091
6092 pub const NOT_QOS_STA: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(50) };
6093
6094 pub const DENIED_LISTEN_INTERVAL_TOO_LARGE: StatusCode =
6095 StatusCode { value: ::fidl_next::wire::Uint16(51) };
6096
6097 pub const STATUS_INVALID_FT_ACTION_FRAME_COUNT: StatusCode =
6098 StatusCode { value: ::fidl_next::wire::Uint16(52) };
6099
6100 pub const STATUS_INVALID_PMKID: StatusCode =
6101 StatusCode { value: ::fidl_next::wire::Uint16(53) };
6102
6103 pub const STATUS_INVALID_MDE: StatusCode =
6104 StatusCode { value: ::fidl_next::wire::Uint16(54) };
6105
6106 pub const STATUS_INVALID_FTE: StatusCode =
6107 StatusCode { value: ::fidl_next::wire::Uint16(55) };
6108
6109 pub const REQUESTED_TCLAS_NOT_SUPPORTED_BY_AP: StatusCode =
6110 StatusCode { value: ::fidl_next::wire::Uint16(56) };
6111
6112 pub const INSUFFICIENT_TCLAS_PROCESSING_RESOURCES: StatusCode =
6113 StatusCode { value: ::fidl_next::wire::Uint16(57) };
6114
6115 pub const TRY_ANOTHER_BSS: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(58) };
6116
6117 pub const GAS_ADVERTISEMENT_PROTOCOL_NOT_SUPPORTED: StatusCode =
6118 StatusCode { value: ::fidl_next::wire::Uint16(59) };
6119
6120 pub const NO_OUTSTANDING_GAS_REQUEST: StatusCode =
6121 StatusCode { value: ::fidl_next::wire::Uint16(60) };
6122
6123 pub const GAS_RESPONSE_NOT_RECEIVED_FROM_SERVER: StatusCode =
6124 StatusCode { value: ::fidl_next::wire::Uint16(61) };
6125
6126 pub const GAS_QUERY_TIMEOUT: StatusCode =
6127 StatusCode { value: ::fidl_next::wire::Uint16(62) };
6128
6129 pub const GAS_QUERY_RESPONSE_TOO_LARGE: StatusCode =
6130 StatusCode { value: ::fidl_next::wire::Uint16(63) };
6131
6132 pub const REJECTED_HOME_WITH_SUGGESTED_CHANGES: StatusCode =
6133 StatusCode { value: ::fidl_next::wire::Uint16(64) };
6134
6135 pub const SERVER_UNREACHABLE: StatusCode =
6136 StatusCode { value: ::fidl_next::wire::Uint16(65) };
6137
6138 pub const REJECTED_FOR_SSP_PERMISSIONS: StatusCode =
6139 StatusCode { value: ::fidl_next::wire::Uint16(67) };
6140
6141 pub const REFUSED_UNAUTHENTICATED_ACCESS_NOT_SUPPORTED: StatusCode =
6142 StatusCode { value: ::fidl_next::wire::Uint16(68) };
6143
6144 pub const INVALID_RSNE: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(72) };
6145
6146 pub const U_APSD_COEXISTANCE_NOT_SUPPORTED: StatusCode =
6147 StatusCode { value: ::fidl_next::wire::Uint16(73) };
6148
6149 pub const U_APSD_COEX_MODE_NOT_SUPPORTED: StatusCode =
6150 StatusCode { value: ::fidl_next::wire::Uint16(74) };
6151
6152 pub const BAD_INTERVAL_WITH_U_APSD_COEX: StatusCode =
6153 StatusCode { value: ::fidl_next::wire::Uint16(75) };
6154
6155 pub const ANTI_CLOGGING_TOKEN_REQUIRED: StatusCode =
6156 StatusCode { value: ::fidl_next::wire::Uint16(76) };
6157
6158 pub const UNSUPPORTED_FINITE_CYCLIC_GROUP: StatusCode =
6159 StatusCode { value: ::fidl_next::wire::Uint16(77) };
6160
6161 pub const CANNOT_FIND_ALTERNATIVE_TBTT: StatusCode =
6162 StatusCode { value: ::fidl_next::wire::Uint16(78) };
6163
6164 pub const TRANSMISSION_FAILURE: StatusCode =
6165 StatusCode { value: ::fidl_next::wire::Uint16(79) };
6166
6167 pub const REQUESTED_TCLAS_NOT_SUPPORTED: StatusCode =
6168 StatusCode { value: ::fidl_next::wire::Uint16(80) };
6169
6170 pub const TCLAS_RESOURCES_EXHAUSTED: StatusCode =
6171 StatusCode { value: ::fidl_next::wire::Uint16(81) };
6172
6173 pub const REJECTED_WITH_SUGGESTED_BSS_TRANSITION: StatusCode =
6174 StatusCode { value: ::fidl_next::wire::Uint16(82) };
6175
6176 pub const REJECT_WITH_SCHEDULE: StatusCode =
6177 StatusCode { value: ::fidl_next::wire::Uint16(83) };
6178
6179 pub const REJECT_NO_WAKEUP_SPECIFIED: StatusCode =
6180 StatusCode { value: ::fidl_next::wire::Uint16(84) };
6181
6182 pub const SUCCESS_POWER_SAVE_MODE: StatusCode =
6183 StatusCode { value: ::fidl_next::wire::Uint16(85) };
6184
6185 pub const PENDING_ADMITTING_FST_SESSION: StatusCode =
6186 StatusCode { value: ::fidl_next::wire::Uint16(86) };
6187
6188 pub const PERFORMING_FST_NOW: StatusCode =
6189 StatusCode { value: ::fidl_next::wire::Uint16(87) };
6190
6191 pub const PENDING_GAP_IN_BA_WINDOW: StatusCode =
6192 StatusCode { value: ::fidl_next::wire::Uint16(88) };
6193
6194 pub const REJECT_U_PID_SETTING: StatusCode =
6195 StatusCode { value: ::fidl_next::wire::Uint16(89) };
6196
6197 pub const REFUSED_EXTERNAL_REASON: StatusCode =
6198 StatusCode { value: ::fidl_next::wire::Uint16(92) };
6199
6200 pub const REFUSED_AP_OUT_OF_MEMORY: StatusCode =
6201 StatusCode { value: ::fidl_next::wire::Uint16(93) };
6202
6203 pub const REJECTED_EMERGENCY_SERVICES_NOT_SUPPORTED: StatusCode =
6204 StatusCode { value: ::fidl_next::wire::Uint16(94) };
6205
6206 pub const QUERY_RESPONSE_OUTSTANDING: StatusCode =
6207 StatusCode { value: ::fidl_next::wire::Uint16(95) };
6208
6209 pub const REJECT_DSE_BAND: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(96) };
6210
6211 pub const TCLAS_PROCESSING_TERMINATED: StatusCode =
6212 StatusCode { value: ::fidl_next::wire::Uint16(97) };
6213
6214 pub const TS_SCHEDULE_CONFLICT: StatusCode =
6215 StatusCode { value: ::fidl_next::wire::Uint16(98) };
6216
6217 pub const DENIED_WITH_SUGGESTED_BAND_AND_CHANNEL: StatusCode =
6218 StatusCode { value: ::fidl_next::wire::Uint16(99) };
6219
6220 pub const MCCAOP_RESERVATION_CONFLICT: StatusCode =
6221 StatusCode { value: ::fidl_next::wire::Uint16(100) };
6222
6223 pub const MAF_LIMIT_EXCEEDED: StatusCode =
6224 StatusCode { value: ::fidl_next::wire::Uint16(101) };
6225
6226 pub const MCCA_TRACK_LIMIT_EXCEEDED: StatusCode =
6227 StatusCode { value: ::fidl_next::wire::Uint16(102) };
6228
6229 pub const DENIED_DUE_TO_SPECTRUM_MANAGEMENT: StatusCode =
6230 StatusCode { value: ::fidl_next::wire::Uint16(103) };
6231
6232 pub const DENIED_VHT_NOT_SUPPORTED: StatusCode =
6233 StatusCode { value: ::fidl_next::wire::Uint16(104) };
6234
6235 pub const ENABLEMENT_DENIED: StatusCode =
6236 StatusCode { value: ::fidl_next::wire::Uint16(105) };
6237
6238 pub const RESTRICTION_FROM_AUTHORIZED_GDB: StatusCode =
6239 StatusCode { value: ::fidl_next::wire::Uint16(106) };
6240
6241 pub const AUTHORIZATION_DEENABLED: StatusCode =
6242 StatusCode { value: ::fidl_next::wire::Uint16(107) };
6243
6244 pub const ENERGY_LIMITED_OPERATION_NOT_SUPPORTED: StatusCode =
6245 StatusCode { value: ::fidl_next::wire::Uint16(108) };
6246
6247 pub const REJECTED_NDP_BLOCK_ACK_SUGGESTED: StatusCode =
6248 StatusCode { value: ::fidl_next::wire::Uint16(109) };
6249
6250 pub const REJECTED_MAX_AWAY_DURATION_UNACCEPTABLE: StatusCode =
6251 StatusCode { value: ::fidl_next::wire::Uint16(110) };
6252
6253 pub const FLOW_CONTROL_OPERATION_SUPPORTED: StatusCode =
6254 StatusCode { value: ::fidl_next::wire::Uint16(111) };
6255
6256 pub const FILS_AUTHENTICATION_FAILURE: StatusCode =
6257 StatusCode { value: ::fidl_next::wire::Uint16(112) };
6258
6259 pub const UNKNOWN_AUTHENTICATION_SERVER: StatusCode =
6260 StatusCode { value: ::fidl_next::wire::Uint16(113) };
6261
6262 pub const DENIED_NOTIFICATION_PERIOD_ALLOCATION: StatusCode =
6263 StatusCode { value: ::fidl_next::wire::Uint16(116) };
6264
6265 pub const DENIED_CHANNEL_SPLITTING: StatusCode =
6266 StatusCode { value: ::fidl_next::wire::Uint16(117) };
6267
6268 pub const DENIED_ALLOCATION: StatusCode =
6269 StatusCode { value: ::fidl_next::wire::Uint16(118) };
6270
6271 pub const CMMG_FEATURES_NOT_SUPPORTED: StatusCode =
6272 StatusCode { value: ::fidl_next::wire::Uint16(119) };
6273
6274 pub const GAS_FRAGMENT_NOT_AVAILABLE: StatusCode =
6275 StatusCode { value: ::fidl_next::wire::Uint16(120) };
6276
6277 pub const SUCCESS_CAG_VERSIONS_MATCH: StatusCode =
6278 StatusCode { value: ::fidl_next::wire::Uint16(121) };
6279
6280 pub const GLK_NOT_AUTHORIZED: StatusCode =
6281 StatusCode { value: ::fidl_next::wire::Uint16(122) };
6282
6283 pub const UNKNOWN_PASSWORD_IDENTIFIER: StatusCode =
6284 StatusCode { value: ::fidl_next::wire::Uint16(123) };
6285
6286 pub const DENIED_LOCAL_MAC_ADDRESS_POLICY_VIOLATION: StatusCode =
6287 StatusCode { value: ::fidl_next::wire::Uint16(125) };
6288
6289 pub const SAE_HASH_TO_ELEMENT: StatusCode =
6290 StatusCode { value: ::fidl_next::wire::Uint16(126) };
6291
6292 pub const TCLAS_PROCESSING_TERMINATED_INSUFFICIENT_QOS: StatusCode =
6293 StatusCode { value: ::fidl_next::wire::Uint16(128) };
6294
6295 pub const TCLAS_PROCESSING_TERMINATED_POLICY_CONFLICT: StatusCode =
6296 StatusCode { value: ::fidl_next::wire::Uint16(129) };
6297
6298 pub const JOIN_FAILURE: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(256) };
6299
6300 pub const SPURIOUS_DEAUTH_OR_DISASSOC: StatusCode =
6301 StatusCode { value: ::fidl_next::wire::Uint16(257) };
6302
6303 pub const CANCELED: StatusCode = StatusCode { value: ::fidl_next::wire::Uint16(258) };
6304
6305 pub const ESTABLISH_RSNA_FAILURE: StatusCode =
6306 StatusCode { value: ::fidl_next::wire::Uint16(259) };
6307
6308 pub const OWE_HANDSHAKE_FAILURE: StatusCode =
6309 StatusCode { value: ::fidl_next::wire::Uint16(260) };
6310
6311 pub const NO_ACK_FROM_PEER: StatusCode =
6312 StatusCode { value: ::fidl_next::wire::Uint16(261) };
6313
6314 pub const RESPONSE_TIMEOUT: StatusCode =
6315 StatusCode { value: ::fidl_next::wire::Uint16(262) };
6316
6317 pub const UNEXPECTED_RESPONSE: StatusCode =
6318 StatusCode { value: ::fidl_next::wire::Uint16(263) };
6319
6320 pub const INTERNAL_FAILURE: StatusCode =
6321 StatusCode { value: ::fidl_next::wire::Uint16(264) };
6322 }
6323
6324 unsafe impl<___D> ::fidl_next::Decode<___D> for StatusCode
6325 where
6326 ___D: ?Sized,
6327 {
6328 fn decode(
6329 slot: ::fidl_next::Slot<'_, Self>,
6330 _: &mut ___D,
6331 _: (),
6332 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
6333 Ok(())
6334 }
6335 }
6336
6337 impl ::core::convert::From<crate::natural::StatusCode> for StatusCode {
6338 fn from(natural: crate::natural::StatusCode) -> Self {
6339 match natural {
6340 crate::natural::StatusCode::Success => StatusCode::SUCCESS,
6341
6342 crate::natural::StatusCode::RefusedReasonUnspecified => {
6343 StatusCode::REFUSED_REASON_UNSPECIFIED
6344 }
6345
6346 crate::natural::StatusCode::TdlsRejectedAlternativeProvided => {
6347 StatusCode::TDLS_REJECTED_ALTERNATIVE_PROVIDED
6348 }
6349
6350 crate::natural::StatusCode::TdlsRejected => StatusCode::TDLS_REJECTED,
6351
6352 crate::natural::StatusCode::SecurityDisabled => StatusCode::SECURITY_DISABLED,
6353
6354 crate::natural::StatusCode::UnacceptableLifetime => {
6355 StatusCode::UNACCEPTABLE_LIFETIME
6356 }
6357
6358 crate::natural::StatusCode::NotInSameBss => StatusCode::NOT_IN_SAME_BSS,
6359
6360 crate::natural::StatusCode::RefusedCapabilitiesMismatch => {
6361 StatusCode::REFUSED_CAPABILITIES_MISMATCH
6362 }
6363
6364 crate::natural::StatusCode::DeniedNoAssociationExists => {
6365 StatusCode::DENIED_NO_ASSOCIATION_EXISTS
6366 }
6367
6368 crate::natural::StatusCode::DeniedOtherReason => StatusCode::DENIED_OTHER_REASON,
6369
6370 crate::natural::StatusCode::UnsupportedAuthAlgorithm => {
6371 StatusCode::UNSUPPORTED_AUTH_ALGORITHM
6372 }
6373
6374 crate::natural::StatusCode::TransactionSequenceError => {
6375 StatusCode::TRANSACTION_SEQUENCE_ERROR
6376 }
6377
6378 crate::natural::StatusCode::ChallengeFailure => StatusCode::CHALLENGE_FAILURE,
6379
6380 crate::natural::StatusCode::RejectedSequenceTimeout => {
6381 StatusCode::REJECTED_SEQUENCE_TIMEOUT
6382 }
6383
6384 crate::natural::StatusCode::DeniedNoMoreStas => StatusCode::DENIED_NO_MORE_STAS,
6385
6386 crate::natural::StatusCode::RefusedBasicRatesMismatch => {
6387 StatusCode::REFUSED_BASIC_RATES_MISMATCH
6388 }
6389
6390 crate::natural::StatusCode::DeniedNoShortPreambleSupport => {
6391 StatusCode::DENIED_NO_SHORT_PREAMBLE_SUPPORT
6392 }
6393
6394 crate::natural::StatusCode::RejectedSpectrumManagementRequired => {
6395 StatusCode::REJECTED_SPECTRUM_MANAGEMENT_REQUIRED
6396 }
6397
6398 crate::natural::StatusCode::RejectedBadPowerCapability => {
6399 StatusCode::REJECTED_BAD_POWER_CAPABILITY
6400 }
6401
6402 crate::natural::StatusCode::RejectedBadSupportedChannels => {
6403 StatusCode::REJECTED_BAD_SUPPORTED_CHANNELS
6404 }
6405
6406 crate::natural::StatusCode::DeniedNoShortSlotTimeSupport => {
6407 StatusCode::DENIED_NO_SHORT_SLOT_TIME_SUPPORT
6408 }
6409
6410 crate::natural::StatusCode::DeniedNoHtSupport => StatusCode::DENIED_NO_HT_SUPPORT,
6411
6412 crate::natural::StatusCode::R0KhUnreachable => StatusCode::R0_KH_UNREACHABLE,
6413
6414 crate::natural::StatusCode::DeniedPcoTimeNotSupported => {
6415 StatusCode::DENIED_PCO_TIME_NOT_SUPPORTED
6416 }
6417
6418 crate::natural::StatusCode::RefusedTemporarily => StatusCode::REFUSED_TEMPORARILY,
6419
6420 crate::natural::StatusCode::RobustManagementPolicyViolation => {
6421 StatusCode::ROBUST_MANAGEMENT_POLICY_VIOLATION
6422 }
6423
6424 crate::natural::StatusCode::UnspecifiedQosFailure => {
6425 StatusCode::UNSPECIFIED_QOS_FAILURE
6426 }
6427
6428 crate::natural::StatusCode::DeniedInsufficientBandwidth => {
6429 StatusCode::DENIED_INSUFFICIENT_BANDWIDTH
6430 }
6431
6432 crate::natural::StatusCode::DeniedPoorChannelConditions => {
6433 StatusCode::DENIED_POOR_CHANNEL_CONDITIONS
6434 }
6435
6436 crate::natural::StatusCode::DeniedQosNotSupported => {
6437 StatusCode::DENIED_QOS_NOT_SUPPORTED
6438 }
6439
6440 crate::natural::StatusCode::RequestDeclined => StatusCode::REQUEST_DECLINED,
6441
6442 crate::natural::StatusCode::InvalidParameters => StatusCode::INVALID_PARAMETERS,
6443
6444 crate::natural::StatusCode::RejectedWithSuggestedChanges => {
6445 StatusCode::REJECTED_WITH_SUGGESTED_CHANGES
6446 }
6447
6448 crate::natural::StatusCode::StatusInvalidElement => {
6449 StatusCode::STATUS_INVALID_ELEMENT
6450 }
6451
6452 crate::natural::StatusCode::StatusInvalidGroupCipher => {
6453 StatusCode::STATUS_INVALID_GROUP_CIPHER
6454 }
6455
6456 crate::natural::StatusCode::StatusInvalidPairwiseCipher => {
6457 StatusCode::STATUS_INVALID_PAIRWISE_CIPHER
6458 }
6459
6460 crate::natural::StatusCode::StatusInvalidAkmp => StatusCode::STATUS_INVALID_AKMP,
6461
6462 crate::natural::StatusCode::UnsupportedRsneVersion => {
6463 StatusCode::UNSUPPORTED_RSNE_VERSION
6464 }
6465
6466 crate::natural::StatusCode::InvalidRsneCapabilities => {
6467 StatusCode::INVALID_RSNE_CAPABILITIES
6468 }
6469
6470 crate::natural::StatusCode::StatusCipherOutOfPolicy => {
6471 StatusCode::STATUS_CIPHER_OUT_OF_POLICY
6472 }
6473
6474 crate::natural::StatusCode::RejectedForDelayPeriod => {
6475 StatusCode::REJECTED_FOR_DELAY_PERIOD
6476 }
6477
6478 crate::natural::StatusCode::DlsNotAllowed => StatusCode::DLS_NOT_ALLOWED,
6479
6480 crate::natural::StatusCode::NotPresent => StatusCode::NOT_PRESENT,
6481
6482 crate::natural::StatusCode::NotQosSta => StatusCode::NOT_QOS_STA,
6483
6484 crate::natural::StatusCode::DeniedListenIntervalTooLarge => {
6485 StatusCode::DENIED_LISTEN_INTERVAL_TOO_LARGE
6486 }
6487
6488 crate::natural::StatusCode::StatusInvalidFtActionFrameCount => {
6489 StatusCode::STATUS_INVALID_FT_ACTION_FRAME_COUNT
6490 }
6491
6492 crate::natural::StatusCode::StatusInvalidPmkid => StatusCode::STATUS_INVALID_PMKID,
6493
6494 crate::natural::StatusCode::StatusInvalidMde => StatusCode::STATUS_INVALID_MDE,
6495
6496 crate::natural::StatusCode::StatusInvalidFte => StatusCode::STATUS_INVALID_FTE,
6497
6498 crate::natural::StatusCode::RequestedTclasNotSupportedByAp => {
6499 StatusCode::REQUESTED_TCLAS_NOT_SUPPORTED_BY_AP
6500 }
6501
6502 crate::natural::StatusCode::InsufficientTclasProcessingResources => {
6503 StatusCode::INSUFFICIENT_TCLAS_PROCESSING_RESOURCES
6504 }
6505
6506 crate::natural::StatusCode::TryAnotherBss => StatusCode::TRY_ANOTHER_BSS,
6507
6508 crate::natural::StatusCode::GasAdvertisementProtocolNotSupported => {
6509 StatusCode::GAS_ADVERTISEMENT_PROTOCOL_NOT_SUPPORTED
6510 }
6511
6512 crate::natural::StatusCode::NoOutstandingGasRequest => {
6513 StatusCode::NO_OUTSTANDING_GAS_REQUEST
6514 }
6515
6516 crate::natural::StatusCode::GasResponseNotReceivedFromServer => {
6517 StatusCode::GAS_RESPONSE_NOT_RECEIVED_FROM_SERVER
6518 }
6519
6520 crate::natural::StatusCode::GasQueryTimeout => StatusCode::GAS_QUERY_TIMEOUT,
6521
6522 crate::natural::StatusCode::GasQueryResponseTooLarge => {
6523 StatusCode::GAS_QUERY_RESPONSE_TOO_LARGE
6524 }
6525
6526 crate::natural::StatusCode::RejectedHomeWithSuggestedChanges => {
6527 StatusCode::REJECTED_HOME_WITH_SUGGESTED_CHANGES
6528 }
6529
6530 crate::natural::StatusCode::ServerUnreachable => StatusCode::SERVER_UNREACHABLE,
6531
6532 crate::natural::StatusCode::RejectedForSspPermissions => {
6533 StatusCode::REJECTED_FOR_SSP_PERMISSIONS
6534 }
6535
6536 crate::natural::StatusCode::RefusedUnauthenticatedAccessNotSupported => {
6537 StatusCode::REFUSED_UNAUTHENTICATED_ACCESS_NOT_SUPPORTED
6538 }
6539
6540 crate::natural::StatusCode::InvalidRsne => StatusCode::INVALID_RSNE,
6541
6542 crate::natural::StatusCode::UApsdCoexistanceNotSupported => {
6543 StatusCode::U_APSD_COEXISTANCE_NOT_SUPPORTED
6544 }
6545
6546 crate::natural::StatusCode::UApsdCoexModeNotSupported => {
6547 StatusCode::U_APSD_COEX_MODE_NOT_SUPPORTED
6548 }
6549
6550 crate::natural::StatusCode::BadIntervalWithUApsdCoex => {
6551 StatusCode::BAD_INTERVAL_WITH_U_APSD_COEX
6552 }
6553
6554 crate::natural::StatusCode::AntiCloggingTokenRequired => {
6555 StatusCode::ANTI_CLOGGING_TOKEN_REQUIRED
6556 }
6557
6558 crate::natural::StatusCode::UnsupportedFiniteCyclicGroup => {
6559 StatusCode::UNSUPPORTED_FINITE_CYCLIC_GROUP
6560 }
6561
6562 crate::natural::StatusCode::CannotFindAlternativeTbtt => {
6563 StatusCode::CANNOT_FIND_ALTERNATIVE_TBTT
6564 }
6565
6566 crate::natural::StatusCode::TransmissionFailure => StatusCode::TRANSMISSION_FAILURE,
6567
6568 crate::natural::StatusCode::RequestedTclasNotSupported => {
6569 StatusCode::REQUESTED_TCLAS_NOT_SUPPORTED
6570 }
6571
6572 crate::natural::StatusCode::TclasResourcesExhausted => {
6573 StatusCode::TCLAS_RESOURCES_EXHAUSTED
6574 }
6575
6576 crate::natural::StatusCode::RejectedWithSuggestedBssTransition => {
6577 StatusCode::REJECTED_WITH_SUGGESTED_BSS_TRANSITION
6578 }
6579
6580 crate::natural::StatusCode::RejectWithSchedule => StatusCode::REJECT_WITH_SCHEDULE,
6581
6582 crate::natural::StatusCode::RejectNoWakeupSpecified => {
6583 StatusCode::REJECT_NO_WAKEUP_SPECIFIED
6584 }
6585
6586 crate::natural::StatusCode::SuccessPowerSaveMode => {
6587 StatusCode::SUCCESS_POWER_SAVE_MODE
6588 }
6589
6590 crate::natural::StatusCode::PendingAdmittingFstSession => {
6591 StatusCode::PENDING_ADMITTING_FST_SESSION
6592 }
6593
6594 crate::natural::StatusCode::PerformingFstNow => StatusCode::PERFORMING_FST_NOW,
6595
6596 crate::natural::StatusCode::PendingGapInBaWindow => {
6597 StatusCode::PENDING_GAP_IN_BA_WINDOW
6598 }
6599
6600 crate::natural::StatusCode::RejectUPidSetting => StatusCode::REJECT_U_PID_SETTING,
6601
6602 crate::natural::StatusCode::RefusedExternalReason => {
6603 StatusCode::REFUSED_EXTERNAL_REASON
6604 }
6605
6606 crate::natural::StatusCode::RefusedApOutOfMemory => {
6607 StatusCode::REFUSED_AP_OUT_OF_MEMORY
6608 }
6609
6610 crate::natural::StatusCode::RejectedEmergencyServicesNotSupported => {
6611 StatusCode::REJECTED_EMERGENCY_SERVICES_NOT_SUPPORTED
6612 }
6613
6614 crate::natural::StatusCode::QueryResponseOutstanding => {
6615 StatusCode::QUERY_RESPONSE_OUTSTANDING
6616 }
6617
6618 crate::natural::StatusCode::RejectDseBand => StatusCode::REJECT_DSE_BAND,
6619
6620 crate::natural::StatusCode::TclasProcessingTerminated => {
6621 StatusCode::TCLAS_PROCESSING_TERMINATED
6622 }
6623
6624 crate::natural::StatusCode::TsScheduleConflict => StatusCode::TS_SCHEDULE_CONFLICT,
6625
6626 crate::natural::StatusCode::DeniedWithSuggestedBandAndChannel => {
6627 StatusCode::DENIED_WITH_SUGGESTED_BAND_AND_CHANNEL
6628 }
6629
6630 crate::natural::StatusCode::MccaopReservationConflict => {
6631 StatusCode::MCCAOP_RESERVATION_CONFLICT
6632 }
6633
6634 crate::natural::StatusCode::MafLimitExceeded => StatusCode::MAF_LIMIT_EXCEEDED,
6635
6636 crate::natural::StatusCode::MccaTrackLimitExceeded => {
6637 StatusCode::MCCA_TRACK_LIMIT_EXCEEDED
6638 }
6639
6640 crate::natural::StatusCode::DeniedDueToSpectrumManagement => {
6641 StatusCode::DENIED_DUE_TO_SPECTRUM_MANAGEMENT
6642 }
6643
6644 crate::natural::StatusCode::DeniedVhtNotSupported => {
6645 StatusCode::DENIED_VHT_NOT_SUPPORTED
6646 }
6647
6648 crate::natural::StatusCode::EnablementDenied => StatusCode::ENABLEMENT_DENIED,
6649
6650 crate::natural::StatusCode::RestrictionFromAuthorizedGdb => {
6651 StatusCode::RESTRICTION_FROM_AUTHORIZED_GDB
6652 }
6653
6654 crate::natural::StatusCode::AuthorizationDeenabled => {
6655 StatusCode::AUTHORIZATION_DEENABLED
6656 }
6657
6658 crate::natural::StatusCode::EnergyLimitedOperationNotSupported => {
6659 StatusCode::ENERGY_LIMITED_OPERATION_NOT_SUPPORTED
6660 }
6661
6662 crate::natural::StatusCode::RejectedNdpBlockAckSuggested => {
6663 StatusCode::REJECTED_NDP_BLOCK_ACK_SUGGESTED
6664 }
6665
6666 crate::natural::StatusCode::RejectedMaxAwayDurationUnacceptable => {
6667 StatusCode::REJECTED_MAX_AWAY_DURATION_UNACCEPTABLE
6668 }
6669
6670 crate::natural::StatusCode::FlowControlOperationSupported => {
6671 StatusCode::FLOW_CONTROL_OPERATION_SUPPORTED
6672 }
6673
6674 crate::natural::StatusCode::FilsAuthenticationFailure => {
6675 StatusCode::FILS_AUTHENTICATION_FAILURE
6676 }
6677
6678 crate::natural::StatusCode::UnknownAuthenticationServer => {
6679 StatusCode::UNKNOWN_AUTHENTICATION_SERVER
6680 }
6681
6682 crate::natural::StatusCode::DeniedNotificationPeriodAllocation => {
6683 StatusCode::DENIED_NOTIFICATION_PERIOD_ALLOCATION
6684 }
6685
6686 crate::natural::StatusCode::DeniedChannelSplitting => {
6687 StatusCode::DENIED_CHANNEL_SPLITTING
6688 }
6689
6690 crate::natural::StatusCode::DeniedAllocation => StatusCode::DENIED_ALLOCATION,
6691
6692 crate::natural::StatusCode::CmmgFeaturesNotSupported => {
6693 StatusCode::CMMG_FEATURES_NOT_SUPPORTED
6694 }
6695
6696 crate::natural::StatusCode::GasFragmentNotAvailable => {
6697 StatusCode::GAS_FRAGMENT_NOT_AVAILABLE
6698 }
6699
6700 crate::natural::StatusCode::SuccessCagVersionsMatch => {
6701 StatusCode::SUCCESS_CAG_VERSIONS_MATCH
6702 }
6703
6704 crate::natural::StatusCode::GlkNotAuthorized => StatusCode::GLK_NOT_AUTHORIZED,
6705
6706 crate::natural::StatusCode::UnknownPasswordIdentifier => {
6707 StatusCode::UNKNOWN_PASSWORD_IDENTIFIER
6708 }
6709
6710 crate::natural::StatusCode::DeniedLocalMacAddressPolicyViolation => {
6711 StatusCode::DENIED_LOCAL_MAC_ADDRESS_POLICY_VIOLATION
6712 }
6713
6714 crate::natural::StatusCode::SaeHashToElement => StatusCode::SAE_HASH_TO_ELEMENT,
6715
6716 crate::natural::StatusCode::TclasProcessingTerminatedInsufficientQos => {
6717 StatusCode::TCLAS_PROCESSING_TERMINATED_INSUFFICIENT_QOS
6718 }
6719
6720 crate::natural::StatusCode::TclasProcessingTerminatedPolicyConflict => {
6721 StatusCode::TCLAS_PROCESSING_TERMINATED_POLICY_CONFLICT
6722 }
6723
6724 crate::natural::StatusCode::JoinFailure => StatusCode::JOIN_FAILURE,
6725
6726 crate::natural::StatusCode::SpuriousDeauthOrDisassoc => {
6727 StatusCode::SPURIOUS_DEAUTH_OR_DISASSOC
6728 }
6729
6730 crate::natural::StatusCode::Canceled => StatusCode::CANCELED,
6731
6732 crate::natural::StatusCode::EstablishRsnaFailure => {
6733 StatusCode::ESTABLISH_RSNA_FAILURE
6734 }
6735
6736 crate::natural::StatusCode::OweHandshakeFailure => {
6737 StatusCode::OWE_HANDSHAKE_FAILURE
6738 }
6739
6740 crate::natural::StatusCode::NoAckFromPeer => StatusCode::NO_ACK_FROM_PEER,
6741
6742 crate::natural::StatusCode::ResponseTimeout => StatusCode::RESPONSE_TIMEOUT,
6743
6744 crate::natural::StatusCode::UnexpectedResponse => StatusCode::UNEXPECTED_RESPONSE,
6745
6746 crate::natural::StatusCode::InternalFailure => StatusCode::INTERNAL_FAILURE,
6747
6748 crate::natural::StatusCode::UnknownOrdinal_(value) => {
6749 StatusCode { value: ::fidl_next::wire::Uint16::from(value) }
6750 }
6751 }
6752 }
6753 }
6754
6755 impl ::fidl_next::IntoNatural for StatusCode {
6756 type Natural = crate::natural::StatusCode;
6757 }
6758
6759 #[derive(Clone, Debug)]
6761 #[repr(C)]
6762 pub struct VhtCapabilities {
6763 pub bytes: [u8; 12],
6764 }
6765
6766 static_assertions::const_assert_eq!(std::mem::size_of::<VhtCapabilities>(), 12);
6767 static_assertions::const_assert_eq!(std::mem::align_of::<VhtCapabilities>(), 1);
6768
6769 static_assertions::const_assert_eq!(std::mem::offset_of!(VhtCapabilities, bytes), 0);
6770
6771 impl ::fidl_next::Constrained for VhtCapabilities {
6772 type Constraint = ();
6773
6774 fn validate(
6775 _: ::fidl_next::Slot<'_, Self>,
6776 _: Self::Constraint,
6777 ) -> Result<(), ::fidl_next::ValidationError> {
6778 Ok(())
6779 }
6780 }
6781
6782 unsafe impl ::fidl_next::Wire for VhtCapabilities {
6783 type Narrowed<'de> = VhtCapabilities;
6784
6785 #[inline]
6786 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
6787 ::fidl_next::munge! {
6788 let Self {
6789 bytes,
6790
6791 } = &mut *out_;
6792 }
6793
6794 ::fidl_next::Wire::zero_padding(bytes);
6795 }
6796 }
6797
6798 unsafe impl<___D> ::fidl_next::Decode<___D> for VhtCapabilities
6799 where
6800 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
6801 {
6802 fn decode(
6803 slot_: ::fidl_next::Slot<'_, Self>,
6804 decoder_: &mut ___D,
6805 _: (),
6806 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
6807 ::fidl_next::munge! {
6808 let Self {
6809 mut bytes,
6810
6811 } = slot_;
6812 }
6813
6814 let _field = bytes.as_mut();
6815
6816 ::fidl_next::Decode::decode(bytes.as_mut(), decoder_, ())?;
6817
6818 Ok(())
6819 }
6820 }
6821
6822 impl ::fidl_next::IntoNatural for VhtCapabilities {
6823 type Natural = crate::natural::VhtCapabilities;
6824 }
6825
6826 #[derive(Clone, Debug)]
6828 #[repr(C)]
6829 pub struct VhtOperation {
6830 pub bytes: [u8; 5],
6831 }
6832
6833 static_assertions::const_assert_eq!(std::mem::size_of::<VhtOperation>(), 5);
6834 static_assertions::const_assert_eq!(std::mem::align_of::<VhtOperation>(), 1);
6835
6836 static_assertions::const_assert_eq!(std::mem::offset_of!(VhtOperation, bytes), 0);
6837
6838 impl ::fidl_next::Constrained for VhtOperation {
6839 type Constraint = ();
6840
6841 fn validate(
6842 _: ::fidl_next::Slot<'_, Self>,
6843 _: Self::Constraint,
6844 ) -> Result<(), ::fidl_next::ValidationError> {
6845 Ok(())
6846 }
6847 }
6848
6849 unsafe impl ::fidl_next::Wire for VhtOperation {
6850 type Narrowed<'de> = VhtOperation;
6851
6852 #[inline]
6853 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
6854 ::fidl_next::munge! {
6855 let Self {
6856 bytes,
6857
6858 } = &mut *out_;
6859 }
6860
6861 ::fidl_next::Wire::zero_padding(bytes);
6862 }
6863 }
6864
6865 unsafe impl<___D> ::fidl_next::Decode<___D> for VhtOperation
6866 where
6867 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
6868 {
6869 fn decode(
6870 slot_: ::fidl_next::Slot<'_, Self>,
6871 decoder_: &mut ___D,
6872 _: (),
6873 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
6874 ::fidl_next::munge! {
6875 let Self {
6876 mut bytes,
6877
6878 } = slot_;
6879 }
6880
6881 let _field = bytes.as_mut();
6882
6883 ::fidl_next::Decode::decode(bytes.as_mut(), decoder_, ())?;
6884
6885 Ok(())
6886 }
6887 }
6888
6889 impl ::fidl_next::IntoNatural for VhtOperation {
6890 type Natural = crate::natural::VhtOperation;
6891 }
6892
6893 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
6895 #[repr(transparent)]
6896 pub struct WlanAccessCategory {
6897 pub(crate) value: ::fidl_next::wire::Uint32,
6898 }
6899
6900 impl ::fidl_next::Constrained for WlanAccessCategory {
6901 type Constraint = ();
6902
6903 fn validate(
6904 _: ::fidl_next::Slot<'_, Self>,
6905 _: Self::Constraint,
6906 ) -> Result<(), ::fidl_next::ValidationError> {
6907 Ok(())
6908 }
6909 }
6910
6911 unsafe impl ::fidl_next::Wire for WlanAccessCategory {
6912 type Narrowed<'de> = Self;
6913
6914 #[inline]
6915 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
6916 }
6918 }
6919
6920 impl WlanAccessCategory {
6921 pub const BACKGROUND: WlanAccessCategory =
6922 WlanAccessCategory { value: ::fidl_next::wire::Uint32(1) };
6923
6924 pub const BEST_EFFORT: WlanAccessCategory =
6925 WlanAccessCategory { value: ::fidl_next::wire::Uint32(2) };
6926
6927 pub const VIDEO: WlanAccessCategory =
6928 WlanAccessCategory { value: ::fidl_next::wire::Uint32(3) };
6929
6930 pub const VOICE: WlanAccessCategory =
6931 WlanAccessCategory { value: ::fidl_next::wire::Uint32(4) };
6932 }
6933
6934 unsafe impl<___D> ::fidl_next::Decode<___D> for WlanAccessCategory
6935 where
6936 ___D: ?Sized,
6937 {
6938 fn decode(
6939 slot: ::fidl_next::Slot<'_, Self>,
6940 _: &mut ___D,
6941 _: (),
6942 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
6943 ::fidl_next::munge!(let Self { value } = slot);
6944
6945 match u32::from(*value) {
6946 1 | 2 | 3 | 4 => (),
6947 unknown => {
6948 return Err(::fidl_next::DecodeError::InvalidEnumOrdinal(unknown as i128));
6949 }
6950 }
6951
6952 Ok(())
6953 }
6954 }
6955
6956 impl ::core::convert::From<crate::natural::WlanAccessCategory> for WlanAccessCategory {
6957 fn from(natural: crate::natural::WlanAccessCategory) -> Self {
6958 match natural {
6959 crate::natural::WlanAccessCategory::Background => WlanAccessCategory::BACKGROUND,
6960
6961 crate::natural::WlanAccessCategory::BestEffort => WlanAccessCategory::BEST_EFFORT,
6962
6963 crate::natural::WlanAccessCategory::Video => WlanAccessCategory::VIDEO,
6964
6965 crate::natural::WlanAccessCategory::Voice => WlanAccessCategory::VOICE,
6966 }
6967 }
6968 }
6969
6970 impl ::fidl_next::IntoNatural for WlanAccessCategory {
6971 type Natural = crate::natural::WlanAccessCategory;
6972 }
6973
6974 #[derive(Clone, Debug)]
6976 #[repr(C)]
6977 pub struct WlanChannel {
6978 pub primary: u8,
6979
6980 pub cbw: crate::wire::ChannelBandwidth,
6981
6982 pub secondary80: u8,
6983 }
6984
6985 static_assertions::const_assert_eq!(std::mem::size_of::<WlanChannel>(), 12);
6986 static_assertions::const_assert_eq!(std::mem::align_of::<WlanChannel>(), 4);
6987
6988 static_assertions::const_assert_eq!(std::mem::offset_of!(WlanChannel, primary), 0);
6989
6990 static_assertions::const_assert_eq!(std::mem::offset_of!(WlanChannel, cbw), 4);
6991
6992 static_assertions::const_assert_eq!(std::mem::offset_of!(WlanChannel, secondary80), 8);
6993
6994 impl ::fidl_next::Constrained for WlanChannel {
6995 type Constraint = ();
6996
6997 fn validate(
6998 _: ::fidl_next::Slot<'_, Self>,
6999 _: Self::Constraint,
7000 ) -> Result<(), ::fidl_next::ValidationError> {
7001 Ok(())
7002 }
7003 }
7004
7005 unsafe impl ::fidl_next::Wire for WlanChannel {
7006 type Narrowed<'de> = WlanChannel;
7007
7008 #[inline]
7009 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
7010 ::fidl_next::munge! {
7011 let Self {
7012 primary,
7013 cbw,
7014 secondary80,
7015
7016 } = &mut *out_;
7017 }
7018
7019 ::fidl_next::Wire::zero_padding(primary);
7020
7021 ::fidl_next::Wire::zero_padding(cbw);
7022
7023 ::fidl_next::Wire::zero_padding(secondary80);
7024
7025 unsafe {
7026 out_.as_mut_ptr().cast::<u8>().add(9).write_bytes(0, 3);
7027 }
7028
7029 unsafe {
7030 out_.as_mut_ptr().cast::<u8>().add(1).write_bytes(0, 3);
7031 }
7032 }
7033 }
7034
7035 unsafe impl<___D> ::fidl_next::Decode<___D> for WlanChannel
7036 where
7037 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
7038 {
7039 fn decode(
7040 slot_: ::fidl_next::Slot<'_, Self>,
7041 decoder_: &mut ___D,
7042 _: (),
7043 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
7044 if slot_.as_bytes()[9..12] != [0u8; 3] {
7045 return Err(::fidl_next::DecodeError::InvalidPadding);
7046 }
7047
7048 if slot_.as_bytes()[1..4] != [0u8; 3] {
7049 return Err(::fidl_next::DecodeError::InvalidPadding);
7050 }
7051
7052 ::fidl_next::munge! {
7053 let Self {
7054 mut primary,
7055 mut cbw,
7056 mut secondary80,
7057
7058 } = slot_;
7059 }
7060
7061 let _field = primary.as_mut();
7062
7063 ::fidl_next::Decode::decode(primary.as_mut(), decoder_, ())?;
7064
7065 let _field = cbw.as_mut();
7066
7067 ::fidl_next::Decode::decode(cbw.as_mut(), decoder_, ())?;
7068
7069 let _field = secondary80.as_mut();
7070
7071 ::fidl_next::Decode::decode(secondary80.as_mut(), decoder_, ())?;
7072
7073 Ok(())
7074 }
7075 }
7076
7077 impl ::fidl_next::IntoNatural for WlanChannel {
7078 type Natural = crate::natural::WlanChannel;
7079 }
7080
7081 #[derive(Clone, Copy, Debug, PartialEq, Eq)]
7083 #[repr(transparent)]
7084 pub struct WlanPhyType {
7085 pub(crate) value: ::fidl_next::wire::Uint32,
7086 }
7087
7088 impl ::fidl_next::Constrained for WlanPhyType {
7089 type Constraint = ();
7090
7091 fn validate(
7092 _: ::fidl_next::Slot<'_, Self>,
7093 _: Self::Constraint,
7094 ) -> Result<(), ::fidl_next::ValidationError> {
7095 Ok(())
7096 }
7097 }
7098
7099 unsafe impl ::fidl_next::Wire for WlanPhyType {
7100 type Narrowed<'de> = Self;
7101
7102 #[inline]
7103 fn zero_padding(_: &mut ::core::mem::MaybeUninit<Self>) {
7104 }
7106 }
7107
7108 impl WlanPhyType {
7109 pub const DSSS: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(1) };
7110
7111 pub const HR: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(2) };
7112
7113 pub const OFDM: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(3) };
7114
7115 pub const ERP: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(4) };
7116
7117 pub const HT: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(5) };
7118
7119 pub const DMG: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(6) };
7120
7121 pub const VHT: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(7) };
7122
7123 pub const TVHT: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(8) };
7124
7125 pub const S1_G: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(9) };
7126
7127 pub const CDMG: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(10) };
7128
7129 pub const CMMG: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(11) };
7130
7131 pub const HE: WlanPhyType = WlanPhyType { value: ::fidl_next::wire::Uint32(12) };
7132 }
7133
7134 unsafe impl<___D> ::fidl_next::Decode<___D> for WlanPhyType
7135 where
7136 ___D: ?Sized,
7137 {
7138 fn decode(
7139 slot: ::fidl_next::Slot<'_, Self>,
7140 _: &mut ___D,
7141 _: (),
7142 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
7143 Ok(())
7144 }
7145 }
7146
7147 impl ::core::convert::From<crate::natural::WlanPhyType> for WlanPhyType {
7148 fn from(natural: crate::natural::WlanPhyType) -> Self {
7149 match natural {
7150 crate::natural::WlanPhyType::Dsss => WlanPhyType::DSSS,
7151
7152 crate::natural::WlanPhyType::Hr => WlanPhyType::HR,
7153
7154 crate::natural::WlanPhyType::Ofdm => WlanPhyType::OFDM,
7155
7156 crate::natural::WlanPhyType::Erp => WlanPhyType::ERP,
7157
7158 crate::natural::WlanPhyType::Ht => WlanPhyType::HT,
7159
7160 crate::natural::WlanPhyType::Dmg => WlanPhyType::DMG,
7161
7162 crate::natural::WlanPhyType::Vht => WlanPhyType::VHT,
7163
7164 crate::natural::WlanPhyType::Tvht => WlanPhyType::TVHT,
7165
7166 crate::natural::WlanPhyType::S1G => WlanPhyType::S1_G,
7167
7168 crate::natural::WlanPhyType::Cdmg => WlanPhyType::CDMG,
7169
7170 crate::natural::WlanPhyType::Cmmg => WlanPhyType::CMMG,
7171
7172 crate::natural::WlanPhyType::He => WlanPhyType::HE,
7173
7174 crate::natural::WlanPhyType::UnknownOrdinal_(value) => {
7175 WlanPhyType { value: ::fidl_next::wire::Uint32::from(value) }
7176 }
7177 }
7178 }
7179 }
7180
7181 impl ::fidl_next::IntoNatural for WlanPhyType {
7182 type Natural = crate::natural::WlanPhyType;
7183 }
7184}
7185
7186pub mod wire_optional {}
7187
7188pub mod generic {
7189
7190 pub struct ChannelNumber<T0, T1> {
7192 pub band: T0,
7193
7194 pub number: T1,
7195 }
7196
7197 unsafe impl<___E, T0, T1> ::fidl_next::Encode<crate::wire::ChannelNumber, ___E>
7198 for ChannelNumber<T0, T1>
7199 where
7200 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7201 T0: ::fidl_next::Encode<crate::wire::WlanBand, ___E>,
7202 T1: ::fidl_next::Encode<u8, ___E>,
7203 {
7204 #[inline]
7205 fn encode(
7206 self,
7207 encoder_: &mut ___E,
7208 out_: &mut ::core::mem::MaybeUninit<crate::wire::ChannelNumber>,
7209 _: (),
7210 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7211 ::fidl_next::munge! {
7212 let crate::wire::ChannelNumber {
7213 band,
7214 number,
7215
7216 } = out_;
7217 }
7218
7219 ::fidl_next::Encode::encode(self.band, encoder_, band, ())?;
7220
7221 ::fidl_next::Encode::encode(self.number, encoder_, number, ())?;
7222
7223 Ok(())
7224 }
7225 }
7226
7227 unsafe impl<'a, ___E, T0, T1> ::fidl_next::Encode<crate::wire::ChannelNumber, ___E>
7228 for &'a ChannelNumber<T0, T1>
7229 where
7230 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7231 &'a T0: ::fidl_next::Encode<crate::wire::WlanBand, ___E>,
7232 &'a T1: ::fidl_next::Encode<u8, ___E>,
7233 {
7234 #[inline]
7235 fn encode(
7236 self,
7237 encoder_: &mut ___E,
7238 out_: &mut ::core::mem::MaybeUninit<crate::wire::ChannelNumber>,
7239 _: (),
7240 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7241 ::fidl_next::munge! {
7242 let crate::wire::ChannelNumber {
7243 band,
7244 number,
7245
7246 } = out_;
7247 }
7248
7249 ::fidl_next::Encode::encode(&self.band, encoder_, band, ())?;
7250
7251 ::fidl_next::Encode::encode(&self.number, encoder_, number, ())?;
7252
7253 Ok(())
7254 }
7255 }
7256
7257 pub struct BssDescription<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9> {
7259 pub bssid: T0,
7260
7261 pub bss_type: T1,
7262
7263 pub beacon_period: T2,
7264
7265 pub capability_info: T3,
7266
7267 pub ies: T4,
7268
7269 pub primary: T5,
7270
7271 pub bandwidth: T6,
7272
7273 pub vht_secondary_80_channel: T7,
7274
7275 pub rssi_dbm: T8,
7276
7277 pub snr_db: T9,
7278 }
7279
7280 unsafe impl<___E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>
7281 ::fidl_next::Encode<crate::wire::BssDescription<'static>, ___E>
7282 for BssDescription<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>
7283 where
7284 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7285 ___E: ::fidl_next::Encoder,
7286 T0: ::fidl_next::Encode<[u8; 6], ___E>,
7287 T1: ::fidl_next::Encode<crate::wire::BssType, ___E>,
7288 T2: ::fidl_next::Encode<::fidl_next::wire::Uint16, ___E>,
7289 T3: ::fidl_next::Encode<::fidl_next::wire::Uint16, ___E>,
7290 T4: ::fidl_next::Encode<::fidl_next::wire::Vector<'static, u8>, ___E>,
7291 T5: ::fidl_next::Encode<crate::wire::ChannelNumber, ___E>,
7292 T6: ::fidl_next::Encode<crate::wire::ChannelBandwidth, ___E>,
7293 T7: ::fidl_next::Encode<crate::wire::ChannelNumber, ___E>,
7294 T8: ::fidl_next::Encode<i8, ___E>,
7295 T9: ::fidl_next::Encode<i8, ___E>,
7296 {
7297 #[inline]
7298 fn encode(
7299 self,
7300 encoder_: &mut ___E,
7301 out_: &mut ::core::mem::MaybeUninit<crate::wire::BssDescription<'static>>,
7302 _: (),
7303 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7304 ::fidl_next::munge! {
7305 let crate::wire::BssDescription {
7306 bssid,
7307 bss_type,
7308 beacon_period,
7309 capability_info,
7310 ies,
7311 primary,
7312 bandwidth,
7313 vht_secondary_80_channel,
7314 rssi_dbm,
7315 snr_db,
7316
7317 } = out_;
7318 }
7319
7320 ::fidl_next::Encode::encode(self.bssid, encoder_, bssid, ())?;
7321
7322 ::fidl_next::Encode::encode(self.bss_type, encoder_, bss_type, ())?;
7323
7324 ::fidl_next::Encode::encode(self.beacon_period, encoder_, beacon_period, ())?;
7325
7326 ::fidl_next::Encode::encode(self.capability_info, encoder_, capability_info, ())?;
7327
7328 ::fidl_next::Encode::encode(self.ies, encoder_, ies, (4294967295, ()))?;
7329
7330 ::fidl_next::Encode::encode(self.primary, encoder_, primary, ())?;
7331
7332 ::fidl_next::Encode::encode(self.bandwidth, encoder_, bandwidth, ())?;
7333
7334 ::fidl_next::Encode::encode(
7335 self.vht_secondary_80_channel,
7336 encoder_,
7337 vht_secondary_80_channel,
7338 (),
7339 )?;
7340
7341 ::fidl_next::Encode::encode(self.rssi_dbm, encoder_, rssi_dbm, ())?;
7342
7343 ::fidl_next::Encode::encode(self.snr_db, encoder_, snr_db, ())?;
7344
7345 Ok(())
7346 }
7347 }
7348
7349 unsafe impl<'a, ___E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>
7350 ::fidl_next::Encode<crate::wire::BssDescription<'static>, ___E>
7351 for &'a BssDescription<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>
7352 where
7353 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7354 ___E: ::fidl_next::Encoder,
7355 &'a T0: ::fidl_next::Encode<[u8; 6], ___E>,
7356 &'a T1: ::fidl_next::Encode<crate::wire::BssType, ___E>,
7357 &'a T2: ::fidl_next::Encode<::fidl_next::wire::Uint16, ___E>,
7358 &'a T3: ::fidl_next::Encode<::fidl_next::wire::Uint16, ___E>,
7359 &'a T4: ::fidl_next::Encode<::fidl_next::wire::Vector<'static, u8>, ___E>,
7360 &'a T5: ::fidl_next::Encode<crate::wire::ChannelNumber, ___E>,
7361 &'a T6: ::fidl_next::Encode<crate::wire::ChannelBandwidth, ___E>,
7362 &'a T7: ::fidl_next::Encode<crate::wire::ChannelNumber, ___E>,
7363 &'a T8: ::fidl_next::Encode<i8, ___E>,
7364 &'a T9: ::fidl_next::Encode<i8, ___E>,
7365 {
7366 #[inline]
7367 fn encode(
7368 self,
7369 encoder_: &mut ___E,
7370 out_: &mut ::core::mem::MaybeUninit<crate::wire::BssDescription<'static>>,
7371 _: (),
7372 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7373 ::fidl_next::munge! {
7374 let crate::wire::BssDescription {
7375 bssid,
7376 bss_type,
7377 beacon_period,
7378 capability_info,
7379 ies,
7380 primary,
7381 bandwidth,
7382 vht_secondary_80_channel,
7383 rssi_dbm,
7384 snr_db,
7385
7386 } = out_;
7387 }
7388
7389 ::fidl_next::Encode::encode(&self.bssid, encoder_, bssid, ())?;
7390
7391 ::fidl_next::Encode::encode(&self.bss_type, encoder_, bss_type, ())?;
7392
7393 ::fidl_next::Encode::encode(&self.beacon_period, encoder_, beacon_period, ())?;
7394
7395 ::fidl_next::Encode::encode(&self.capability_info, encoder_, capability_info, ())?;
7396
7397 ::fidl_next::Encode::encode(&self.ies, encoder_, ies, (4294967295, ()))?;
7398
7399 ::fidl_next::Encode::encode(&self.primary, encoder_, primary, ())?;
7400
7401 ::fidl_next::Encode::encode(&self.bandwidth, encoder_, bandwidth, ())?;
7402
7403 ::fidl_next::Encode::encode(
7404 &self.vht_secondary_80_channel,
7405 encoder_,
7406 vht_secondary_80_channel,
7407 (),
7408 )?;
7409
7410 ::fidl_next::Encode::encode(&self.rssi_dbm, encoder_, rssi_dbm, ())?;
7411
7412 ::fidl_next::Encode::encode(&self.snr_db, encoder_, snr_db, ())?;
7413
7414 Ok(())
7415 }
7416 }
7417
7418 pub struct CSsid<T0, T1> {
7420 pub len: T0,
7421
7422 pub data: T1,
7423 }
7424
7425 unsafe impl<___E, T0, T1> ::fidl_next::Encode<crate::wire::CSsid, ___E> for CSsid<T0, T1>
7426 where
7427 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7428 T0: ::fidl_next::Encode<u8, ___E>,
7429 T1: ::fidl_next::Encode<[u8; 32], ___E>,
7430 {
7431 #[inline]
7432 fn encode(
7433 self,
7434 encoder_: &mut ___E,
7435 out_: &mut ::core::mem::MaybeUninit<crate::wire::CSsid>,
7436 _: (),
7437 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7438 ::fidl_next::munge! {
7439 let crate::wire::CSsid {
7440 len,
7441 data,
7442
7443 } = out_;
7444 }
7445
7446 ::fidl_next::Encode::encode(self.len, encoder_, len, ())?;
7447
7448 ::fidl_next::Encode::encode(self.data, encoder_, data, ())?;
7449
7450 Ok(())
7451 }
7452 }
7453
7454 unsafe impl<'a, ___E, T0, T1> ::fidl_next::Encode<crate::wire::CSsid, ___E> for &'a CSsid<T0, T1>
7455 where
7456 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7457 &'a T0: ::fidl_next::Encode<u8, ___E>,
7458 &'a T1: ::fidl_next::Encode<[u8; 32], ___E>,
7459 {
7460 #[inline]
7461 fn encode(
7462 self,
7463 encoder_: &mut ___E,
7464 out_: &mut ::core::mem::MaybeUninit<crate::wire::CSsid>,
7465 _: (),
7466 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7467 ::fidl_next::munge! {
7468 let crate::wire::CSsid {
7469 len,
7470 data,
7471
7472 } = out_;
7473 }
7474
7475 ::fidl_next::Encode::encode(&self.len, encoder_, len, ())?;
7476
7477 ::fidl_next::Encode::encode(&self.data, encoder_, data, ())?;
7478
7479 Ok(())
7480 }
7481 }
7482
7483 pub struct HtCapabilities<T0> {
7485 pub bytes: T0,
7486 }
7487
7488 unsafe impl<___E, T0> ::fidl_next::Encode<crate::wire::HtCapabilities, ___E> for HtCapabilities<T0>
7489 where
7490 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7491 T0: ::fidl_next::Encode<[u8; 26], ___E>,
7492 {
7493 #[inline]
7494 fn encode(
7495 self,
7496 encoder_: &mut ___E,
7497 out_: &mut ::core::mem::MaybeUninit<crate::wire::HtCapabilities>,
7498 _: (),
7499 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7500 ::fidl_next::munge! {
7501 let crate::wire::HtCapabilities {
7502 bytes,
7503
7504 } = out_;
7505 }
7506
7507 ::fidl_next::Encode::encode(self.bytes, encoder_, bytes, ())?;
7508
7509 Ok(())
7510 }
7511 }
7512
7513 unsafe impl<'a, ___E, T0> ::fidl_next::Encode<crate::wire::HtCapabilities, ___E>
7514 for &'a HtCapabilities<T0>
7515 where
7516 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7517 &'a T0: ::fidl_next::Encode<[u8; 26], ___E>,
7518 {
7519 #[inline]
7520 fn encode(
7521 self,
7522 encoder_: &mut ___E,
7523 out_: &mut ::core::mem::MaybeUninit<crate::wire::HtCapabilities>,
7524 _: (),
7525 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7526 ::fidl_next::munge! {
7527 let crate::wire::HtCapabilities {
7528 bytes,
7529
7530 } = out_;
7531 }
7532
7533 ::fidl_next::Encode::encode(&self.bytes, encoder_, bytes, ())?;
7534
7535 Ok(())
7536 }
7537 }
7538
7539 pub struct HtOperation<T0> {
7541 pub bytes: T0,
7542 }
7543
7544 unsafe impl<___E, T0> ::fidl_next::Encode<crate::wire::HtOperation, ___E> for HtOperation<T0>
7545 where
7546 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7547 T0: ::fidl_next::Encode<[u8; 22], ___E>,
7548 {
7549 #[inline]
7550 fn encode(
7551 self,
7552 encoder_: &mut ___E,
7553 out_: &mut ::core::mem::MaybeUninit<crate::wire::HtOperation>,
7554 _: (),
7555 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7556 ::fidl_next::munge! {
7557 let crate::wire::HtOperation {
7558 bytes,
7559
7560 } = out_;
7561 }
7562
7563 ::fidl_next::Encode::encode(self.bytes, encoder_, bytes, ())?;
7564
7565 Ok(())
7566 }
7567 }
7568
7569 unsafe impl<'a, ___E, T0> ::fidl_next::Encode<crate::wire::HtOperation, ___E>
7570 for &'a HtOperation<T0>
7571 where
7572 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7573 &'a T0: ::fidl_next::Encode<[u8; 22], ___E>,
7574 {
7575 #[inline]
7576 fn encode(
7577 self,
7578 encoder_: &mut ___E,
7579 out_: &mut ::core::mem::MaybeUninit<crate::wire::HtOperation>,
7580 _: (),
7581 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7582 ::fidl_next::munge! {
7583 let crate::wire::HtOperation {
7584 bytes,
7585
7586 } = out_;
7587 }
7588
7589 ::fidl_next::Encode::encode(&self.bytes, encoder_, bytes, ())?;
7590
7591 Ok(())
7592 }
7593 }
7594
7595 pub struct VhtCapabilities<T0> {
7597 pub bytes: T0,
7598 }
7599
7600 unsafe impl<___E, T0> ::fidl_next::Encode<crate::wire::VhtCapabilities, ___E>
7601 for VhtCapabilities<T0>
7602 where
7603 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7604 T0: ::fidl_next::Encode<[u8; 12], ___E>,
7605 {
7606 #[inline]
7607 fn encode(
7608 self,
7609 encoder_: &mut ___E,
7610 out_: &mut ::core::mem::MaybeUninit<crate::wire::VhtCapabilities>,
7611 _: (),
7612 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7613 ::fidl_next::munge! {
7614 let crate::wire::VhtCapabilities {
7615 bytes,
7616
7617 } = out_;
7618 }
7619
7620 ::fidl_next::Encode::encode(self.bytes, encoder_, bytes, ())?;
7621
7622 Ok(())
7623 }
7624 }
7625
7626 unsafe impl<'a, ___E, T0> ::fidl_next::Encode<crate::wire::VhtCapabilities, ___E>
7627 for &'a VhtCapabilities<T0>
7628 where
7629 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7630 &'a T0: ::fidl_next::Encode<[u8; 12], ___E>,
7631 {
7632 #[inline]
7633 fn encode(
7634 self,
7635 encoder_: &mut ___E,
7636 out_: &mut ::core::mem::MaybeUninit<crate::wire::VhtCapabilities>,
7637 _: (),
7638 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7639 ::fidl_next::munge! {
7640 let crate::wire::VhtCapabilities {
7641 bytes,
7642
7643 } = out_;
7644 }
7645
7646 ::fidl_next::Encode::encode(&self.bytes, encoder_, bytes, ())?;
7647
7648 Ok(())
7649 }
7650 }
7651
7652 pub struct VhtOperation<T0> {
7654 pub bytes: T0,
7655 }
7656
7657 unsafe impl<___E, T0> ::fidl_next::Encode<crate::wire::VhtOperation, ___E> for VhtOperation<T0>
7658 where
7659 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7660 T0: ::fidl_next::Encode<[u8; 5], ___E>,
7661 {
7662 #[inline]
7663 fn encode(
7664 self,
7665 encoder_: &mut ___E,
7666 out_: &mut ::core::mem::MaybeUninit<crate::wire::VhtOperation>,
7667 _: (),
7668 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7669 ::fidl_next::munge! {
7670 let crate::wire::VhtOperation {
7671 bytes,
7672
7673 } = out_;
7674 }
7675
7676 ::fidl_next::Encode::encode(self.bytes, encoder_, bytes, ())?;
7677
7678 Ok(())
7679 }
7680 }
7681
7682 unsafe impl<'a, ___E, T0> ::fidl_next::Encode<crate::wire::VhtOperation, ___E>
7683 for &'a VhtOperation<T0>
7684 where
7685 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7686 &'a T0: ::fidl_next::Encode<[u8; 5], ___E>,
7687 {
7688 #[inline]
7689 fn encode(
7690 self,
7691 encoder_: &mut ___E,
7692 out_: &mut ::core::mem::MaybeUninit<crate::wire::VhtOperation>,
7693 _: (),
7694 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7695 ::fidl_next::munge! {
7696 let crate::wire::VhtOperation {
7697 bytes,
7698
7699 } = out_;
7700 }
7701
7702 ::fidl_next::Encode::encode(&self.bytes, encoder_, bytes, ())?;
7703
7704 Ok(())
7705 }
7706 }
7707
7708 pub struct WlanChannel<T0, T1, T2> {
7710 pub primary: T0,
7711
7712 pub cbw: T1,
7713
7714 pub secondary80: T2,
7715 }
7716
7717 unsafe impl<___E, T0, T1, T2> ::fidl_next::Encode<crate::wire::WlanChannel, ___E>
7718 for WlanChannel<T0, T1, T2>
7719 where
7720 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7721 T0: ::fidl_next::Encode<u8, ___E>,
7722 T1: ::fidl_next::Encode<crate::wire::ChannelBandwidth, ___E>,
7723 T2: ::fidl_next::Encode<u8, ___E>,
7724 {
7725 #[inline]
7726 fn encode(
7727 self,
7728 encoder_: &mut ___E,
7729 out_: &mut ::core::mem::MaybeUninit<crate::wire::WlanChannel>,
7730 _: (),
7731 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7732 ::fidl_next::munge! {
7733 let crate::wire::WlanChannel {
7734 primary,
7735 cbw,
7736 secondary80,
7737
7738 } = out_;
7739 }
7740
7741 ::fidl_next::Encode::encode(self.primary, encoder_, primary, ())?;
7742
7743 ::fidl_next::Encode::encode(self.cbw, encoder_, cbw, ())?;
7744
7745 ::fidl_next::Encode::encode(self.secondary80, encoder_, secondary80, ())?;
7746
7747 Ok(())
7748 }
7749 }
7750
7751 unsafe impl<'a, ___E, T0, T1, T2> ::fidl_next::Encode<crate::wire::WlanChannel, ___E>
7752 for &'a WlanChannel<T0, T1, T2>
7753 where
7754 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
7755 &'a T0: ::fidl_next::Encode<u8, ___E>,
7756 &'a T1: ::fidl_next::Encode<crate::wire::ChannelBandwidth, ___E>,
7757 &'a T2: ::fidl_next::Encode<u8, ___E>,
7758 {
7759 #[inline]
7760 fn encode(
7761 self,
7762 encoder_: &mut ___E,
7763 out_: &mut ::core::mem::MaybeUninit<crate::wire::WlanChannel>,
7764 _: (),
7765 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
7766 ::fidl_next::munge! {
7767 let crate::wire::WlanChannel {
7768 primary,
7769 cbw,
7770 secondary80,
7771
7772 } = out_;
7773 }
7774
7775 ::fidl_next::Encode::encode(&self.primary, encoder_, primary, ())?;
7776
7777 ::fidl_next::Encode::encode(&self.cbw, encoder_, cbw, ())?;
7778
7779 ::fidl_next::Encode::encode(&self.secondary80, encoder_, secondary80, ())?;
7780
7781 Ok(())
7782 }
7783 }
7784}
7785
7786pub use self::natural::*;
7787
7788pub const MAC_ADDR_LEN: u8 = 6 as u8;
7789
7790pub const CCMP_128_MIC_LEN: u32 = 8 as u32;
7791
7792pub const CCMP_256_MIC_LEN: u32 = 16 as u32;
7793
7794#[doc = " IEEE Std 802.11-2016 12.5.3.2\n"]
7795pub const CCMP_HDR_LEN: u32 = 8 as u32;
7796
7797pub const CCMP_PN_LEN: u32 = 6 as u32;
7798
7799#[doc = " IEEE Std 802.11-2016, 9.4.2.2\n The maximum length of an SSID is 32 bytes, even when the SSID should be\n interpreted using UTF-8 encoding (see Table 9-135). While every length in\n the 802.11 standard is byte oriented, the word BYTE is included in the\n name of this constant to emphasize the importance that it not be applied\n to the length of a UTF-8 encoded string.\n"]
7800pub const MAX_SSID_BYTE_LEN: u8 = 32 as u8;
7801
7802pub const HT_CAP_LEN: u8 = 26 as u8;
7803
7804pub const HT_OP_LEN: u8 = 22 as u8;
7805
7806pub const MAX_KEY_LEN: u8 = 32 as u8;
7807
7808#[doc = " IEEE Std 802.11-2016, 9.4.2.99\n"]
7809pub const MAX_MESH_ID_BYTE_LEN: u8 = 32 as u8;
7810
7811#[doc = " IEEE Std 802.11-2016, 9.3.3.2\n"]
7812pub const MAX_MGMT_FRAME_MAC_HEADER_BYTE_LEN: u8 = 28 as u8;
7813
7814#[doc = " IEEE Std 802.11-2016, 9.2.4.7\n"]
7815pub const MAX_MMPDU_BYTE_LEN: u16 = 2304 as u16;
7816
7817pub const MAX_SUPPORTED_BASIC_RATES: u8 = 12 as u8;
7818
7819#[doc = " The limit on the number of channels in a list of unique channel numbers is 256\n since a channel number in IEEE 802.11-2016 cannot exceed one octet. See\n IEEE 802.11-2016 9.4.2.18 Supported Channels element for an example element\n that assumes a channel number does not exceed one octet.\n"]
7820pub const MAX_UNIQUE_CHANNEL_NUMBERS: u16 = 256 as u16;
7821
7822pub const MAX_VHT_MPDU_BYTE_LEN_0: u16 = 3895 as u16;
7823
7824pub const MAX_VHT_MPDU_BYTE_LEN_1: u16 = 7991 as u16;
7825
7826pub const MAX_VHT_MPDU_BYTE_LEN_2: u16 = 11454 as u16;
7827
7828pub const OUI_LEN: u8 = 3 as u8;
7829
7830#[doc = " The limit on the number of SSIDs is 84 because an SSID List IE can contain no\n more than 84 one byte SSIDs. (Specifying a zero byte SSID in an SSID List with\n more than one SSID is valid but unnecessary since it is the wildcard SSID.)\n"]
7831pub const SSID_LIST_MAX: u8 = 84 as u8;
7832
7833#[doc = " IEEE Std 802.11-2016, 9.2.4.5\n"]
7834pub const TIDS_MAX: u32 = 16 as u32;
7835
7836pub const VHT_CAP_LEN: u8 = 12 as u8;
7837
7838pub const VHT_OP_LEN: u8 = 5 as u8;
7839
7840pub const WLAN_IE_BODY_MAX_LEN: u32 = 255 as u32;
7841
7842#[doc = " IEEE Std 802.11-2016, 9.4.2.25.1\n IEEE mentions that an element body maximum length is 255 octets in the RSN element\n section, but not in a dedicated section.\n Since the IE header is two octets, the whole IE max length is 257 octets.\n"]
7843pub const WLAN_IE_MAX_LEN: u32 = 257 as u32;
7844
7845#[doc = " IEEE Std 802.11-2016, Table 9-19\n"]
7846pub const WLAN_MSDU_MAX_LEN: u32 = 2304 as u32;