Skip to main content

fidl_next_fuchsia_wlan_phyimpl/
fidl_next_fuchsia_wlan_phyimpl.rs

1// DO NOT EDIT: This file is machine-generated by fidlgen
2#![warn(clippy::all)]
3#![allow(unused_parens, unused_variables, unused_mut, unused_imports, unreachable_code)]
4
5pub mod natural {
6
7    pub use fidl_next_common_fuchsia_wlan_phyimpl::natural::*;
8
9    #[derive(Debug, Default, PartialEq)]
10    pub struct WlanPhyImplCreateIfaceRequest {
11        pub role: ::core::option::Option<::fidl_next_fuchsia_wlan_common::natural::WlanMacRole>,
12
13        pub mlme_channel: ::core::option::Option<::fidl_next::fuchsia::zx::Channel>,
14
15        pub init_sta_addr: ::core::option::Option<[u8; 6]>,
16    }
17
18    impl WlanPhyImplCreateIfaceRequest {
19        fn __max_ordinal(&self) -> usize {
20            if self.init_sta_addr.is_some() {
21                return 3;
22            }
23
24            if self.mlme_channel.is_some() {
25                return 2;
26            }
27
28            if self.role.is_some() {
29                return 1;
30            }
31
32            0
33        }
34    }
35
36    unsafe impl<___E> ::fidl_next::Encode<crate::wire::WlanPhyImplCreateIfaceRequest<'static>, ___E>
37        for WlanPhyImplCreateIfaceRequest
38    where
39        ___E: ::fidl_next::Encoder + ?Sized,
40        ___E: ::fidl_next::fuchsia::HandleEncoder,
41    {
42        #[inline]
43        fn encode(
44            mut self,
45            encoder: &mut ___E,
46            out: &mut ::core::mem::MaybeUninit<crate::wire::WlanPhyImplCreateIfaceRequest<'static>>,
47            _: (),
48        ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
49            ::fidl_next::munge!(let crate::wire::WlanPhyImplCreateIfaceRequest { table } = out);
50
51            let max_ord = self.__max_ordinal();
52
53            let mut out = ::core::mem::MaybeUninit::<::fidl_next::wire::Envelope>::uninit();
54            ::fidl_next::Wire::zero_padding(&mut out);
55
56            let mut preallocated = ::fidl_next::EncoderExt::preallocate::<
57                ::fidl_next::wire::Envelope,
58            >(encoder, max_ord);
59
60            for i in 1..=max_ord {
61                match i {
62                    3 => {
63                        if let Some(value) = self.init_sta_addr.take() {
64                            ::fidl_next::wire::Envelope::encode_value::<[u8; 6], ___E>(
65                                value,
66                                preallocated.encoder,
67                                &mut out,
68                                (),
69                            )?;
70                        } else {
71                            ::fidl_next::wire::Envelope::encode_zero(&mut out)
72                        }
73                    }
74
75                    2 => {
76                        if let Some(value) = self.mlme_channel.take() {
77                            ::fidl_next::wire::Envelope::encode_value::<
78                                ::fidl_next::wire::fuchsia::Channel,
79                                ___E,
80                            >(
81                                value, preallocated.encoder, &mut out, ()
82                            )?;
83                        } else {
84                            ::fidl_next::wire::Envelope::encode_zero(&mut out)
85                        }
86                    }
87
88                    1 => {
89                        if let Some(value) = self.role.take() {
90                            ::fidl_next::wire::Envelope::encode_value::<
91                                ::fidl_next_fuchsia_wlan_common::wire::WlanMacRole,
92                                ___E,
93                            >(
94                                value, preallocated.encoder, &mut out, ()
95                            )?;
96                        } else {
97                            ::fidl_next::wire::Envelope::encode_zero(&mut out)
98                        }
99                    }
100
101                    _ => ::fidl_next::wire::Envelope::encode_zero(&mut out),
102                }
103                unsafe {
104                    preallocated.write_next(out.assume_init_ref());
105                }
106            }
107
108            ::fidl_next::wire::Table::encode_len(table, max_ord);
109
110            Ok(())
111        }
112    }
113
114    impl<'de> ::fidl_next::FromWire<crate::wire::WlanPhyImplCreateIfaceRequest<'de>>
115        for WlanPhyImplCreateIfaceRequest
116    {
117        #[inline]
118        fn from_wire(wire_: crate::wire::WlanPhyImplCreateIfaceRequest<'de>) -> Self {
119            let wire_ = ::core::mem::ManuallyDrop::new(wire_);
120
121            let role = wire_.table.get(1);
122
123            let mlme_channel = wire_.table.get(2);
124
125            let init_sta_addr = wire_.table.get(3);
126
127            Self {
128                role: role.map(|envelope| {
129                    ::fidl_next::FromWire::from_wire(unsafe {
130                        envelope
131                            .read_unchecked::<::fidl_next_fuchsia_wlan_common::wire::WlanMacRole>()
132                    })
133                }),
134
135                mlme_channel: mlme_channel.map(|envelope| {
136                    ::fidl_next::FromWire::from_wire(unsafe {
137                        envelope.read_unchecked::<::fidl_next::wire::fuchsia::Channel>()
138                    })
139                }),
140
141                init_sta_addr: init_sta_addr.map(|envelope| {
142                    ::fidl_next::FromWire::from_wire(unsafe {
143                        envelope.read_unchecked::<[u8; 6]>()
144                    })
145                }),
146            }
147        }
148    }
149
150    #[derive(Debug, Default, PartialEq)]
151    pub struct WlanPhyImplInitRequest {
152        pub notify_client: ::core::option::Option<
153            ::fidl_next::ClientEnd<crate::WlanPhyImplNotify, ::fidl_next::fuchsia::zx::Channel>,
154        >,
155    }
156
157    impl WlanPhyImplInitRequest {
158        fn __max_ordinal(&self) -> usize {
159            if self.notify_client.is_some() {
160                return 1;
161            }
162
163            0
164        }
165    }
166
167    unsafe impl<___E> ::fidl_next::Encode<crate::wire::WlanPhyImplInitRequest<'static>, ___E>
168        for WlanPhyImplInitRequest
169    where
170        ___E: ::fidl_next::Encoder + ?Sized,
171        ___E: ::fidl_next::fuchsia::HandleEncoder,
172    {
173        #[inline]
174        fn encode(
175            mut self,
176            encoder: &mut ___E,
177            out: &mut ::core::mem::MaybeUninit<crate::wire::WlanPhyImplInitRequest<'static>>,
178            _: (),
179        ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
180            ::fidl_next::munge!(let crate::wire::WlanPhyImplInitRequest { table } = out);
181
182            let max_ord = self.__max_ordinal();
183
184            let mut out = ::core::mem::MaybeUninit::<::fidl_next::wire::Envelope>::uninit();
185            ::fidl_next::Wire::zero_padding(&mut out);
186
187            let mut preallocated = ::fidl_next::EncoderExt::preallocate::<
188                ::fidl_next::wire::Envelope,
189            >(encoder, max_ord);
190
191            for i in 1..=max_ord {
192                match i {
193                    1 => {
194                        if let Some(value) = self.notify_client.take() {
195                            ::fidl_next::wire::Envelope::encode_value::<
196                                ::fidl_next::ClientEnd<
197                                    crate::WlanPhyImplNotify,
198                                    ::fidl_next::wire::fuchsia::Channel,
199                                >,
200                                ___E,
201                            >(
202                                value, preallocated.encoder, &mut out, ()
203                            )?;
204                        } else {
205                            ::fidl_next::wire::Envelope::encode_zero(&mut out)
206                        }
207                    }
208
209                    _ => ::fidl_next::wire::Envelope::encode_zero(&mut out),
210                }
211                unsafe {
212                    preallocated.write_next(out.assume_init_ref());
213                }
214            }
215
216            ::fidl_next::wire::Table::encode_len(table, max_ord);
217
218            Ok(())
219        }
220    }
221
222    impl<'de> ::fidl_next::FromWire<crate::wire::WlanPhyImplInitRequest<'de>>
223        for WlanPhyImplInitRequest
224    {
225        #[inline]
226        fn from_wire(wire_: crate::wire::WlanPhyImplInitRequest<'de>) -> Self {
227            let wire_ = ::core::mem::ManuallyDrop::new(wire_);
228
229            let notify_client = wire_.table.get(1);
230
231            Self {
232                notify_client: notify_client.map(|envelope| {
233                    ::fidl_next::FromWire::from_wire(unsafe {
234                        envelope.read_unchecked::<::fidl_next::ClientEnd<
235                            crate::WlanPhyImplNotify,
236                            ::fidl_next::wire::fuchsia::Channel,
237                        >>()
238                    })
239                }),
240            }
241        }
242    }
243}
244
245pub mod wire {
246
247    pub use fidl_next_common_fuchsia_wlan_phyimpl::wire::*;
248
249    /// The wire type corresponding to [`WlanPhyImplCreateIfaceRequest`].
250    #[repr(C)]
251    pub struct WlanPhyImplCreateIfaceRequest<'de> {
252        pub(crate) table: ::fidl_next::wire::Table<'de>,
253    }
254
255    impl<'de> Drop for WlanPhyImplCreateIfaceRequest<'de> {
256        fn drop(&mut self) {
257            let _ = self.table.get(1).map(|envelope| unsafe {
258                envelope.read_unchecked::<::fidl_next_fuchsia_wlan_common::wire::WlanMacRole>()
259            });
260
261            let _ = self.table.get(2).map(|envelope| unsafe {
262                envelope.read_unchecked::<::fidl_next::wire::fuchsia::Channel>()
263            });
264
265            let _ =
266                self.table.get(3).map(|envelope| unsafe { envelope.read_unchecked::<[u8; 6]>() });
267        }
268    }
269
270    impl ::fidl_next::Constrained for WlanPhyImplCreateIfaceRequest<'_> {
271        type Constraint = ();
272
273        fn validate(
274            _: ::fidl_next::Slot<'_, Self>,
275            _: Self::Constraint,
276        ) -> Result<(), ::fidl_next::ValidationError> {
277            Ok(())
278        }
279    }
280
281    unsafe impl ::fidl_next::Wire for WlanPhyImplCreateIfaceRequest<'static> {
282        type Narrowed<'de> = WlanPhyImplCreateIfaceRequest<'de>;
283
284        #[inline]
285        fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
286            ::fidl_next::munge!(let Self { table } = out);
287            ::fidl_next::wire::Table::zero_padding(table);
288        }
289    }
290
291    unsafe impl<'de, ___D> ::fidl_next::Decode<___D> for WlanPhyImplCreateIfaceRequest<'de>
292    where
293        ___D: ::fidl_next::Decoder<'de> + ?Sized,
294        ___D: ::fidl_next::fuchsia::HandleDecoder,
295    {
296        fn decode(
297            slot: ::fidl_next::Slot<'_, Self>,
298            decoder: &mut ___D,
299            _: (),
300        ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
301            ::fidl_next::munge!(let Self { table } = slot);
302
303            ::fidl_next::wire::Table::decode_with(table, decoder, |ordinal, mut slot, decoder| {
304                match ordinal {
305                    0 => unsafe { ::core::hint::unreachable_unchecked() },
306
307                    1 => {
308                        ::fidl_next::wire::Envelope::decode_as::<
309                            ___D,
310                            ::fidl_next_fuchsia_wlan_common::wire::WlanMacRole,
311                        >(slot.as_mut(), decoder, ())?;
312
313                        Ok(())
314                    }
315
316                    2 => {
317                        ::fidl_next::wire::Envelope::decode_as::<
318                            ___D,
319                            ::fidl_next::wire::fuchsia::Channel,
320                        >(slot.as_mut(), decoder, ())?;
321
322                        Ok(())
323                    }
324
325                    3 => {
326                        ::fidl_next::wire::Envelope::decode_as::<___D, [u8; 6]>(
327                            slot.as_mut(),
328                            decoder,
329                            (),
330                        )?;
331
332                        Ok(())
333                    }
334
335                    _ => ::fidl_next::wire::Envelope::decode_unknown(slot, decoder),
336                }
337            })
338        }
339    }
340
341    impl<'de> WlanPhyImplCreateIfaceRequest<'de> {
342        pub fn role(
343            &self,
344        ) -> ::core::option::Option<&::fidl_next_fuchsia_wlan_common::wire::WlanMacRole> {
345            unsafe { Some(self.table.get(1)?.deref_unchecked()) }
346        }
347
348        pub fn take_role(
349            &mut self,
350        ) -> ::core::option::Option<::fidl_next_fuchsia_wlan_common::wire::WlanMacRole> {
351            unsafe { Some(self.table.get_mut(1)?.take_unchecked()) }
352        }
353
354        pub fn mlme_channel(&self) -> ::core::option::Option<&::fidl_next::wire::fuchsia::Channel> {
355            unsafe { Some(self.table.get(2)?.deref_unchecked()) }
356        }
357
358        pub fn take_mlme_channel(
359            &mut self,
360        ) -> ::core::option::Option<::fidl_next::wire::fuchsia::Channel> {
361            unsafe { Some(self.table.get_mut(2)?.take_unchecked()) }
362        }
363
364        pub fn init_sta_addr(&self) -> ::core::option::Option<&[u8; 6]> {
365            unsafe { Some(self.table.get(3)?.deref_unchecked()) }
366        }
367
368        pub fn take_init_sta_addr(&mut self) -> ::core::option::Option<[u8; 6]> {
369            unsafe { Some(self.table.get_mut(3)?.take_unchecked()) }
370        }
371    }
372
373    impl<'de> ::core::fmt::Debug for WlanPhyImplCreateIfaceRequest<'de> {
374        fn fmt(
375            &self,
376            f: &mut ::core::fmt::Formatter<'_>,
377        ) -> ::core::result::Result<(), ::core::fmt::Error> {
378            f.debug_struct("WlanPhyImplCreateIfaceRequest")
379                .field("role", &self.role())
380                .field("mlme_channel", &self.mlme_channel())
381                .field("init_sta_addr", &self.init_sta_addr())
382                .finish()
383        }
384    }
385
386    impl<'de> ::fidl_next::IntoNatural for WlanPhyImplCreateIfaceRequest<'de> {
387        type Natural = crate::natural::WlanPhyImplCreateIfaceRequest;
388    }
389
390    /// The wire type corresponding to [`WlanPhyImplInitRequest`].
391    #[repr(C)]
392    pub struct WlanPhyImplInitRequest<'de> {
393        pub(crate) table: ::fidl_next::wire::Table<'de>,
394    }
395
396    impl<'de> Drop for WlanPhyImplInitRequest<'de> {
397        fn drop(&mut self) {
398            let _ = self.table.get(1).map(|envelope| unsafe {
399                envelope.read_unchecked::<::fidl_next::ClientEnd<
400                    crate::WlanPhyImplNotify,
401                    ::fidl_next::wire::fuchsia::Channel,
402                >>()
403            });
404        }
405    }
406
407    impl ::fidl_next::Constrained for WlanPhyImplInitRequest<'_> {
408        type Constraint = ();
409
410        fn validate(
411            _: ::fidl_next::Slot<'_, Self>,
412            _: Self::Constraint,
413        ) -> Result<(), ::fidl_next::ValidationError> {
414            Ok(())
415        }
416    }
417
418    unsafe impl ::fidl_next::Wire for WlanPhyImplInitRequest<'static> {
419        type Narrowed<'de> = WlanPhyImplInitRequest<'de>;
420
421        #[inline]
422        fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
423            ::fidl_next::munge!(let Self { table } = out);
424            ::fidl_next::wire::Table::zero_padding(table);
425        }
426    }
427
428    unsafe impl<'de, ___D> ::fidl_next::Decode<___D> for WlanPhyImplInitRequest<'de>
429    where
430        ___D: ::fidl_next::Decoder<'de> + ?Sized,
431        ___D: ::fidl_next::fuchsia::HandleDecoder,
432    {
433        fn decode(
434            slot: ::fidl_next::Slot<'_, Self>,
435            decoder: &mut ___D,
436            _: (),
437        ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
438            ::fidl_next::munge!(let Self { table } = slot);
439
440            ::fidl_next::wire::Table::decode_with(table, decoder, |ordinal, mut slot, decoder| {
441                match ordinal {
442                    0 => unsafe { ::core::hint::unreachable_unchecked() },
443
444                    1 => {
445                        ::fidl_next::wire::Envelope::decode_as::<
446                            ___D,
447                            ::fidl_next::ClientEnd<
448                                crate::WlanPhyImplNotify,
449                                ::fidl_next::wire::fuchsia::Channel,
450                            >,
451                        >(slot.as_mut(), decoder, ())?;
452
453                        Ok(())
454                    }
455
456                    _ => ::fidl_next::wire::Envelope::decode_unknown(slot, decoder),
457                }
458            })
459        }
460    }
461
462    impl<'de> WlanPhyImplInitRequest<'de> {
463        pub fn notify_client(
464            &self,
465        ) -> ::core::option::Option<
466            &::fidl_next::ClientEnd<crate::WlanPhyImplNotify, ::fidl_next::wire::fuchsia::Channel>,
467        > {
468            unsafe { Some(self.table.get(1)?.deref_unchecked()) }
469        }
470
471        pub fn take_notify_client(
472            &mut self,
473        ) -> ::core::option::Option<
474            ::fidl_next::ClientEnd<crate::WlanPhyImplNotify, ::fidl_next::wire::fuchsia::Channel>,
475        > {
476            unsafe { Some(self.table.get_mut(1)?.take_unchecked()) }
477        }
478    }
479
480    impl<'de> ::core::fmt::Debug for WlanPhyImplInitRequest<'de> {
481        fn fmt(
482            &self,
483            f: &mut ::core::fmt::Formatter<'_>,
484        ) -> ::core::result::Result<(), ::core::fmt::Error> {
485            f.debug_struct("WlanPhyImplInitRequest")
486                .field("notify_client", &self.notify_client())
487                .finish()
488        }
489    }
490
491    impl<'de> ::fidl_next::IntoNatural for WlanPhyImplInitRequest<'de> {
492        type Natural = crate::natural::WlanPhyImplInitRequest;
493    }
494}
495
496pub mod wire_optional {
497
498    pub use fidl_next_common_fuchsia_wlan_phyimpl::wire_optional::*;
499}
500
501pub mod generic {
502
503    pub use fidl_next_common_fuchsia_wlan_phyimpl::generic::*;
504}
505
506pub use self::natural::*;
507
508/// The type corresponding to the Service service.
509#[derive(Debug)]
510pub struct Service;
511
512impl ::fidl_next::DiscoverableService for Service {
513    const SERVICE_NAME: &'static str = "fuchsia.wlan.phyimpl.Service";
514    const MEMBER_NAMES: &'static [&'static str] = &["wlan_phy_impl"];
515}
516
517impl ::fidl_next::HasServiceRequest<::fdf_fidl::DriverChannel> for Service {}
518
519impl<___C> ::fidl_next::Service<___C> for Service
520where
521    ___C: ::fidl_next::protocol::ServiceConnector<::fdf_fidl::DriverChannel>,
522{
523    type Connector = ServiceConnector<___C>;
524}
525
526/// A strongly-typed service connector for the `Service` service.
527#[repr(transparent)]
528pub struct ServiceConnector<___C> {
529    #[allow(dead_code)]
530    connector: ___C,
531}
532
533impl<___C> ServiceConnector<___C>
534where
535    ___C: ::fidl_next::protocol::ServiceConnector<::fdf_fidl::DriverChannel>,
536{
537    /// Attempts to connect to the `wlan_phy_impl` service member.
538    pub fn wlan_phy_impl(
539        &self,
540        server_end: ::fidl_next::ServerEnd<crate::WlanPhyImpl, ::fdf_fidl::DriverChannel>,
541    ) -> ::core::result::Result<
542        (),
543        <___C as ::fidl_next::protocol::ServiceConnector<::fdf_fidl::DriverChannel>>::Error,
544    > {
545        ::fidl_next::protocol::ServiceConnector::<::fdf_fidl::DriverChannel>::connect_to_member(
546            &self.connector,
547            "wlan_phy_impl",
548            server_end.into_untyped(),
549        )
550    }
551}
552
553/// A service handler for the `Service` service.
554pub trait ServiceHandler {
555    /// Handles an attempt to connect to the `wlan_phy_impl` member.
556    fn wlan_phy_impl(
557        &self,
558        server_end: ::fidl_next::ServerEnd<crate::WlanPhyImpl, ::fdf_fidl::DriverChannel>,
559    );
560}
561
562impl<___H, ___T> ::fidl_next::DispatchServiceHandler<___H, ___T> for Service
563where
564    ___H: ServiceHandler,
565    ::fdf_fidl::DriverChannel: ::fidl_next::InstanceFromServiceTransport<___T>,
566{
567    fn on_connection(handler: &___H, member: &str, server_end: ___T) {
568        use ::fidl_next::InstanceFromServiceTransport;
569        match member {
570            "wlan_phy_impl" => handler.wlan_phy_impl(::fidl_next::ServerEnd::from_untyped(
571                ::fdf_fidl::DriverChannel::from_service_transport(server_end),
572            )),
573
574            _ => unreachable!(),
575        }
576    }
577}
578
579/// The type corresponding to the WlanPhyImpl protocol.
580#[derive(PartialEq, Debug)]
581pub struct WlanPhyImpl;
582
583impl ::fidl_next::Discoverable for WlanPhyImpl {
584    const PROTOCOL_NAME: &'static str = "fuchsia.wlan.phyimpl.WlanPhyImpl";
585}
586
587#[cfg(feature = "driver")]
588impl ::fidl_next::HasTransport for WlanPhyImpl {
589    type Transport = ::fdf_fidl::DriverChannel;
590}
591
592pub mod wlan_phy_impl {
593    pub mod prelude {
594        pub use crate::{
595            WlanPhyImpl, WlanPhyImplClientHandler, WlanPhyImplLocalClientHandler,
596            WlanPhyImplLocalServerHandler, WlanPhyImplServerHandler, wlan_phy_impl,
597        };
598
599        pub use crate::natural::WlanPhyCountry;
600
601        pub use crate::natural::WlanPhyImplCreateIfaceRequest;
602
603        pub use crate::natural::WlanPhyImplDestroyIfaceRequest;
604
605        pub use crate::natural::WlanPhyImplInitRequest;
606
607        pub use crate::natural::WlanPhyImplSetBtCoexistenceModeRequest;
608
609        pub use crate::natural::WlanPhyImplSetPowerSaveModeRequest;
610
611        pub use crate::natural::WlanPhyImplSetTxPowerScenarioRequest;
612
613        pub use crate::natural::WlanPhyImplClearCountryResponse;
614
615        pub use crate::natural::WlanPhyImplCreateIfaceResponse;
616
617        pub use crate::natural::WlanPhyImplDestroyIfaceResponse;
618
619        pub use crate::natural::WlanPhyImplGetPowerSaveModeResponse;
620
621        pub use crate::natural::WlanPhyImplGetPowerStateResponse;
622
623        pub use crate::natural::WlanPhyImplGetSupportedMacRolesResponse;
624
625        pub use crate::natural::WlanPhyImplGetTxPowerScenarioResponse;
626
627        pub use crate::natural::WlanPhyImplInitResponse;
628
629        pub use crate::natural::WlanPhyImplPowerDownResponse;
630
631        pub use crate::natural::WlanPhyImplPowerUpResponse;
632
633        pub use crate::natural::WlanPhyImplResetTxPowerScenarioResponse;
634
635        pub use crate::natural::WlanPhyImplResetResponse;
636
637        pub use crate::natural::WlanPhyImplSetBtCoexistenceModeResponse;
638
639        pub use crate::natural::WlanPhyImplSetCountryResponse;
640
641        pub use crate::natural::WlanPhyImplSetPowerSaveModeResponse;
642
643        pub use crate::natural::WlanPhyImplSetTxPowerScenarioResponse;
644    }
645
646    pub struct Init;
647
648    impl ::fidl_next::Method for Init {
649        const ORDINAL: u64 = 7493583544655362892;
650        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
651            ::fidl_next::protocol::Flexibility::Flexible;
652
653        type Protocol = crate::WlanPhyImpl;
654
655        type Request = crate::wire::WlanPhyImplInitRequest<'static>;
656    }
657
658    impl ::fidl_next::TwoWayMethod for Init {
659        type Response = ::fidl_next::wire::Result<
660            'static,
661            crate::wire::WlanPhyImplInitResponse,
662            ::fidl_next::wire::fuchsia::Status,
663        >;
664    }
665
666    impl<___R> ::fidl_next::Respond<___R> for Init {
667        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
668
669        fn respond(response: ___R) -> Self::Output {
670            ::core::result::Result::Ok(response)
671        }
672    }
673
674    impl<___R> ::fidl_next::RespondErr<___R> for Init {
675        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
676
677        fn respond_err(response: ___R) -> Self::Output {
678            ::core::result::Result::Err(response)
679        }
680    }
681
682    pub struct GetSupportedMacRoles;
683
684    impl ::fidl_next::Method for GetSupportedMacRoles {
685        const ORDINAL: u64 = 6537800780977121793;
686        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
687            ::fidl_next::protocol::Flexibility::Flexible;
688
689        type Protocol = crate::WlanPhyImpl;
690
691        type Request = ::fidl_next::wire::EmptyMessageBody;
692    }
693
694    impl ::fidl_next::TwoWayMethod for GetSupportedMacRoles {
695        type Response = ::fidl_next::wire::Result<
696            'static,
697            crate::wire::WlanPhyImplGetSupportedMacRolesResponse<'static>,
698            ::fidl_next::wire::fuchsia::Status,
699        >;
700    }
701
702    impl<___R> ::fidl_next::Respond<___R> for GetSupportedMacRoles {
703        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
704
705        fn respond(response: ___R) -> Self::Output {
706            ::core::result::Result::Ok(response)
707        }
708    }
709
710    impl<___R> ::fidl_next::RespondErr<___R> for GetSupportedMacRoles {
711        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
712
713        fn respond_err(response: ___R) -> Self::Output {
714            ::core::result::Result::Err(response)
715        }
716    }
717
718    pub struct CreateIface;
719
720    impl ::fidl_next::Method for CreateIface {
721        const ORDINAL: u64 = 3653746094083836708;
722        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
723            ::fidl_next::protocol::Flexibility::Flexible;
724
725        type Protocol = crate::WlanPhyImpl;
726
727        type Request = crate::wire::WlanPhyImplCreateIfaceRequest<'static>;
728    }
729
730    impl ::fidl_next::TwoWayMethod for CreateIface {
731        type Response = ::fidl_next::wire::Result<
732            'static,
733            crate::wire::WlanPhyImplCreateIfaceResponse<'static>,
734            ::fidl_next::wire::fuchsia::Status,
735        >;
736    }
737
738    impl<___R> ::fidl_next::Respond<___R> for CreateIface {
739        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
740
741        fn respond(response: ___R) -> Self::Output {
742            ::core::result::Result::Ok(response)
743        }
744    }
745
746    impl<___R> ::fidl_next::RespondErr<___R> for CreateIface {
747        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
748
749        fn respond_err(response: ___R) -> Self::Output {
750            ::core::result::Result::Err(response)
751        }
752    }
753
754    pub struct DestroyIface;
755
756    impl ::fidl_next::Method for DestroyIface {
757        const ORDINAL: u64 = 4242398030717562286;
758        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
759            ::fidl_next::protocol::Flexibility::Flexible;
760
761        type Protocol = crate::WlanPhyImpl;
762
763        type Request = crate::wire::WlanPhyImplDestroyIfaceRequest<'static>;
764    }
765
766    impl ::fidl_next::TwoWayMethod for DestroyIface {
767        type Response = ::fidl_next::wire::Result<
768            'static,
769            crate::wire::WlanPhyImplDestroyIfaceResponse,
770            ::fidl_next::wire::fuchsia::Status,
771        >;
772    }
773
774    impl<___R> ::fidl_next::Respond<___R> for DestroyIface {
775        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
776
777        fn respond(response: ___R) -> Self::Output {
778            ::core::result::Result::Ok(response)
779        }
780    }
781
782    impl<___R> ::fidl_next::RespondErr<___R> for DestroyIface {
783        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
784
785        fn respond_err(response: ___R) -> Self::Output {
786            ::core::result::Result::Err(response)
787        }
788    }
789
790    pub struct SetCountry;
791
792    impl ::fidl_next::Method for SetCountry {
793        const ORDINAL: u64 = 8612397810323877864;
794        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
795            ::fidl_next::protocol::Flexibility::Flexible;
796
797        type Protocol = crate::WlanPhyImpl;
798
799        type Request = crate::wire::WlanPhyCountry<'static>;
800    }
801
802    impl ::fidl_next::TwoWayMethod for SetCountry {
803        type Response = ::fidl_next::wire::Result<
804            'static,
805            crate::wire::WlanPhyImplSetCountryResponse,
806            ::fidl_next::wire::fuchsia::Status,
807        >;
808    }
809
810    impl<___R> ::fidl_next::Respond<___R> for SetCountry {
811        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
812
813        fn respond(response: ___R) -> Self::Output {
814            ::core::result::Result::Ok(response)
815        }
816    }
817
818    impl<___R> ::fidl_next::RespondErr<___R> for SetCountry {
819        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
820
821        fn respond_err(response: ___R) -> Self::Output {
822            ::core::result::Result::Err(response)
823        }
824    }
825
826    pub struct ClearCountry;
827
828    impl ::fidl_next::Method for ClearCountry {
829        const ORDINAL: u64 = 7385017681971907294;
830        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
831            ::fidl_next::protocol::Flexibility::Flexible;
832
833        type Protocol = crate::WlanPhyImpl;
834
835        type Request = ::fidl_next::wire::EmptyMessageBody;
836    }
837
838    impl ::fidl_next::TwoWayMethod for ClearCountry {
839        type Response = ::fidl_next::wire::Result<
840            'static,
841            crate::wire::WlanPhyImplClearCountryResponse,
842            ::fidl_next::wire::fuchsia::Status,
843        >;
844    }
845
846    impl<___R> ::fidl_next::Respond<___R> for ClearCountry {
847        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
848
849        fn respond(response: ___R) -> Self::Output {
850            ::core::result::Result::Ok(response)
851        }
852    }
853
854    impl<___R> ::fidl_next::RespondErr<___R> for ClearCountry {
855        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
856
857        fn respond_err(response: ___R) -> Self::Output {
858            ::core::result::Result::Err(response)
859        }
860    }
861
862    pub struct GetCountry;
863
864    impl ::fidl_next::Method for GetCountry {
865        const ORDINAL: u64 = 504898287153653553;
866        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
867            ::fidl_next::protocol::Flexibility::Flexible;
868
869        type Protocol = crate::WlanPhyImpl;
870
871        type Request = ::fidl_next::wire::EmptyMessageBody;
872    }
873
874    impl ::fidl_next::TwoWayMethod for GetCountry {
875        type Response = ::fidl_next::wire::Result<
876            'static,
877            crate::wire::WlanPhyCountry<'static>,
878            ::fidl_next::wire::fuchsia::Status,
879        >;
880    }
881
882    impl<___R> ::fidl_next::Respond<___R> for GetCountry {
883        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
884
885        fn respond(response: ___R) -> Self::Output {
886            ::core::result::Result::Ok(response)
887        }
888    }
889
890    impl<___R> ::fidl_next::RespondErr<___R> for GetCountry {
891        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
892
893        fn respond_err(response: ___R) -> Self::Output {
894            ::core::result::Result::Err(response)
895        }
896    }
897
898    pub struct SetPowerSaveMode;
899
900    impl ::fidl_next::Method for SetPowerSaveMode {
901        const ORDINAL: u64 = 5294377936487508532;
902        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
903            ::fidl_next::protocol::Flexibility::Flexible;
904
905        type Protocol = crate::WlanPhyImpl;
906
907        type Request = crate::wire::WlanPhyImplSetPowerSaveModeRequest<'static>;
908    }
909
910    impl ::fidl_next::TwoWayMethod for SetPowerSaveMode {
911        type Response = ::fidl_next::wire::Result<
912            'static,
913            crate::wire::WlanPhyImplSetPowerSaveModeResponse,
914            ::fidl_next::wire::fuchsia::Status,
915        >;
916    }
917
918    impl<___R> ::fidl_next::Respond<___R> for SetPowerSaveMode {
919        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
920
921        fn respond(response: ___R) -> Self::Output {
922            ::core::result::Result::Ok(response)
923        }
924    }
925
926    impl<___R> ::fidl_next::RespondErr<___R> for SetPowerSaveMode {
927        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
928
929        fn respond_err(response: ___R) -> Self::Output {
930            ::core::result::Result::Err(response)
931        }
932    }
933
934    pub struct GetPowerSaveMode;
935
936    impl ::fidl_next::Method for GetPowerSaveMode {
937        const ORDINAL: u64 = 1249843465564268342;
938        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
939            ::fidl_next::protocol::Flexibility::Flexible;
940
941        type Protocol = crate::WlanPhyImpl;
942
943        type Request = ::fidl_next::wire::EmptyMessageBody;
944    }
945
946    impl ::fidl_next::TwoWayMethod for GetPowerSaveMode {
947        type Response = ::fidl_next::wire::Result<
948            'static,
949            crate::wire::WlanPhyImplGetPowerSaveModeResponse<'static>,
950            ::fidl_next::wire::fuchsia::Status,
951        >;
952    }
953
954    impl<___R> ::fidl_next::Respond<___R> for GetPowerSaveMode {
955        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
956
957        fn respond(response: ___R) -> Self::Output {
958            ::core::result::Result::Ok(response)
959        }
960    }
961
962    impl<___R> ::fidl_next::RespondErr<___R> for GetPowerSaveMode {
963        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
964
965        fn respond_err(response: ___R) -> Self::Output {
966            ::core::result::Result::Err(response)
967        }
968    }
969
970    pub struct PowerDown;
971
972    impl ::fidl_next::Method for PowerDown {
973        const ORDINAL: u64 = 7270381901916338537;
974        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
975            ::fidl_next::protocol::Flexibility::Flexible;
976
977        type Protocol = crate::WlanPhyImpl;
978
979        type Request = ::fidl_next::wire::EmptyMessageBody;
980    }
981
982    impl ::fidl_next::TwoWayMethod for PowerDown {
983        type Response = ::fidl_next::wire::Result<
984            'static,
985            crate::wire::WlanPhyImplPowerDownResponse,
986            ::fidl_next::wire::fuchsia::Status,
987        >;
988    }
989
990    impl<___R> ::fidl_next::Respond<___R> for PowerDown {
991        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
992
993        fn respond(response: ___R) -> Self::Output {
994            ::core::result::Result::Ok(response)
995        }
996    }
997
998    impl<___R> ::fidl_next::RespondErr<___R> for PowerDown {
999        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
1000
1001        fn respond_err(response: ___R) -> Self::Output {
1002            ::core::result::Result::Err(response)
1003        }
1004    }
1005
1006    pub struct PowerUp;
1007
1008    impl ::fidl_next::Method for PowerUp {
1009        const ORDINAL: u64 = 3906021304522780285;
1010        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
1011            ::fidl_next::protocol::Flexibility::Flexible;
1012
1013        type Protocol = crate::WlanPhyImpl;
1014
1015        type Request = ::fidl_next::wire::EmptyMessageBody;
1016    }
1017
1018    impl ::fidl_next::TwoWayMethod for PowerUp {
1019        type Response = ::fidl_next::wire::Result<
1020            'static,
1021            crate::wire::WlanPhyImplPowerUpResponse,
1022            ::fidl_next::wire::fuchsia::Status,
1023        >;
1024    }
1025
1026    impl<___R> ::fidl_next::Respond<___R> for PowerUp {
1027        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
1028
1029        fn respond(response: ___R) -> Self::Output {
1030            ::core::result::Result::Ok(response)
1031        }
1032    }
1033
1034    impl<___R> ::fidl_next::RespondErr<___R> for PowerUp {
1035        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
1036
1037        fn respond_err(response: ___R) -> Self::Output {
1038            ::core::result::Result::Err(response)
1039        }
1040    }
1041
1042    pub struct Reset;
1043
1044    impl ::fidl_next::Method for Reset {
1045        const ORDINAL: u64 = 2042885235926298203;
1046        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
1047            ::fidl_next::protocol::Flexibility::Flexible;
1048
1049        type Protocol = crate::WlanPhyImpl;
1050
1051        type Request = ::fidl_next::wire::EmptyMessageBody;
1052    }
1053
1054    impl ::fidl_next::TwoWayMethod for Reset {
1055        type Response = ::fidl_next::wire::Result<
1056            'static,
1057            crate::wire::WlanPhyImplResetResponse,
1058            ::fidl_next::wire::fuchsia::Status,
1059        >;
1060    }
1061
1062    impl<___R> ::fidl_next::Respond<___R> for Reset {
1063        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
1064
1065        fn respond(response: ___R) -> Self::Output {
1066            ::core::result::Result::Ok(response)
1067        }
1068    }
1069
1070    impl<___R> ::fidl_next::RespondErr<___R> for Reset {
1071        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
1072
1073        fn respond_err(response: ___R) -> Self::Output {
1074            ::core::result::Result::Err(response)
1075        }
1076    }
1077
1078    pub struct GetPowerState;
1079
1080    impl ::fidl_next::Method for GetPowerState {
1081        const ORDINAL: u64 = 1120466226693084492;
1082        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
1083            ::fidl_next::protocol::Flexibility::Flexible;
1084
1085        type Protocol = crate::WlanPhyImpl;
1086
1087        type Request = ::fidl_next::wire::EmptyMessageBody;
1088    }
1089
1090    impl ::fidl_next::TwoWayMethod for GetPowerState {
1091        type Response = ::fidl_next::wire::Result<
1092            'static,
1093            crate::wire::WlanPhyImplGetPowerStateResponse<'static>,
1094            ::fidl_next::wire::fuchsia::Status,
1095        >;
1096    }
1097
1098    impl<___R> ::fidl_next::Respond<___R> for GetPowerState {
1099        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
1100
1101        fn respond(response: ___R) -> Self::Output {
1102            ::core::result::Result::Ok(response)
1103        }
1104    }
1105
1106    impl<___R> ::fidl_next::RespondErr<___R> for GetPowerState {
1107        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
1108
1109        fn respond_err(response: ___R) -> Self::Output {
1110            ::core::result::Result::Err(response)
1111        }
1112    }
1113
1114    pub struct SetBtCoexistenceMode;
1115
1116    impl ::fidl_next::Method for SetBtCoexistenceMode {
1117        const ORDINAL: u64 = 3276312011165605259;
1118        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
1119            ::fidl_next::protocol::Flexibility::Flexible;
1120
1121        type Protocol = crate::WlanPhyImpl;
1122
1123        type Request = crate::wire::WlanPhyImplSetBtCoexistenceModeRequest<'static>;
1124    }
1125
1126    impl ::fidl_next::TwoWayMethod for SetBtCoexistenceMode {
1127        type Response = ::fidl_next::wire::Result<
1128            'static,
1129            crate::wire::WlanPhyImplSetBtCoexistenceModeResponse,
1130            ::fidl_next::wire::fuchsia::Status,
1131        >;
1132    }
1133
1134    impl<___R> ::fidl_next::Respond<___R> for SetBtCoexistenceMode {
1135        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
1136
1137        fn respond(response: ___R) -> Self::Output {
1138            ::core::result::Result::Ok(response)
1139        }
1140    }
1141
1142    impl<___R> ::fidl_next::RespondErr<___R> for SetBtCoexistenceMode {
1143        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
1144
1145        fn respond_err(response: ___R) -> Self::Output {
1146            ::core::result::Result::Err(response)
1147        }
1148    }
1149
1150    pub struct SetTxPowerScenario;
1151
1152    impl ::fidl_next::Method for SetTxPowerScenario {
1153        const ORDINAL: u64 = 698995794200761402;
1154        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
1155            ::fidl_next::protocol::Flexibility::Flexible;
1156
1157        type Protocol = crate::WlanPhyImpl;
1158
1159        type Request = crate::wire::WlanPhyImplSetTxPowerScenarioRequest<'static>;
1160    }
1161
1162    impl ::fidl_next::TwoWayMethod for SetTxPowerScenario {
1163        type Response = ::fidl_next::wire::Result<
1164            'static,
1165            crate::wire::WlanPhyImplSetTxPowerScenarioResponse,
1166            ::fidl_next::wire::fuchsia::Status,
1167        >;
1168    }
1169
1170    impl<___R> ::fidl_next::Respond<___R> for SetTxPowerScenario {
1171        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
1172
1173        fn respond(response: ___R) -> Self::Output {
1174            ::core::result::Result::Ok(response)
1175        }
1176    }
1177
1178    impl<___R> ::fidl_next::RespondErr<___R> for SetTxPowerScenario {
1179        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
1180
1181        fn respond_err(response: ___R) -> Self::Output {
1182            ::core::result::Result::Err(response)
1183        }
1184    }
1185
1186    pub struct ResetTxPowerScenario;
1187
1188    impl ::fidl_next::Method for ResetTxPowerScenario {
1189        const ORDINAL: u64 = 5600588310235871255;
1190        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
1191            ::fidl_next::protocol::Flexibility::Flexible;
1192
1193        type Protocol = crate::WlanPhyImpl;
1194
1195        type Request = ::fidl_next::wire::EmptyMessageBody;
1196    }
1197
1198    impl ::fidl_next::TwoWayMethod for ResetTxPowerScenario {
1199        type Response = ::fidl_next::wire::Result<
1200            'static,
1201            crate::wire::WlanPhyImplResetTxPowerScenarioResponse,
1202            ::fidl_next::wire::fuchsia::Status,
1203        >;
1204    }
1205
1206    impl<___R> ::fidl_next::Respond<___R> for ResetTxPowerScenario {
1207        type Output = ::core::result::Result<___R, ::fidl_next::never::Never>;
1208
1209        fn respond(response: ___R) -> Self::Output {
1210            ::core::result::Result::Ok(response)
1211        }
1212    }
1213
1214    impl<___R> ::fidl_next::RespondErr<___R> for ResetTxPowerScenario {
1215        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
1216
1217        fn respond_err(response: ___R) -> Self::Output {
1218            ::core::result::Result::Err(response)
1219        }
1220    }
1221
1222    pub struct GetTxPowerScenario;
1223
1224    impl ::fidl_next::Method for GetTxPowerScenario {
1225        const ORDINAL: u64 = 1236513198957883974;
1226        const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
1227            ::fidl_next::protocol::Flexibility::Flexible;
1228
1229        type Protocol = crate::WlanPhyImpl;
1230
1231        type Request = ::fidl_next::wire::EmptyMessageBody;
1232    }
1233
1234    impl ::fidl_next::TwoWayMethod for GetTxPowerScenario {
1235        type Response = ::fidl_next::wire::Result<
1236            'static,
1237            crate::wire::WlanPhyImplGetTxPowerScenarioResponse,
1238            ::fidl_next::wire::fuchsia::Status,
1239        >;
1240    }
1241
1242    impl<___R> ::fidl_next::Respond<___R> for GetTxPowerScenario {
1243        type Output = ::core::result::Result<
1244            crate::generic::WlanPhyImplGetTxPowerScenarioResponse<___R>,
1245            ::fidl_next::never::Never,
1246        >;
1247
1248        fn respond(response: ___R) -> Self::Output {
1249            ::core::result::Result::Ok(crate::generic::WlanPhyImplGetTxPowerScenarioResponse {
1250                scenario: response,
1251            })
1252        }
1253    }
1254
1255    impl<___R> ::fidl_next::RespondErr<___R> for GetTxPowerScenario {
1256        type Output = ::core::result::Result<::fidl_next::never::Never, ___R>;
1257
1258        fn respond_err(response: ___R) -> Self::Output {
1259            ::core::result::Result::Err(response)
1260        }
1261    }
1262
1263    mod ___detail {
1264        unsafe impl<___T> ::fidl_next::HasConnectionHandles<___T> for crate::WlanPhyImpl
1265        where
1266            ___T: ::fidl_next::Transport,
1267        {
1268            type Client = WlanPhyImplClient<___T>;
1269            type Server = WlanPhyImplServer<___T>;
1270        }
1271
1272        /// The client for the `WlanPhyImpl` protocol.
1273        #[repr(transparent)]
1274        pub struct WlanPhyImplClient<___T: ::fidl_next::Transport> {
1275            #[allow(dead_code)]
1276            client: ::fidl_next::protocol::Client<___T>,
1277        }
1278
1279        impl<___T> WlanPhyImplClient<___T>
1280        where
1281            ___T: ::fidl_next::Transport,
1282        {
1283            #[doc = " This method can be used by the WlanPhyImpl client to send the client end of the\n WlanPhyImplNotify endpoint for the WlanPhyImpl server to use. If the WlanPhyImpl client\n never invokes this method that is an indirect implication that the WlanPhyImplNotify is not\n supported. Some possible error codes are:\n ZX_ERR_NOT_SUPPORTED: The WlanPhyImpl server does not support the WlanPhyImplNotify protocol.\n"]
1284            pub fn init_with<___R>(
1285                &self,
1286                request: ___R,
1287            ) -> ::fidl_next::TwoWayFuture<'_, super::Init, ___T>
1288            where
1289                ___R: ::fidl_next::Encode<
1290                        crate::wire::WlanPhyImplInitRequest<'static>,
1291                        <___T as ::fidl_next::Transport>::SendBuffer,
1292                    >,
1293            {
1294                ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
1295                    7493583544655362892,
1296                    <super::Init as ::fidl_next::Method>::FLEXIBILITY,
1297                    request,
1298                ))
1299            }
1300
1301            #[doc = " MAC roles supported for ifaces on the physical device.\n"]
1302            pub fn get_supported_mac_roles(
1303                &self,
1304            ) -> ::fidl_next::TwoWayFuture<'_, super::GetSupportedMacRoles, ___T> {
1305                ::fidl_next::TwoWayFuture::from_untyped(
1306                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1307                        6537800780977121793,
1308                        <super::GetSupportedMacRoles as ::fidl_next::Method>::FLEXIBILITY,
1309                        (),
1310                    ),
1311                )
1312            }
1313
1314            #[doc = " Create a new interface with the specified role, returning the interface id. \\\n Some common error codes are: \\\n ZX_ERR_NO_RESOURCES: maximum number of interfaces have already been created. \\\n ZX_ERR_NOT_SUPPORTED: device does not support the specified role.\n"]
1315            pub fn create_iface_with<___R>(
1316                &self,
1317                request: ___R,
1318            ) -> ::fidl_next::TwoWayFuture<'_, super::CreateIface, ___T>
1319            where
1320                ___R: ::fidl_next::Encode<
1321                        crate::wire::WlanPhyImplCreateIfaceRequest<'static>,
1322                        <___T as ::fidl_next::Transport>::SendBuffer,
1323                    >,
1324            {
1325                ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
1326                    3653746094083836708,
1327                    <super::CreateIface as ::fidl_next::Method>::FLEXIBILITY,
1328                    request,
1329                ))
1330            }
1331
1332            #[doc = " Destroy the interface with the matching id. \\\n Some common error codes are: \\\n ZX_ERR_NOT_FOUND: Specified iface does not exist or has already been removed. \\\n ZX_ERR_SHOULD_WAIT: Device is busy and cannot be removed, try again later.\n"]
1333            pub fn destroy_iface_with<___R>(
1334                &self,
1335                request: ___R,
1336            ) -> ::fidl_next::TwoWayFuture<'_, super::DestroyIface, ___T>
1337            where
1338                ___R: ::fidl_next::Encode<
1339                        crate::wire::WlanPhyImplDestroyIfaceRequest<'static>,
1340                        <___T as ::fidl_next::Transport>::SendBuffer,
1341                    >,
1342            {
1343                ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
1344                    4242398030717562286,
1345                    <super::DestroyIface as ::fidl_next::Method>::FLEXIBILITY,
1346                    request,
1347                ))
1348            }
1349
1350            #[doc = " Set country with a WlanPhyCountry. \\\n Some common error codes are: \\\n ZX_ERR_NOT_FOUND: Specified country code not supported. PHY state is left unchanged.\n"]
1351            pub fn set_country_with<___R>(
1352                &self,
1353                request: ___R,
1354            ) -> ::fidl_next::TwoWayFuture<'_, super::SetCountry, ___T>
1355            where
1356                ___R: ::fidl_next::Encode<
1357                        crate::wire::WlanPhyCountry<'static>,
1358                        <___T as ::fidl_next::Transport>::SendBuffer,
1359                    >,
1360            {
1361                ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
1362                    8612397810323877864,
1363                    <super::SetCountry as ::fidl_next::Method>::FLEXIBILITY,
1364                    request,
1365                ))
1366            }
1367
1368            #[doc = " Set device to a world-safe country, i.e. a mode that conforms to all\n regulatory constraints globally. \\\n Generally expected to succeed if the device is in a functional state.\n"]
1369            pub fn clear_country(
1370                &self,
1371            ) -> ::fidl_next::TwoWayFuture<'_, super::ClearCountry, ___T> {
1372                ::fidl_next::TwoWayFuture::from_untyped(
1373                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1374                        7385017681971907294,
1375                        <super::ClearCountry as ::fidl_next::Method>::FLEXIBILITY,
1376                        (),
1377                    ),
1378                )
1379            }
1380
1381            #[doc = " Read currently configured country. Implementations are advised to read the\n country directly from the firmware, where possible. \\\n Generally expected to succeed if the device is in a functional state.\n"]
1382            pub fn get_country(&self) -> ::fidl_next::TwoWayFuture<'_, super::GetCountry, ___T> {
1383                ::fidl_next::TwoWayFuture::from_untyped(
1384                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1385                        504898287153653553,
1386                        <super::GetCountry as ::fidl_next::Method>::FLEXIBILITY,
1387                        (),
1388                    ),
1389                )
1390            }
1391
1392            #[doc = " Set Power Save mode on device. In most implementations this\n likely to be set in Firmware. \\\n Some common error codes are: \\\n ZX_ERR_NOT_SUPPORTED: Specified Power Save mode not supported.\n"]
1393            pub fn set_power_save_mode_with<___R>(
1394                &self,
1395                request: ___R,
1396            ) -> ::fidl_next::TwoWayFuture<'_, super::SetPowerSaveMode, ___T>
1397            where
1398                ___R: ::fidl_next::Encode<
1399                        crate::wire::WlanPhyImplSetPowerSaveModeRequest<'static>,
1400                        <___T as ::fidl_next::Transport>::SendBuffer,
1401                    >,
1402            {
1403                ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
1404                    5294377936487508532,
1405                    <super::SetPowerSaveMode as ::fidl_next::Method>::FLEXIBILITY,
1406                    request,
1407                ))
1408            }
1409
1410            #[doc = " Get current Power Save mode from device. In most implementation this\n likely to be retrieved from Firmware.\n"]
1411            pub fn get_power_save_mode(
1412                &self,
1413            ) -> ::fidl_next::TwoWayFuture<'_, super::GetPowerSaveMode, ___T> {
1414                ::fidl_next::TwoWayFuture::from_untyped(
1415                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1416                        1249843465564268342,
1417                        <super::GetPowerSaveMode as ::fidl_next::Method>::FLEXIBILITY,
1418                        (),
1419                    ),
1420                )
1421            }
1422
1423            #[doc = " Power up/down/reset the wlan chip.\n If supported, PowerDown will power down the wlan chip if it is currently powered on.\n Any existing interfaces should have already been deleted before making this call or else the\n driver will fail the call with error code ZX_ERR_INTERNAL.\n Other possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.\n ZX_ERR_BAD_STATE: the wlan chip is already powered down.\n"]
1424            pub fn power_down(&self) -> ::fidl_next::TwoWayFuture<'_, super::PowerDown, ___T> {
1425                ::fidl_next::TwoWayFuture::from_untyped(
1426                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1427                        7270381901916338537,
1428                        <super::PowerDown as ::fidl_next::Method>::FLEXIBILITY,
1429                        (),
1430                    ),
1431                )
1432            }
1433
1434            #[doc = " If supported, PowerUp will power up the wlan chip if it is currently powered down.\n Possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.\n ZX_ERR_BAD_STATE: the wlan chip is already powered up.\n"]
1435            pub fn power_up(&self) -> ::fidl_next::TwoWayFuture<'_, super::PowerUp, ___T> {
1436                ::fidl_next::TwoWayFuture::from_untyped(
1437                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1438                        3906021304522780285,
1439                        <super::PowerUp as ::fidl_next::Method>::FLEXIBILITY,
1440                        (),
1441                    ),
1442                )
1443            }
1444
1445            #[doc = " If supported, Reset functionality implements PowerDown then PowerUp in an attempt to\n recover from an error state. For example, if an interface gets into a bad state or if\n firmware crashes, the firmware/chip may be unable to perform some actions and Reset\n may be able to clear the bad state.\n Possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.\n"]
1446            pub fn reset(&self) -> ::fidl_next::TwoWayFuture<'_, super::Reset, ___T> {
1447                ::fidl_next::TwoWayFuture::from_untyped(
1448                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1449                        2042885235926298203,
1450                        <super::Reset as ::fidl_next::Method>::FLEXIBILITY,
1451                        (),
1452                    ),
1453                )
1454            }
1455
1456            #[doc = " Returns the current power state of the wlan chip. After successful initialization\n of the wlan driver, the state is set to true (power on) by default. power_on set to\n true indicates that the wlan chip is powered on and false indicates the wlan chip\n is powered off.\n"]
1457            pub fn get_power_state(
1458                &self,
1459            ) -> ::fidl_next::TwoWayFuture<'_, super::GetPowerState, ___T> {
1460                ::fidl_next::TwoWayFuture::from_untyped(
1461                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1462                        1120466226693084492,
1463                        <super::GetPowerState as ::fidl_next::Method>::FLEXIBILITY,
1464                        (),
1465                    ),
1466                )
1467            }
1468
1469            #[doc = " Set the Bluetooth coexistence mode.\n Possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: device does not support the specified BT coexistence mode.\n"]
1470            pub fn set_bt_coexistence_mode_with<___R>(
1471                &self,
1472                request: ___R,
1473            ) -> ::fidl_next::TwoWayFuture<'_, super::SetBtCoexistenceMode, ___T>
1474            where
1475                ___R: ::fidl_next::Encode<
1476                        crate::wire::WlanPhyImplSetBtCoexistenceModeRequest<'static>,
1477                        <___T as ::fidl_next::Transport>::SendBuffer,
1478                    >,
1479            {
1480                ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
1481                    3276312011165605259,
1482                    <super::SetBtCoexistenceMode as ::fidl_next::Method>::FLEXIBILITY,
1483                    request,
1484                ))
1485            }
1486
1487            pub fn set_tx_power_scenario_with<___R>(
1488                &self,
1489                request: ___R,
1490            ) -> ::fidl_next::TwoWayFuture<'_, super::SetTxPowerScenario, ___T>
1491            where
1492                ___R: ::fidl_next::Encode<
1493                        crate::wire::WlanPhyImplSetTxPowerScenarioRequest<'static>,
1494                        <___T as ::fidl_next::Transport>::SendBuffer,
1495                    >,
1496            {
1497                ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
1498                    698995794200761402,
1499                    <super::SetTxPowerScenario as ::fidl_next::Method>::FLEXIBILITY,
1500                    request,
1501                ))
1502            }
1503
1504            pub fn reset_tx_power_scenario(
1505                &self,
1506            ) -> ::fidl_next::TwoWayFuture<'_, super::ResetTxPowerScenario, ___T> {
1507                ::fidl_next::TwoWayFuture::from_untyped(
1508                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1509                        5600588310235871255,
1510                        <super::ResetTxPowerScenario as ::fidl_next::Method>::FLEXIBILITY,
1511                        (),
1512                    ),
1513                )
1514            }
1515
1516            pub fn get_tx_power_scenario(
1517                &self,
1518            ) -> ::fidl_next::TwoWayFuture<'_, super::GetTxPowerScenario, ___T> {
1519                ::fidl_next::TwoWayFuture::from_untyped(
1520                    self.client.send_two_way::<::fidl_next::wire::EmptyMessageBody>(
1521                        1236513198957883974,
1522                        <super::GetTxPowerScenario as ::fidl_next::Method>::FLEXIBILITY,
1523                        (),
1524                    ),
1525                )
1526            }
1527        }
1528
1529        /// The server for the `WlanPhyImpl` protocol.
1530        #[repr(transparent)]
1531        pub struct WlanPhyImplServer<___T: ::fidl_next::Transport> {
1532            server: ::fidl_next::protocol::Server<___T>,
1533        }
1534
1535        impl<___T> WlanPhyImplServer<___T> where ___T: ::fidl_next::Transport {}
1536    }
1537}
1538
1539#[diagnostic::on_unimplemented(
1540    note = "If {Self} implements the non-local WlanPhyImplClientHandler trait, use `spawn_as_local` or the `Local` adapter type"
1541)]
1542
1543/// A client handler for the WlanPhyImpl protocol.
1544///
1545/// See [`WlanPhyImpl`] for more details.
1546pub trait WlanPhyImplLocalClientHandler<
1547    #[cfg(feature = "driver")] ___T: ::fidl_next::Transport = ::fdf_fidl::DriverChannel,
1548    #[cfg(not(feature = "driver"))] ___T: ::fidl_next::Transport,
1549>
1550{
1551    fn on_unknown_interaction(&mut self, ordinal: u64) -> impl ::core::future::Future<Output = ()> {
1552        ::core::future::ready(())
1553    }
1554}
1555
1556impl<___H, ___T> ::fidl_next::DispatchLocalClientMessage<___H, ___T> for WlanPhyImpl
1557where
1558    ___H: WlanPhyImplLocalClientHandler<___T>,
1559    ___T: ::fidl_next::Transport,
1560{
1561    async fn on_event(
1562        handler: &mut ___H,
1563        mut message: ::fidl_next::Message<___T>,
1564    ) -> ::core::result::Result<(), ::fidl_next::ProtocolError<___T::Error>> {
1565        match *message.header().ordinal {
1566            ordinal => {
1567                handler.on_unknown_interaction(ordinal).await;
1568                if ::core::matches!(
1569                    message.header().flexibility(),
1570                    ::fidl_next::protocol::Flexibility::Strict
1571                ) {
1572                    Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
1573                } else {
1574                    Ok(())
1575                }
1576            }
1577        }
1578    }
1579}
1580
1581#[diagnostic::on_unimplemented(
1582    note = "If {Self} implements the non-local WlanPhyImplServerHandler trait, use `spawn_as_local` or the `Local` adapter type"
1583)]
1584
1585/// A server handler for the WlanPhyImpl protocol.
1586///
1587/// See [`WlanPhyImpl`] for more details.
1588pub trait WlanPhyImplLocalServerHandler<
1589    #[cfg(feature = "driver")] ___T: ::fidl_next::Transport = ::fdf_fidl::DriverChannel,
1590    #[cfg(not(feature = "driver"))] ___T: ::fidl_next::Transport,
1591>
1592{
1593    #[doc = " This method can be used by the WlanPhyImpl client to send the client end of the\n WlanPhyImplNotify endpoint for the WlanPhyImpl server to use. If the WlanPhyImpl client\n never invokes this method that is an indirect implication that the WlanPhyImplNotify is not\n supported. Some possible error codes are:\n ZX_ERR_NOT_SUPPORTED: The WlanPhyImpl server does not support the WlanPhyImplNotify protocol.\n"]
1594    fn init(
1595        &mut self,
1596
1597        request: ::fidl_next::Request<wlan_phy_impl::Init, ___T>,
1598
1599        responder: ::fidl_next::Responder<wlan_phy_impl::Init, ___T>,
1600    ) -> impl ::core::future::Future<Output = ()>;
1601
1602    #[doc = " MAC roles supported for ifaces on the physical device.\n"]
1603    fn get_supported_mac_roles(
1604        &mut self,
1605
1606        responder: ::fidl_next::Responder<wlan_phy_impl::GetSupportedMacRoles, ___T>,
1607    ) -> impl ::core::future::Future<Output = ()>;
1608
1609    #[doc = " Create a new interface with the specified role, returning the interface id. \\\n Some common error codes are: \\\n ZX_ERR_NO_RESOURCES: maximum number of interfaces have already been created. \\\n ZX_ERR_NOT_SUPPORTED: device does not support the specified role.\n"]
1610    fn create_iface(
1611        &mut self,
1612
1613        request: ::fidl_next::Request<wlan_phy_impl::CreateIface, ___T>,
1614
1615        responder: ::fidl_next::Responder<wlan_phy_impl::CreateIface, ___T>,
1616    ) -> impl ::core::future::Future<Output = ()>;
1617
1618    #[doc = " Destroy the interface with the matching id. \\\n Some common error codes are: \\\n ZX_ERR_NOT_FOUND: Specified iface does not exist or has already been removed. \\\n ZX_ERR_SHOULD_WAIT: Device is busy and cannot be removed, try again later.\n"]
1619    fn destroy_iface(
1620        &mut self,
1621
1622        request: ::fidl_next::Request<wlan_phy_impl::DestroyIface, ___T>,
1623
1624        responder: ::fidl_next::Responder<wlan_phy_impl::DestroyIface, ___T>,
1625    ) -> impl ::core::future::Future<Output = ()>;
1626
1627    #[doc = " Set country with a WlanPhyCountry. \\\n Some common error codes are: \\\n ZX_ERR_NOT_FOUND: Specified country code not supported. PHY state is left unchanged.\n"]
1628    fn set_country(
1629        &mut self,
1630
1631        request: ::fidl_next::Request<wlan_phy_impl::SetCountry, ___T>,
1632
1633        responder: ::fidl_next::Responder<wlan_phy_impl::SetCountry, ___T>,
1634    ) -> impl ::core::future::Future<Output = ()>;
1635
1636    #[doc = " Set device to a world-safe country, i.e. a mode that conforms to all\n regulatory constraints globally. \\\n Generally expected to succeed if the device is in a functional state.\n"]
1637    fn clear_country(
1638        &mut self,
1639
1640        responder: ::fidl_next::Responder<wlan_phy_impl::ClearCountry, ___T>,
1641    ) -> impl ::core::future::Future<Output = ()>;
1642
1643    #[doc = " Read currently configured country. Implementations are advised to read the\n country directly from the firmware, where possible. \\\n Generally expected to succeed if the device is in a functional state.\n"]
1644    fn get_country(
1645        &mut self,
1646
1647        responder: ::fidl_next::Responder<wlan_phy_impl::GetCountry, ___T>,
1648    ) -> impl ::core::future::Future<Output = ()>;
1649
1650    #[doc = " Set Power Save mode on device. In most implementations this\n likely to be set in Firmware. \\\n Some common error codes are: \\\n ZX_ERR_NOT_SUPPORTED: Specified Power Save mode not supported.\n"]
1651    fn set_power_save_mode(
1652        &mut self,
1653
1654        request: ::fidl_next::Request<wlan_phy_impl::SetPowerSaveMode, ___T>,
1655
1656        responder: ::fidl_next::Responder<wlan_phy_impl::SetPowerSaveMode, ___T>,
1657    ) -> impl ::core::future::Future<Output = ()>;
1658
1659    #[doc = " Get current Power Save mode from device. In most implementation this\n likely to be retrieved from Firmware.\n"]
1660    fn get_power_save_mode(
1661        &mut self,
1662
1663        responder: ::fidl_next::Responder<wlan_phy_impl::GetPowerSaveMode, ___T>,
1664    ) -> impl ::core::future::Future<Output = ()>;
1665
1666    #[doc = " Power up/down/reset the wlan chip.\n If supported, PowerDown will power down the wlan chip if it is currently powered on.\n Any existing interfaces should have already been deleted before making this call or else the\n driver will fail the call with error code ZX_ERR_INTERNAL.\n Other possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.\n ZX_ERR_BAD_STATE: the wlan chip is already powered down.\n"]
1667    fn power_down(
1668        &mut self,
1669
1670        responder: ::fidl_next::Responder<wlan_phy_impl::PowerDown, ___T>,
1671    ) -> impl ::core::future::Future<Output = ()>;
1672
1673    #[doc = " If supported, PowerUp will power up the wlan chip if it is currently powered down.\n Possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.\n ZX_ERR_BAD_STATE: the wlan chip is already powered up.\n"]
1674    fn power_up(
1675        &mut self,
1676
1677        responder: ::fidl_next::Responder<wlan_phy_impl::PowerUp, ___T>,
1678    ) -> impl ::core::future::Future<Output = ()>;
1679
1680    #[doc = " If supported, Reset functionality implements PowerDown then PowerUp in an attempt to\n recover from an error state. For example, if an interface gets into a bad state or if\n firmware crashes, the firmware/chip may be unable to perform some actions and Reset\n may be able to clear the bad state.\n Possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.\n"]
1681    fn reset(
1682        &mut self,
1683
1684        responder: ::fidl_next::Responder<wlan_phy_impl::Reset, ___T>,
1685    ) -> impl ::core::future::Future<Output = ()>;
1686
1687    #[doc = " Returns the current power state of the wlan chip. After successful initialization\n of the wlan driver, the state is set to true (power on) by default. power_on set to\n true indicates that the wlan chip is powered on and false indicates the wlan chip\n is powered off.\n"]
1688    fn get_power_state(
1689        &mut self,
1690
1691        responder: ::fidl_next::Responder<wlan_phy_impl::GetPowerState, ___T>,
1692    ) -> impl ::core::future::Future<Output = ()>;
1693
1694    #[doc = " Set the Bluetooth coexistence mode.\n Possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: device does not support the specified BT coexistence mode.\n"]
1695    fn set_bt_coexistence_mode(
1696        &mut self,
1697
1698        request: ::fidl_next::Request<wlan_phy_impl::SetBtCoexistenceMode, ___T>,
1699
1700        responder: ::fidl_next::Responder<wlan_phy_impl::SetBtCoexistenceMode, ___T>,
1701    ) -> impl ::core::future::Future<Output = ()>;
1702
1703    fn set_tx_power_scenario(
1704        &mut self,
1705
1706        request: ::fidl_next::Request<wlan_phy_impl::SetTxPowerScenario, ___T>,
1707
1708        responder: ::fidl_next::Responder<wlan_phy_impl::SetTxPowerScenario, ___T>,
1709    ) -> impl ::core::future::Future<Output = ()>;
1710
1711    fn reset_tx_power_scenario(
1712        &mut self,
1713
1714        responder: ::fidl_next::Responder<wlan_phy_impl::ResetTxPowerScenario, ___T>,
1715    ) -> impl ::core::future::Future<Output = ()>;
1716
1717    fn get_tx_power_scenario(
1718        &mut self,
1719
1720        responder: ::fidl_next::Responder<wlan_phy_impl::GetTxPowerScenario, ___T>,
1721    ) -> impl ::core::future::Future<Output = ()>;
1722
1723    fn on_unknown_interaction(&mut self, ordinal: u64) -> impl ::core::future::Future<Output = ()> {
1724        ::core::future::ready(())
1725    }
1726}
1727
1728impl<___H, ___T> ::fidl_next::DispatchLocalServerMessage<___H, ___T> for WlanPhyImpl
1729where
1730    ___H: WlanPhyImplLocalServerHandler<___T>,
1731    ___T: ::fidl_next::Transport,
1732    for<'de> crate::wire::WlanPhyImplInitRequest<'de>: ::fidl_next::Decode<
1733            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
1734            Constraint = (),
1735        >,
1736    for<'de> crate::wire::WlanPhyImplCreateIfaceRequest<'de>: ::fidl_next::Decode<
1737            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
1738            Constraint = (),
1739        >,
1740    for<'de> crate::wire::WlanPhyImplDestroyIfaceRequest<'de>: ::fidl_next::Decode<
1741            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
1742            Constraint = (),
1743        >,
1744    for<'de> crate::wire::WlanPhyCountry<'de>: ::fidl_next::Decode<
1745            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
1746            Constraint = (),
1747        >,
1748    for<'de> crate::wire::WlanPhyImplSetPowerSaveModeRequest<'de>: ::fidl_next::Decode<
1749            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
1750            Constraint = (),
1751        >,
1752    for<'de> crate::wire::WlanPhyImplSetBtCoexistenceModeRequest<'de>: ::fidl_next::Decode<
1753            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
1754            Constraint = (),
1755        >,
1756    for<'de> crate::wire::WlanPhyImplSetTxPowerScenarioRequest<'de>: ::fidl_next::Decode<
1757            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
1758            Constraint = (),
1759        >,
1760{
1761    async fn on_one_way(
1762        handler: &mut ___H,
1763        mut message: ::fidl_next::Message<___T>,
1764    ) -> ::core::result::Result<
1765        (),
1766        ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
1767    > {
1768        match *message.header().ordinal {
1769            ordinal => {
1770                handler.on_unknown_interaction(ordinal).await;
1771                if ::core::matches!(
1772                    message.header().flexibility(),
1773                    ::fidl_next::protocol::Flexibility::Strict
1774                ) {
1775                    Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
1776                } else {
1777                    Ok(())
1778                }
1779            }
1780        }
1781    }
1782
1783    async fn on_two_way(
1784        handler: &mut ___H,
1785        mut message: ::fidl_next::Message<___T>,
1786        responder: ::fidl_next::protocol::Responder<___T>,
1787    ) -> ::core::result::Result<
1788        (),
1789        ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
1790    > {
1791        match *message.header().ordinal {
1792            7493583544655362892 => {
1793                let responder = ::fidl_next::Responder::from_untyped(responder);
1794
1795                match ::fidl_next::AsDecoderExt::into_decoded(message) {
1796                    Ok(decoded) => {
1797                        handler.init(::fidl_next::Request::from_decoded(decoded), responder).await;
1798                        Ok(())
1799                    }
1800                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
1801                        ordinal: 7493583544655362892,
1802                        error,
1803                    }),
1804                }
1805            }
1806
1807            6537800780977121793 => {
1808                let responder = ::fidl_next::Responder::from_untyped(responder);
1809
1810                handler.get_supported_mac_roles(responder).await;
1811                Ok(())
1812            }
1813
1814            3653746094083836708 => {
1815                let responder = ::fidl_next::Responder::from_untyped(responder);
1816
1817                match ::fidl_next::AsDecoderExt::into_decoded(message) {
1818                    Ok(decoded) => {
1819                        handler
1820                            .create_iface(::fidl_next::Request::from_decoded(decoded), responder)
1821                            .await;
1822                        Ok(())
1823                    }
1824                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
1825                        ordinal: 3653746094083836708,
1826                        error,
1827                    }),
1828                }
1829            }
1830
1831            4242398030717562286 => {
1832                let responder = ::fidl_next::Responder::from_untyped(responder);
1833
1834                match ::fidl_next::AsDecoderExt::into_decoded(message) {
1835                    Ok(decoded) => {
1836                        handler
1837                            .destroy_iface(::fidl_next::Request::from_decoded(decoded), responder)
1838                            .await;
1839                        Ok(())
1840                    }
1841                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
1842                        ordinal: 4242398030717562286,
1843                        error,
1844                    }),
1845                }
1846            }
1847
1848            8612397810323877864 => {
1849                let responder = ::fidl_next::Responder::from_untyped(responder);
1850
1851                match ::fidl_next::AsDecoderExt::into_decoded(message) {
1852                    Ok(decoded) => {
1853                        handler
1854                            .set_country(::fidl_next::Request::from_decoded(decoded), responder)
1855                            .await;
1856                        Ok(())
1857                    }
1858                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
1859                        ordinal: 8612397810323877864,
1860                        error,
1861                    }),
1862                }
1863            }
1864
1865            7385017681971907294 => {
1866                let responder = ::fidl_next::Responder::from_untyped(responder);
1867
1868                handler.clear_country(responder).await;
1869                Ok(())
1870            }
1871
1872            504898287153653553 => {
1873                let responder = ::fidl_next::Responder::from_untyped(responder);
1874
1875                handler.get_country(responder).await;
1876                Ok(())
1877            }
1878
1879            5294377936487508532 => {
1880                let responder = ::fidl_next::Responder::from_untyped(responder);
1881
1882                match ::fidl_next::AsDecoderExt::into_decoded(message) {
1883                    Ok(decoded) => {
1884                        handler
1885                            .set_power_save_mode(
1886                                ::fidl_next::Request::from_decoded(decoded),
1887                                responder,
1888                            )
1889                            .await;
1890                        Ok(())
1891                    }
1892                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
1893                        ordinal: 5294377936487508532,
1894                        error,
1895                    }),
1896                }
1897            }
1898
1899            1249843465564268342 => {
1900                let responder = ::fidl_next::Responder::from_untyped(responder);
1901
1902                handler.get_power_save_mode(responder).await;
1903                Ok(())
1904            }
1905
1906            7270381901916338537 => {
1907                let responder = ::fidl_next::Responder::from_untyped(responder);
1908
1909                handler.power_down(responder).await;
1910                Ok(())
1911            }
1912
1913            3906021304522780285 => {
1914                let responder = ::fidl_next::Responder::from_untyped(responder);
1915
1916                handler.power_up(responder).await;
1917                Ok(())
1918            }
1919
1920            2042885235926298203 => {
1921                let responder = ::fidl_next::Responder::from_untyped(responder);
1922
1923                handler.reset(responder).await;
1924                Ok(())
1925            }
1926
1927            1120466226693084492 => {
1928                let responder = ::fidl_next::Responder::from_untyped(responder);
1929
1930                handler.get_power_state(responder).await;
1931                Ok(())
1932            }
1933
1934            3276312011165605259 => {
1935                let responder = ::fidl_next::Responder::from_untyped(responder);
1936
1937                match ::fidl_next::AsDecoderExt::into_decoded(message) {
1938                    Ok(decoded) => {
1939                        handler
1940                            .set_bt_coexistence_mode(
1941                                ::fidl_next::Request::from_decoded(decoded),
1942                                responder,
1943                            )
1944                            .await;
1945                        Ok(())
1946                    }
1947                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
1948                        ordinal: 3276312011165605259,
1949                        error,
1950                    }),
1951                }
1952            }
1953
1954            698995794200761402 => {
1955                let responder = ::fidl_next::Responder::from_untyped(responder);
1956
1957                match ::fidl_next::AsDecoderExt::into_decoded(message) {
1958                    Ok(decoded) => {
1959                        handler
1960                            .set_tx_power_scenario(
1961                                ::fidl_next::Request::from_decoded(decoded),
1962                                responder,
1963                            )
1964                            .await;
1965                        Ok(())
1966                    }
1967                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
1968                        ordinal: 698995794200761402,
1969                        error,
1970                    }),
1971                }
1972            }
1973
1974            5600588310235871255 => {
1975                let responder = ::fidl_next::Responder::from_untyped(responder);
1976
1977                handler.reset_tx_power_scenario(responder).await;
1978                Ok(())
1979            }
1980
1981            1236513198957883974 => {
1982                let responder = ::fidl_next::Responder::from_untyped(responder);
1983
1984                handler.get_tx_power_scenario(responder).await;
1985                Ok(())
1986            }
1987
1988            ordinal => {
1989                handler.on_unknown_interaction(ordinal).await;
1990                if ::core::matches!(
1991                    message.header().flexibility(),
1992                    ::fidl_next::protocol::Flexibility::Strict
1993                ) {
1994                    Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
1995                } else {
1996                    responder
1997                        .respond_framework_error(
1998                            ordinal,
1999                            ::fidl_next::FrameworkError::UnknownMethod,
2000                        )
2001                        .expect("encoding a framework error should never fail")
2002                        .await?;
2003                    Ok(())
2004                }
2005            }
2006        }
2007    }
2008}
2009
2010/// A client handler for the WlanPhyImpl protocol.
2011///
2012/// See [`WlanPhyImpl`] for more details.
2013pub trait WlanPhyImplClientHandler<
2014    #[cfg(feature = "driver")] ___T: ::fidl_next::Transport = ::fdf_fidl::DriverChannel,
2015    #[cfg(not(feature = "driver"))] ___T: ::fidl_next::Transport,
2016>
2017{
2018    fn on_unknown_interaction(
2019        &mut self,
2020        ordinal: u64,
2021    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send {
2022        ::core::future::ready(())
2023    }
2024}
2025
2026impl<___H, ___T> ::fidl_next::DispatchClientMessage<___H, ___T> for WlanPhyImpl
2027where
2028    ___H: WlanPhyImplClientHandler<___T> + ::core::marker::Send,
2029    ___T: ::fidl_next::Transport,
2030{
2031    async fn on_event(
2032        handler: &mut ___H,
2033        mut message: ::fidl_next::Message<___T>,
2034    ) -> ::core::result::Result<(), ::fidl_next::ProtocolError<___T::Error>> {
2035        match *message.header().ordinal {
2036            ordinal => {
2037                handler.on_unknown_interaction(ordinal).await;
2038                if ::core::matches!(
2039                    message.header().flexibility(),
2040                    ::fidl_next::protocol::Flexibility::Strict
2041                ) {
2042                    Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
2043                } else {
2044                    Ok(())
2045                }
2046            }
2047        }
2048    }
2049}
2050
2051/// A server handler for the WlanPhyImpl protocol.
2052///
2053/// See [`WlanPhyImpl`] for more details.
2054pub trait WlanPhyImplServerHandler<
2055    #[cfg(feature = "driver")] ___T: ::fidl_next::Transport = ::fdf_fidl::DriverChannel,
2056    #[cfg(not(feature = "driver"))] ___T: ::fidl_next::Transport,
2057>
2058{
2059    #[doc = " This method can be used by the WlanPhyImpl client to send the client end of the\n WlanPhyImplNotify endpoint for the WlanPhyImpl server to use. If the WlanPhyImpl client\n never invokes this method that is an indirect implication that the WlanPhyImplNotify is not\n supported. Some possible error codes are:\n ZX_ERR_NOT_SUPPORTED: The WlanPhyImpl server does not support the WlanPhyImplNotify protocol.\n"]
2060    fn init(
2061        &mut self,
2062
2063        request: ::fidl_next::Request<wlan_phy_impl::Init, ___T>,
2064
2065        responder: ::fidl_next::Responder<wlan_phy_impl::Init, ___T>,
2066    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2067
2068    #[doc = " MAC roles supported for ifaces on the physical device.\n"]
2069    fn get_supported_mac_roles(
2070        &mut self,
2071
2072        responder: ::fidl_next::Responder<wlan_phy_impl::GetSupportedMacRoles, ___T>,
2073    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2074
2075    #[doc = " Create a new interface with the specified role, returning the interface id. \\\n Some common error codes are: \\\n ZX_ERR_NO_RESOURCES: maximum number of interfaces have already been created. \\\n ZX_ERR_NOT_SUPPORTED: device does not support the specified role.\n"]
2076    fn create_iface(
2077        &mut self,
2078
2079        request: ::fidl_next::Request<wlan_phy_impl::CreateIface, ___T>,
2080
2081        responder: ::fidl_next::Responder<wlan_phy_impl::CreateIface, ___T>,
2082    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2083
2084    #[doc = " Destroy the interface with the matching id. \\\n Some common error codes are: \\\n ZX_ERR_NOT_FOUND: Specified iface does not exist or has already been removed. \\\n ZX_ERR_SHOULD_WAIT: Device is busy and cannot be removed, try again later.\n"]
2085    fn destroy_iface(
2086        &mut self,
2087
2088        request: ::fidl_next::Request<wlan_phy_impl::DestroyIface, ___T>,
2089
2090        responder: ::fidl_next::Responder<wlan_phy_impl::DestroyIface, ___T>,
2091    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2092
2093    #[doc = " Set country with a WlanPhyCountry. \\\n Some common error codes are: \\\n ZX_ERR_NOT_FOUND: Specified country code not supported. PHY state is left unchanged.\n"]
2094    fn set_country(
2095        &mut self,
2096
2097        request: ::fidl_next::Request<wlan_phy_impl::SetCountry, ___T>,
2098
2099        responder: ::fidl_next::Responder<wlan_phy_impl::SetCountry, ___T>,
2100    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2101
2102    #[doc = " Set device to a world-safe country, i.e. a mode that conforms to all\n regulatory constraints globally. \\\n Generally expected to succeed if the device is in a functional state.\n"]
2103    fn clear_country(
2104        &mut self,
2105
2106        responder: ::fidl_next::Responder<wlan_phy_impl::ClearCountry, ___T>,
2107    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2108
2109    #[doc = " Read currently configured country. Implementations are advised to read the\n country directly from the firmware, where possible. \\\n Generally expected to succeed if the device is in a functional state.\n"]
2110    fn get_country(
2111        &mut self,
2112
2113        responder: ::fidl_next::Responder<wlan_phy_impl::GetCountry, ___T>,
2114    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2115
2116    #[doc = " Set Power Save mode on device. In most implementations this\n likely to be set in Firmware. \\\n Some common error codes are: \\\n ZX_ERR_NOT_SUPPORTED: Specified Power Save mode not supported.\n"]
2117    fn set_power_save_mode(
2118        &mut self,
2119
2120        request: ::fidl_next::Request<wlan_phy_impl::SetPowerSaveMode, ___T>,
2121
2122        responder: ::fidl_next::Responder<wlan_phy_impl::SetPowerSaveMode, ___T>,
2123    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2124
2125    #[doc = " Get current Power Save mode from device. In most implementation this\n likely to be retrieved from Firmware.\n"]
2126    fn get_power_save_mode(
2127        &mut self,
2128
2129        responder: ::fidl_next::Responder<wlan_phy_impl::GetPowerSaveMode, ___T>,
2130    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2131
2132    #[doc = " Power up/down/reset the wlan chip.\n If supported, PowerDown will power down the wlan chip if it is currently powered on.\n Any existing interfaces should have already been deleted before making this call or else the\n driver will fail the call with error code ZX_ERR_INTERNAL.\n Other possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.\n ZX_ERR_BAD_STATE: the wlan chip is already powered down.\n"]
2133    fn power_down(
2134        &mut self,
2135
2136        responder: ::fidl_next::Responder<wlan_phy_impl::PowerDown, ___T>,
2137    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2138
2139    #[doc = " If supported, PowerUp will power up the wlan chip if it is currently powered down.\n Possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.\n ZX_ERR_BAD_STATE: the wlan chip is already powered up.\n"]
2140    fn power_up(
2141        &mut self,
2142
2143        responder: ::fidl_next::Responder<wlan_phy_impl::PowerUp, ___T>,
2144    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2145
2146    #[doc = " If supported, Reset functionality implements PowerDown then PowerUp in an attempt to\n recover from an error state. For example, if an interface gets into a bad state or if\n firmware crashes, the firmware/chip may be unable to perform some actions and Reset\n may be able to clear the bad state.\n Possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.\n"]
2147    fn reset(
2148        &mut self,
2149
2150        responder: ::fidl_next::Responder<wlan_phy_impl::Reset, ___T>,
2151    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2152
2153    #[doc = " Returns the current power state of the wlan chip. After successful initialization\n of the wlan driver, the state is set to true (power on) by default. power_on set to\n true indicates that the wlan chip is powered on and false indicates the wlan chip\n is powered off.\n"]
2154    fn get_power_state(
2155        &mut self,
2156
2157        responder: ::fidl_next::Responder<wlan_phy_impl::GetPowerState, ___T>,
2158    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2159
2160    #[doc = " Set the Bluetooth coexistence mode.\n Possible error codes are: \\\n ZX_ERR_NOT_SUPPORTED: device does not support the specified BT coexistence mode.\n"]
2161    fn set_bt_coexistence_mode(
2162        &mut self,
2163
2164        request: ::fidl_next::Request<wlan_phy_impl::SetBtCoexistenceMode, ___T>,
2165
2166        responder: ::fidl_next::Responder<wlan_phy_impl::SetBtCoexistenceMode, ___T>,
2167    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2168
2169    fn set_tx_power_scenario(
2170        &mut self,
2171
2172        request: ::fidl_next::Request<wlan_phy_impl::SetTxPowerScenario, ___T>,
2173
2174        responder: ::fidl_next::Responder<wlan_phy_impl::SetTxPowerScenario, ___T>,
2175    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2176
2177    fn reset_tx_power_scenario(
2178        &mut self,
2179
2180        responder: ::fidl_next::Responder<wlan_phy_impl::ResetTxPowerScenario, ___T>,
2181    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2182
2183    fn get_tx_power_scenario(
2184        &mut self,
2185
2186        responder: ::fidl_next::Responder<wlan_phy_impl::GetTxPowerScenario, ___T>,
2187    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
2188
2189    fn on_unknown_interaction(
2190        &mut self,
2191        ordinal: u64,
2192    ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send {
2193        ::core::future::ready(())
2194    }
2195}
2196
2197impl<___H, ___T> ::fidl_next::DispatchServerMessage<___H, ___T> for WlanPhyImpl
2198where
2199    ___H: WlanPhyImplServerHandler<___T> + ::core::marker::Send,
2200    ___T: ::fidl_next::Transport,
2201    for<'de> crate::wire::WlanPhyImplInitRequest<'de>: ::fidl_next::Decode<
2202            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
2203            Constraint = (),
2204        >,
2205    for<'de> crate::wire::WlanPhyImplCreateIfaceRequest<'de>: ::fidl_next::Decode<
2206            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
2207            Constraint = (),
2208        >,
2209    for<'de> crate::wire::WlanPhyImplDestroyIfaceRequest<'de>: ::fidl_next::Decode<
2210            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
2211            Constraint = (),
2212        >,
2213    for<'de> crate::wire::WlanPhyCountry<'de>: ::fidl_next::Decode<
2214            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
2215            Constraint = (),
2216        >,
2217    for<'de> crate::wire::WlanPhyImplSetPowerSaveModeRequest<'de>: ::fidl_next::Decode<
2218            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
2219            Constraint = (),
2220        >,
2221    for<'de> crate::wire::WlanPhyImplSetBtCoexistenceModeRequest<'de>: ::fidl_next::Decode<
2222            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
2223            Constraint = (),
2224        >,
2225    for<'de> crate::wire::WlanPhyImplSetTxPowerScenarioRequest<'de>: ::fidl_next::Decode<
2226            <<___T as ::fidl_next::Transport>::RecvBuffer as ::fidl_next::AsDecoder<'de>>::Decoder,
2227            Constraint = (),
2228        >,
2229{
2230    async fn on_one_way(
2231        handler: &mut ___H,
2232        mut message: ::fidl_next::Message<___T>,
2233    ) -> ::core::result::Result<
2234        (),
2235        ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
2236    > {
2237        match *message.header().ordinal {
2238            ordinal => {
2239                handler.on_unknown_interaction(ordinal).await;
2240                if ::core::matches!(
2241                    message.header().flexibility(),
2242                    ::fidl_next::protocol::Flexibility::Strict
2243                ) {
2244                    Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
2245                } else {
2246                    Ok(())
2247                }
2248            }
2249        }
2250    }
2251
2252    async fn on_two_way(
2253        handler: &mut ___H,
2254        mut message: ::fidl_next::Message<___T>,
2255        responder: ::fidl_next::protocol::Responder<___T>,
2256    ) -> ::core::result::Result<
2257        (),
2258        ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
2259    > {
2260        match *message.header().ordinal {
2261            7493583544655362892 => {
2262                let responder = ::fidl_next::Responder::from_untyped(responder);
2263
2264                match ::fidl_next::AsDecoderExt::into_decoded(message) {
2265                    Ok(decoded) => {
2266                        handler.init(::fidl_next::Request::from_decoded(decoded), responder).await;
2267                        Ok(())
2268                    }
2269                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
2270                        ordinal: 7493583544655362892,
2271                        error,
2272                    }),
2273                }
2274            }
2275
2276            6537800780977121793 => {
2277                let responder = ::fidl_next::Responder::from_untyped(responder);
2278
2279                handler.get_supported_mac_roles(responder).await;
2280                Ok(())
2281            }
2282
2283            3653746094083836708 => {
2284                let responder = ::fidl_next::Responder::from_untyped(responder);
2285
2286                match ::fidl_next::AsDecoderExt::into_decoded(message) {
2287                    Ok(decoded) => {
2288                        handler
2289                            .create_iface(::fidl_next::Request::from_decoded(decoded), responder)
2290                            .await;
2291                        Ok(())
2292                    }
2293                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
2294                        ordinal: 3653746094083836708,
2295                        error,
2296                    }),
2297                }
2298            }
2299
2300            4242398030717562286 => {
2301                let responder = ::fidl_next::Responder::from_untyped(responder);
2302
2303                match ::fidl_next::AsDecoderExt::into_decoded(message) {
2304                    Ok(decoded) => {
2305                        handler
2306                            .destroy_iface(::fidl_next::Request::from_decoded(decoded), responder)
2307                            .await;
2308                        Ok(())
2309                    }
2310                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
2311                        ordinal: 4242398030717562286,
2312                        error,
2313                    }),
2314                }
2315            }
2316
2317            8612397810323877864 => {
2318                let responder = ::fidl_next::Responder::from_untyped(responder);
2319
2320                match ::fidl_next::AsDecoderExt::into_decoded(message) {
2321                    Ok(decoded) => {
2322                        handler
2323                            .set_country(::fidl_next::Request::from_decoded(decoded), responder)
2324                            .await;
2325                        Ok(())
2326                    }
2327                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
2328                        ordinal: 8612397810323877864,
2329                        error,
2330                    }),
2331                }
2332            }
2333
2334            7385017681971907294 => {
2335                let responder = ::fidl_next::Responder::from_untyped(responder);
2336
2337                handler.clear_country(responder).await;
2338                Ok(())
2339            }
2340
2341            504898287153653553 => {
2342                let responder = ::fidl_next::Responder::from_untyped(responder);
2343
2344                handler.get_country(responder).await;
2345                Ok(())
2346            }
2347
2348            5294377936487508532 => {
2349                let responder = ::fidl_next::Responder::from_untyped(responder);
2350
2351                match ::fidl_next::AsDecoderExt::into_decoded(message) {
2352                    Ok(decoded) => {
2353                        handler
2354                            .set_power_save_mode(
2355                                ::fidl_next::Request::from_decoded(decoded),
2356                                responder,
2357                            )
2358                            .await;
2359                        Ok(())
2360                    }
2361                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
2362                        ordinal: 5294377936487508532,
2363                        error,
2364                    }),
2365                }
2366            }
2367
2368            1249843465564268342 => {
2369                let responder = ::fidl_next::Responder::from_untyped(responder);
2370
2371                handler.get_power_save_mode(responder).await;
2372                Ok(())
2373            }
2374
2375            7270381901916338537 => {
2376                let responder = ::fidl_next::Responder::from_untyped(responder);
2377
2378                handler.power_down(responder).await;
2379                Ok(())
2380            }
2381
2382            3906021304522780285 => {
2383                let responder = ::fidl_next::Responder::from_untyped(responder);
2384
2385                handler.power_up(responder).await;
2386                Ok(())
2387            }
2388
2389            2042885235926298203 => {
2390                let responder = ::fidl_next::Responder::from_untyped(responder);
2391
2392                handler.reset(responder).await;
2393                Ok(())
2394            }
2395
2396            1120466226693084492 => {
2397                let responder = ::fidl_next::Responder::from_untyped(responder);
2398
2399                handler.get_power_state(responder).await;
2400                Ok(())
2401            }
2402
2403            3276312011165605259 => {
2404                let responder = ::fidl_next::Responder::from_untyped(responder);
2405
2406                match ::fidl_next::AsDecoderExt::into_decoded(message) {
2407                    Ok(decoded) => {
2408                        handler
2409                            .set_bt_coexistence_mode(
2410                                ::fidl_next::Request::from_decoded(decoded),
2411                                responder,
2412                            )
2413                            .await;
2414                        Ok(())
2415                    }
2416                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
2417                        ordinal: 3276312011165605259,
2418                        error,
2419                    }),
2420                }
2421            }
2422
2423            698995794200761402 => {
2424                let responder = ::fidl_next::Responder::from_untyped(responder);
2425
2426                match ::fidl_next::AsDecoderExt::into_decoded(message) {
2427                    Ok(decoded) => {
2428                        handler
2429                            .set_tx_power_scenario(
2430                                ::fidl_next::Request::from_decoded(decoded),
2431                                responder,
2432                            )
2433                            .await;
2434                        Ok(())
2435                    }
2436                    Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
2437                        ordinal: 698995794200761402,
2438                        error,
2439                    }),
2440                }
2441            }
2442
2443            5600588310235871255 => {
2444                let responder = ::fidl_next::Responder::from_untyped(responder);
2445
2446                handler.reset_tx_power_scenario(responder).await;
2447                Ok(())
2448            }
2449
2450            1236513198957883974 => {
2451                let responder = ::fidl_next::Responder::from_untyped(responder);
2452
2453                handler.get_tx_power_scenario(responder).await;
2454                Ok(())
2455            }
2456
2457            ordinal => {
2458                handler.on_unknown_interaction(ordinal).await;
2459                if ::core::matches!(
2460                    message.header().flexibility(),
2461                    ::fidl_next::protocol::Flexibility::Strict
2462                ) {
2463                    Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
2464                } else {
2465                    responder
2466                        .respond_framework_error(
2467                            ordinal,
2468                            ::fidl_next::FrameworkError::UnknownMethod,
2469                        )
2470                        .expect("encoding a framework error should never fail")
2471                        .await?;
2472                    Ok(())
2473                }
2474            }
2475        }
2476    }
2477}
2478
2479impl<___T> WlanPhyImplClientHandler<___T> for ::fidl_next::IgnoreEvents
2480where
2481    ___T: ::fidl_next::Transport,
2482{
2483    async fn on_unknown_interaction(&mut self, _: u64) {}
2484}
2485
2486impl<___H, ___T> WlanPhyImplLocalClientHandler<___T> for ::fidl_next::Local<___H>
2487where
2488    ___H: WlanPhyImplClientHandler<___T>,
2489    ___T: ::fidl_next::Transport,
2490{
2491    async fn on_unknown_interaction(&mut self, ordinal: u64) {
2492        ___H::on_unknown_interaction(&mut self.0, ordinal).await
2493    }
2494}
2495
2496impl<___H, ___T> WlanPhyImplLocalServerHandler<___T> for ::fidl_next::Local<___H>
2497where
2498    ___H: WlanPhyImplServerHandler<___T>,
2499    ___T: ::fidl_next::Transport,
2500{
2501    async fn init(
2502        &mut self,
2503
2504        request: ::fidl_next::Request<wlan_phy_impl::Init, ___T>,
2505
2506        responder: ::fidl_next::Responder<wlan_phy_impl::Init, ___T>,
2507    ) {
2508        ___H::init(&mut self.0, request, responder).await
2509    }
2510
2511    async fn get_supported_mac_roles(
2512        &mut self,
2513
2514        responder: ::fidl_next::Responder<wlan_phy_impl::GetSupportedMacRoles, ___T>,
2515    ) {
2516        ___H::get_supported_mac_roles(&mut self.0, responder).await
2517    }
2518
2519    async fn create_iface(
2520        &mut self,
2521
2522        request: ::fidl_next::Request<wlan_phy_impl::CreateIface, ___T>,
2523
2524        responder: ::fidl_next::Responder<wlan_phy_impl::CreateIface, ___T>,
2525    ) {
2526        ___H::create_iface(&mut self.0, request, responder).await
2527    }
2528
2529    async fn destroy_iface(
2530        &mut self,
2531
2532        request: ::fidl_next::Request<wlan_phy_impl::DestroyIface, ___T>,
2533
2534        responder: ::fidl_next::Responder<wlan_phy_impl::DestroyIface, ___T>,
2535    ) {
2536        ___H::destroy_iface(&mut self.0, request, responder).await
2537    }
2538
2539    async fn set_country(
2540        &mut self,
2541
2542        request: ::fidl_next::Request<wlan_phy_impl::SetCountry, ___T>,
2543
2544        responder: ::fidl_next::Responder<wlan_phy_impl::SetCountry, ___T>,
2545    ) {
2546        ___H::set_country(&mut self.0, request, responder).await
2547    }
2548
2549    async fn clear_country(
2550        &mut self,
2551
2552        responder: ::fidl_next::Responder<wlan_phy_impl::ClearCountry, ___T>,
2553    ) {
2554        ___H::clear_country(&mut self.0, responder).await
2555    }
2556
2557    async fn get_country(
2558        &mut self,
2559
2560        responder: ::fidl_next::Responder<wlan_phy_impl::GetCountry, ___T>,
2561    ) {
2562        ___H::get_country(&mut self.0, responder).await
2563    }
2564
2565    async fn set_power_save_mode(
2566        &mut self,
2567
2568        request: ::fidl_next::Request<wlan_phy_impl::SetPowerSaveMode, ___T>,
2569
2570        responder: ::fidl_next::Responder<wlan_phy_impl::SetPowerSaveMode, ___T>,
2571    ) {
2572        ___H::set_power_save_mode(&mut self.0, request, responder).await
2573    }
2574
2575    async fn get_power_save_mode(
2576        &mut self,
2577
2578        responder: ::fidl_next::Responder<wlan_phy_impl::GetPowerSaveMode, ___T>,
2579    ) {
2580        ___H::get_power_save_mode(&mut self.0, responder).await
2581    }
2582
2583    async fn power_down(
2584        &mut self,
2585
2586        responder: ::fidl_next::Responder<wlan_phy_impl::PowerDown, ___T>,
2587    ) {
2588        ___H::power_down(&mut self.0, responder).await
2589    }
2590
2591    async fn power_up(&mut self, responder: ::fidl_next::Responder<wlan_phy_impl::PowerUp, ___T>) {
2592        ___H::power_up(&mut self.0, responder).await
2593    }
2594
2595    async fn reset(&mut self, responder: ::fidl_next::Responder<wlan_phy_impl::Reset, ___T>) {
2596        ___H::reset(&mut self.0, responder).await
2597    }
2598
2599    async fn get_power_state(
2600        &mut self,
2601
2602        responder: ::fidl_next::Responder<wlan_phy_impl::GetPowerState, ___T>,
2603    ) {
2604        ___H::get_power_state(&mut self.0, responder).await
2605    }
2606
2607    async fn set_bt_coexistence_mode(
2608        &mut self,
2609
2610        request: ::fidl_next::Request<wlan_phy_impl::SetBtCoexistenceMode, ___T>,
2611
2612        responder: ::fidl_next::Responder<wlan_phy_impl::SetBtCoexistenceMode, ___T>,
2613    ) {
2614        ___H::set_bt_coexistence_mode(&mut self.0, request, responder).await
2615    }
2616
2617    async fn set_tx_power_scenario(
2618        &mut self,
2619
2620        request: ::fidl_next::Request<wlan_phy_impl::SetTxPowerScenario, ___T>,
2621
2622        responder: ::fidl_next::Responder<wlan_phy_impl::SetTxPowerScenario, ___T>,
2623    ) {
2624        ___H::set_tx_power_scenario(&mut self.0, request, responder).await
2625    }
2626
2627    async fn reset_tx_power_scenario(
2628        &mut self,
2629
2630        responder: ::fidl_next::Responder<wlan_phy_impl::ResetTxPowerScenario, ___T>,
2631    ) {
2632        ___H::reset_tx_power_scenario(&mut self.0, responder).await
2633    }
2634
2635    async fn get_tx_power_scenario(
2636        &mut self,
2637
2638        responder: ::fidl_next::Responder<wlan_phy_impl::GetTxPowerScenario, ___T>,
2639    ) {
2640        ___H::get_tx_power_scenario(&mut self.0, responder).await
2641    }
2642
2643    async fn on_unknown_interaction(&mut self, ordinal: u64) {
2644        ___H::on_unknown_interaction(&mut self.0, ordinal).await
2645    }
2646}
2647
2648pub use fidl_next_common_fuchsia_wlan_phyimpl::*;