1#![warn(clippy::all)]
3#![allow(unused_parens, unused_variables, unused_mut, unused_imports, unreachable_code)]
4
5#[derive(Clone, Debug)]
6pub struct LoaderLoadObjectRequest {
7 pub object_name: String,
8}
9
10impl ::fidl_next::Encodable for LoaderLoadObjectRequest {
11 type Encoded = WireLoaderLoadObjectRequest<'static>;
12}
13
14unsafe impl<___E> ::fidl_next::Encode<___E> for LoaderLoadObjectRequest
15where
16 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
17 ___E: ::fidl_next::Encoder,
18{
19 #[inline]
20 fn encode(
21 self,
22 encoder: &mut ___E,
23 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
24 ) -> Result<(), ::fidl_next::EncodeError> {
25 ::fidl_next::munge! {
26 let Self::Encoded {
27 object_name,
28
29 } = out;
30 }
31
32 ::fidl_next::Encode::encode(self.object_name, encoder, object_name)?;
33
34 Ok(())
35 }
36}
37
38unsafe impl<___E> ::fidl_next::EncodeRef<___E> for LoaderLoadObjectRequest
39where
40 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
41 ___E: ::fidl_next::Encoder,
42{
43 #[inline]
44 fn encode_ref(
45 &self,
46 encoder: &mut ___E,
47 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
48 ) -> Result<(), ::fidl_next::EncodeError> {
49 ::fidl_next::munge! {
50 let Self::Encoded {
51 object_name,
52
53 } = out;
54 }
55
56 ::fidl_next::EncodeRef::encode_ref(&self.object_name, encoder, object_name)?;
57
58 Ok(())
59 }
60}
61
62impl ::fidl_next::EncodableOption for LoaderLoadObjectRequest {
63 type EncodedOption = ::fidl_next::WireBox<'static, WireLoaderLoadObjectRequest<'static>>;
64}
65
66unsafe impl<___E> ::fidl_next::EncodeOption<___E> for LoaderLoadObjectRequest
67where
68 ___E: ::fidl_next::Encoder + ?Sized,
69 LoaderLoadObjectRequest: ::fidl_next::Encode<___E>,
70{
71 #[inline]
72 fn encode_option(
73 this: Option<Self>,
74 encoder: &mut ___E,
75 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
76 ) -> Result<(), ::fidl_next::EncodeError> {
77 if let Some(inner) = this {
78 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
79 ::fidl_next::WireBox::encode_present(out);
80 } else {
81 ::fidl_next::WireBox::encode_absent(out);
82 }
83
84 Ok(())
85 }
86}
87
88unsafe impl<___E> ::fidl_next::EncodeOptionRef<___E> for LoaderLoadObjectRequest
89where
90 ___E: ::fidl_next::Encoder + ?Sized,
91 LoaderLoadObjectRequest: ::fidl_next::EncodeRef<___E>,
92{
93 #[inline]
94 fn encode_option_ref(
95 this: Option<&Self>,
96 encoder: &mut ___E,
97 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
98 ) -> Result<(), ::fidl_next::EncodeError> {
99 if let Some(inner) = this {
100 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
101 ::fidl_next::WireBox::encode_present(out);
102 } else {
103 ::fidl_next::WireBox::encode_absent(out);
104 }
105
106 Ok(())
107 }
108}
109
110impl<'de> ::fidl_next::FromWire<WireLoaderLoadObjectRequest<'de>> for LoaderLoadObjectRequest {
111 #[inline]
112 fn from_wire(wire: WireLoaderLoadObjectRequest<'de>) -> Self {
113 Self { object_name: ::fidl_next::FromWire::from_wire(wire.object_name) }
114 }
115}
116
117impl<'de> ::fidl_next::FromWireRef<WireLoaderLoadObjectRequest<'de>> for LoaderLoadObjectRequest {
118 #[inline]
119 fn from_wire_ref(wire: &WireLoaderLoadObjectRequest<'de>) -> Self {
120 Self { object_name: ::fidl_next::FromWireRef::from_wire_ref(&wire.object_name) }
121 }
122}
123
124#[derive(Debug)]
126#[repr(C)]
127pub struct WireLoaderLoadObjectRequest<'de> {
128 pub object_name: ::fidl_next::WireString<'de>,
129}
130
131unsafe impl ::fidl_next::Wire for WireLoaderLoadObjectRequest<'static> {
132 type Decoded<'de> = WireLoaderLoadObjectRequest<'de>;
133
134 #[inline]
135 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {}
136}
137
138unsafe impl<___D> ::fidl_next::Decode<___D> for WireLoaderLoadObjectRequest<'static>
139where
140 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
141 ___D: ::fidl_next::Decoder,
142{
143 fn decode(
144 slot: ::fidl_next::Slot<'_, Self>,
145 decoder: &mut ___D,
146 ) -> Result<(), ::fidl_next::DecodeError> {
147 ::fidl_next::munge! {
148 let Self {
149 mut object_name,
150
151 } = slot;
152 }
153
154 ::fidl_next::Decode::decode(object_name.as_mut(), decoder)?;
155
156 let object_name = unsafe { object_name.deref_unchecked() };
157
158 if object_name.len() > 1024 {
159 return Err(::fidl_next::DecodeError::VectorTooLong {
160 size: object_name.len() as u64,
161 limit: 1024,
162 });
163 }
164
165 Ok(())
166 }
167}
168
169#[derive(Debug)]
170#[repr(C)]
171pub struct LoaderLoadObjectResponse {
172 pub rv: i32,
173
174 pub object: Option<::fidl_next::fuchsia::zx::Vmo>,
175}
176
177impl ::fidl_next::Encodable for LoaderLoadObjectResponse {
178 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, WireLoaderLoadObjectResponse> = unsafe {
179 ::fidl_next::CopyOptimization::enable_if(
180 true
181
182 && <
183 i32 as ::fidl_next::Encodable
184 >::COPY_OPTIMIZATION.is_enabled()
185
186 && <
187 Option<::fidl_next::fuchsia::zx::Vmo> as ::fidl_next::Encodable
188 >::COPY_OPTIMIZATION.is_enabled()
189
190 )
191 };
192
193 type Encoded = WireLoaderLoadObjectResponse;
194}
195
196unsafe impl<___E> ::fidl_next::Encode<___E> for LoaderLoadObjectResponse
197where
198 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
199 ___E: ::fidl_next::fuchsia::HandleEncoder,
200{
201 #[inline]
202 fn encode(
203 self,
204 encoder: &mut ___E,
205 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
206 ) -> Result<(), ::fidl_next::EncodeError> {
207 ::fidl_next::munge! {
208 let Self::Encoded {
209 rv,
210 object,
211
212 } = out;
213 }
214
215 ::fidl_next::Encode::encode(self.rv, encoder, rv)?;
216
217 ::fidl_next::Encode::encode(self.object, encoder, object)?;
218
219 Ok(())
220 }
221}
222
223impl ::fidl_next::EncodableOption for LoaderLoadObjectResponse {
224 type EncodedOption = ::fidl_next::WireBox<'static, WireLoaderLoadObjectResponse>;
225}
226
227unsafe impl<___E> ::fidl_next::EncodeOption<___E> for LoaderLoadObjectResponse
228where
229 ___E: ::fidl_next::Encoder + ?Sized,
230 LoaderLoadObjectResponse: ::fidl_next::Encode<___E>,
231{
232 #[inline]
233 fn encode_option(
234 this: Option<Self>,
235 encoder: &mut ___E,
236 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
237 ) -> Result<(), ::fidl_next::EncodeError> {
238 if let Some(inner) = this {
239 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
240 ::fidl_next::WireBox::encode_present(out);
241 } else {
242 ::fidl_next::WireBox::encode_absent(out);
243 }
244
245 Ok(())
246 }
247}
248
249impl ::fidl_next::FromWire<WireLoaderLoadObjectResponse> for LoaderLoadObjectResponse {
250 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<WireLoaderLoadObjectResponse, Self> = unsafe {
251 ::fidl_next::CopyOptimization::enable_if(
252 true && <i32 as ::fidl_next::FromWire<::fidl_next::WireI32>>::COPY_OPTIMIZATION
253 .is_enabled()
254 && <Option<::fidl_next::fuchsia::zx::Vmo> as ::fidl_next::FromWire<
255 ::fidl_next::fuchsia::WireOptionalVmo,
256 >>::COPY_OPTIMIZATION
257 .is_enabled(),
258 )
259 };
260
261 #[inline]
262 fn from_wire(wire: WireLoaderLoadObjectResponse) -> Self {
263 Self {
264 rv: ::fidl_next::FromWire::from_wire(wire.rv),
265
266 object: ::fidl_next::FromWire::from_wire(wire.object),
267 }
268 }
269}
270
271#[derive(Debug)]
273#[repr(C)]
274pub struct WireLoaderLoadObjectResponse {
275 pub rv: ::fidl_next::WireI32,
276
277 pub object: ::fidl_next::fuchsia::WireOptionalVmo,
278}
279
280unsafe impl ::fidl_next::Wire for WireLoaderLoadObjectResponse {
281 type Decoded<'de> = WireLoaderLoadObjectResponse;
282
283 #[inline]
284 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {}
285}
286
287unsafe impl<___D> ::fidl_next::Decode<___D> for WireLoaderLoadObjectResponse
288where
289 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
290 ___D: ::fidl_next::fuchsia::HandleDecoder,
291{
292 fn decode(
293 slot: ::fidl_next::Slot<'_, Self>,
294 decoder: &mut ___D,
295 ) -> Result<(), ::fidl_next::DecodeError> {
296 ::fidl_next::munge! {
297 let Self {
298 mut rv,
299 mut object,
300
301 } = slot;
302 }
303
304 ::fidl_next::Decode::decode(rv.as_mut(), decoder)?;
305
306 ::fidl_next::Decode::decode(object.as_mut(), decoder)?;
307
308 Ok(())
309 }
310}
311
312#[derive(Clone, Debug)]
313pub struct LoaderConfigRequest {
314 pub config: String,
315}
316
317impl ::fidl_next::Encodable for LoaderConfigRequest {
318 type Encoded = WireLoaderConfigRequest<'static>;
319}
320
321unsafe impl<___E> ::fidl_next::Encode<___E> for LoaderConfigRequest
322where
323 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
324 ___E: ::fidl_next::Encoder,
325{
326 #[inline]
327 fn encode(
328 self,
329 encoder: &mut ___E,
330 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
331 ) -> Result<(), ::fidl_next::EncodeError> {
332 ::fidl_next::munge! {
333 let Self::Encoded {
334 config,
335
336 } = out;
337 }
338
339 ::fidl_next::Encode::encode(self.config, encoder, config)?;
340
341 Ok(())
342 }
343}
344
345unsafe impl<___E> ::fidl_next::EncodeRef<___E> for LoaderConfigRequest
346where
347 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
348 ___E: ::fidl_next::Encoder,
349{
350 #[inline]
351 fn encode_ref(
352 &self,
353 encoder: &mut ___E,
354 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
355 ) -> Result<(), ::fidl_next::EncodeError> {
356 ::fidl_next::munge! {
357 let Self::Encoded {
358 config,
359
360 } = out;
361 }
362
363 ::fidl_next::EncodeRef::encode_ref(&self.config, encoder, config)?;
364
365 Ok(())
366 }
367}
368
369impl ::fidl_next::EncodableOption for LoaderConfigRequest {
370 type EncodedOption = ::fidl_next::WireBox<'static, WireLoaderConfigRequest<'static>>;
371}
372
373unsafe impl<___E> ::fidl_next::EncodeOption<___E> for LoaderConfigRequest
374where
375 ___E: ::fidl_next::Encoder + ?Sized,
376 LoaderConfigRequest: ::fidl_next::Encode<___E>,
377{
378 #[inline]
379 fn encode_option(
380 this: Option<Self>,
381 encoder: &mut ___E,
382 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
383 ) -> Result<(), ::fidl_next::EncodeError> {
384 if let Some(inner) = this {
385 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
386 ::fidl_next::WireBox::encode_present(out);
387 } else {
388 ::fidl_next::WireBox::encode_absent(out);
389 }
390
391 Ok(())
392 }
393}
394
395unsafe impl<___E> ::fidl_next::EncodeOptionRef<___E> for LoaderConfigRequest
396where
397 ___E: ::fidl_next::Encoder + ?Sized,
398 LoaderConfigRequest: ::fidl_next::EncodeRef<___E>,
399{
400 #[inline]
401 fn encode_option_ref(
402 this: Option<&Self>,
403 encoder: &mut ___E,
404 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
405 ) -> Result<(), ::fidl_next::EncodeError> {
406 if let Some(inner) = this {
407 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
408 ::fidl_next::WireBox::encode_present(out);
409 } else {
410 ::fidl_next::WireBox::encode_absent(out);
411 }
412
413 Ok(())
414 }
415}
416
417impl<'de> ::fidl_next::FromWire<WireLoaderConfigRequest<'de>> for LoaderConfigRequest {
418 #[inline]
419 fn from_wire(wire: WireLoaderConfigRequest<'de>) -> Self {
420 Self { config: ::fidl_next::FromWire::from_wire(wire.config) }
421 }
422}
423
424impl<'de> ::fidl_next::FromWireRef<WireLoaderConfigRequest<'de>> for LoaderConfigRequest {
425 #[inline]
426 fn from_wire_ref(wire: &WireLoaderConfigRequest<'de>) -> Self {
427 Self { config: ::fidl_next::FromWireRef::from_wire_ref(&wire.config) }
428 }
429}
430
431#[derive(Debug)]
433#[repr(C)]
434pub struct WireLoaderConfigRequest<'de> {
435 pub config: ::fidl_next::WireString<'de>,
436}
437
438unsafe impl ::fidl_next::Wire for WireLoaderConfigRequest<'static> {
439 type Decoded<'de> = WireLoaderConfigRequest<'de>;
440
441 #[inline]
442 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {}
443}
444
445unsafe impl<___D> ::fidl_next::Decode<___D> for WireLoaderConfigRequest<'static>
446where
447 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
448 ___D: ::fidl_next::Decoder,
449{
450 fn decode(
451 slot: ::fidl_next::Slot<'_, Self>,
452 decoder: &mut ___D,
453 ) -> Result<(), ::fidl_next::DecodeError> {
454 ::fidl_next::munge! {
455 let Self {
456 mut config,
457
458 } = slot;
459 }
460
461 ::fidl_next::Decode::decode(config.as_mut(), decoder)?;
462
463 let config = unsafe { config.deref_unchecked() };
464
465 if config.len() > 1024 {
466 return Err(::fidl_next::DecodeError::VectorTooLong {
467 size: config.len() as u64,
468 limit: 1024,
469 });
470 }
471
472 Ok(())
473 }
474}
475
476#[derive(Clone, Debug)]
477#[repr(C)]
478pub struct LoaderConfigResponse {
479 pub rv: i32,
480}
481
482impl ::fidl_next::Encodable for LoaderConfigResponse {
483 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, WireLoaderConfigResponse> = unsafe {
484 ::fidl_next::CopyOptimization::enable_if(
485 true && <i32 as ::fidl_next::Encodable>::COPY_OPTIMIZATION.is_enabled(),
486 )
487 };
488
489 type Encoded = WireLoaderConfigResponse;
490}
491
492unsafe impl<___E> ::fidl_next::Encode<___E> for LoaderConfigResponse
493where
494 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
495{
496 #[inline]
497 fn encode(
498 self,
499 encoder: &mut ___E,
500 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
501 ) -> Result<(), ::fidl_next::EncodeError> {
502 ::fidl_next::munge! {
503 let Self::Encoded {
504 rv,
505
506 } = out;
507 }
508
509 ::fidl_next::Encode::encode(self.rv, encoder, rv)?;
510
511 Ok(())
512 }
513}
514
515unsafe impl<___E> ::fidl_next::EncodeRef<___E> for LoaderConfigResponse
516where
517 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
518{
519 #[inline]
520 fn encode_ref(
521 &self,
522 encoder: &mut ___E,
523 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
524 ) -> Result<(), ::fidl_next::EncodeError> {
525 ::fidl_next::munge! {
526 let Self::Encoded {
527 rv,
528
529 } = out;
530 }
531
532 ::fidl_next::EncodeRef::encode_ref(&self.rv, encoder, rv)?;
533
534 Ok(())
535 }
536}
537
538impl ::fidl_next::EncodableOption for LoaderConfigResponse {
539 type EncodedOption = ::fidl_next::WireBox<'static, WireLoaderConfigResponse>;
540}
541
542unsafe impl<___E> ::fidl_next::EncodeOption<___E> for LoaderConfigResponse
543where
544 ___E: ::fidl_next::Encoder + ?Sized,
545 LoaderConfigResponse: ::fidl_next::Encode<___E>,
546{
547 #[inline]
548 fn encode_option(
549 this: Option<Self>,
550 encoder: &mut ___E,
551 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
552 ) -> Result<(), ::fidl_next::EncodeError> {
553 if let Some(inner) = this {
554 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
555 ::fidl_next::WireBox::encode_present(out);
556 } else {
557 ::fidl_next::WireBox::encode_absent(out);
558 }
559
560 Ok(())
561 }
562}
563
564unsafe impl<___E> ::fidl_next::EncodeOptionRef<___E> for LoaderConfigResponse
565where
566 ___E: ::fidl_next::Encoder + ?Sized,
567 LoaderConfigResponse: ::fidl_next::EncodeRef<___E>,
568{
569 #[inline]
570 fn encode_option_ref(
571 this: Option<&Self>,
572 encoder: &mut ___E,
573 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
574 ) -> Result<(), ::fidl_next::EncodeError> {
575 if let Some(inner) = this {
576 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
577 ::fidl_next::WireBox::encode_present(out);
578 } else {
579 ::fidl_next::WireBox::encode_absent(out);
580 }
581
582 Ok(())
583 }
584}
585
586impl ::fidl_next::FromWire<WireLoaderConfigResponse> for LoaderConfigResponse {
587 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<WireLoaderConfigResponse, Self> = unsafe {
588 ::fidl_next::CopyOptimization::enable_if(
589 true && <i32 as ::fidl_next::FromWire<::fidl_next::WireI32>>::COPY_OPTIMIZATION
590 .is_enabled(),
591 )
592 };
593
594 #[inline]
595 fn from_wire(wire: WireLoaderConfigResponse) -> Self {
596 Self { rv: ::fidl_next::FromWire::from_wire(wire.rv) }
597 }
598}
599
600impl ::fidl_next::FromWireRef<WireLoaderConfigResponse> for LoaderConfigResponse {
601 #[inline]
602 fn from_wire_ref(wire: &WireLoaderConfigResponse) -> Self {
603 Self { rv: ::fidl_next::FromWireRef::from_wire_ref(&wire.rv) }
604 }
605}
606
607#[derive(Clone, Debug)]
609#[repr(C)]
610pub struct WireLoaderConfigResponse {
611 pub rv: ::fidl_next::WireI32,
612}
613
614unsafe impl ::fidl_next::Wire for WireLoaderConfigResponse {
615 type Decoded<'de> = WireLoaderConfigResponse;
616
617 #[inline]
618 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {}
619}
620
621unsafe impl<___D> ::fidl_next::Decode<___D> for WireLoaderConfigResponse
622where
623 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
624{
625 fn decode(
626 slot: ::fidl_next::Slot<'_, Self>,
627 decoder: &mut ___D,
628 ) -> Result<(), ::fidl_next::DecodeError> {
629 ::fidl_next::munge! {
630 let Self {
631 mut rv,
632
633 } = slot;
634 }
635
636 ::fidl_next::Decode::decode(rv.as_mut(), decoder)?;
637
638 Ok(())
639 }
640}
641
642#[derive(Debug)]
643#[repr(C)]
644pub struct LoaderCloneRequest {
645 pub loader: ::fidl_next::ServerEnd<crate::Loader, ::fidl_next::fuchsia::zx::Channel>,
646}
647
648impl ::fidl_next::Encodable for LoaderCloneRequest {
649 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, WireLoaderCloneRequest> = unsafe {
650 ::fidl_next::CopyOptimization::enable_if(
651 true
652
653 && <
654 ::fidl_next::ServerEnd<crate::Loader, ::fidl_next::fuchsia::zx::Channel> as ::fidl_next::Encodable
655 >::COPY_OPTIMIZATION.is_enabled()
656
657 )
658 };
659
660 type Encoded = WireLoaderCloneRequest;
661}
662
663unsafe impl<___E> ::fidl_next::Encode<___E> for LoaderCloneRequest
664where
665 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
666 ___E: ::fidl_next::fuchsia::HandleEncoder,
667{
668 #[inline]
669 fn encode(
670 self,
671 encoder: &mut ___E,
672 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
673 ) -> Result<(), ::fidl_next::EncodeError> {
674 ::fidl_next::munge! {
675 let Self::Encoded {
676 loader,
677
678 } = out;
679 }
680
681 ::fidl_next::Encode::encode(self.loader, encoder, loader)?;
682
683 Ok(())
684 }
685}
686
687impl ::fidl_next::EncodableOption for LoaderCloneRequest {
688 type EncodedOption = ::fidl_next::WireBox<'static, WireLoaderCloneRequest>;
689}
690
691unsafe impl<___E> ::fidl_next::EncodeOption<___E> for LoaderCloneRequest
692where
693 ___E: ::fidl_next::Encoder + ?Sized,
694 LoaderCloneRequest: ::fidl_next::Encode<___E>,
695{
696 #[inline]
697 fn encode_option(
698 this: Option<Self>,
699 encoder: &mut ___E,
700 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
701 ) -> Result<(), ::fidl_next::EncodeError> {
702 if let Some(inner) = this {
703 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
704 ::fidl_next::WireBox::encode_present(out);
705 } else {
706 ::fidl_next::WireBox::encode_absent(out);
707 }
708
709 Ok(())
710 }
711}
712
713impl ::fidl_next::FromWire<WireLoaderCloneRequest> for LoaderCloneRequest {
714 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<WireLoaderCloneRequest, Self> = unsafe {
715 ::fidl_next::CopyOptimization::enable_if(
716 true
717
718 && <
719 ::fidl_next::ServerEnd<crate::Loader, ::fidl_next::fuchsia::zx::Channel> as ::fidl_next::FromWire<::fidl_next::ServerEnd<crate::Loader, ::fidl_next::fuchsia::WireChannel>>
720 >::COPY_OPTIMIZATION.is_enabled()
721
722 )
723 };
724
725 #[inline]
726 fn from_wire(wire: WireLoaderCloneRequest) -> Self {
727 Self { loader: ::fidl_next::FromWire::from_wire(wire.loader) }
728 }
729}
730
731#[derive(Debug)]
733#[repr(C)]
734pub struct WireLoaderCloneRequest {
735 pub loader: ::fidl_next::ServerEnd<crate::Loader, ::fidl_next::fuchsia::WireChannel>,
736}
737
738unsafe impl ::fidl_next::Wire for WireLoaderCloneRequest {
739 type Decoded<'de> = WireLoaderCloneRequest;
740
741 #[inline]
742 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {}
743}
744
745unsafe impl<___D> ::fidl_next::Decode<___D> for WireLoaderCloneRequest
746where
747 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
748 ___D: ::fidl_next::fuchsia::HandleDecoder,
749{
750 fn decode(
751 slot: ::fidl_next::Slot<'_, Self>,
752 decoder: &mut ___D,
753 ) -> Result<(), ::fidl_next::DecodeError> {
754 ::fidl_next::munge! {
755 let Self {
756 mut loader,
757
758 } = slot;
759 }
760
761 ::fidl_next::Decode::decode(loader.as_mut(), decoder)?;
762
763 Ok(())
764 }
765}
766
767#[derive(Clone, Debug)]
768#[repr(C)]
769pub struct LoaderCloneResponse {
770 pub rv: i32,
771}
772
773impl ::fidl_next::Encodable for LoaderCloneResponse {
774 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<Self, WireLoaderCloneResponse> = unsafe {
775 ::fidl_next::CopyOptimization::enable_if(
776 true && <i32 as ::fidl_next::Encodable>::COPY_OPTIMIZATION.is_enabled(),
777 )
778 };
779
780 type Encoded = WireLoaderCloneResponse;
781}
782
783unsafe impl<___E> ::fidl_next::Encode<___E> for LoaderCloneResponse
784where
785 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
786{
787 #[inline]
788 fn encode(
789 self,
790 encoder: &mut ___E,
791 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
792 ) -> Result<(), ::fidl_next::EncodeError> {
793 ::fidl_next::munge! {
794 let Self::Encoded {
795 rv,
796
797 } = out;
798 }
799
800 ::fidl_next::Encode::encode(self.rv, encoder, rv)?;
801
802 Ok(())
803 }
804}
805
806unsafe impl<___E> ::fidl_next::EncodeRef<___E> for LoaderCloneResponse
807where
808 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
809{
810 #[inline]
811 fn encode_ref(
812 &self,
813 encoder: &mut ___E,
814 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
815 ) -> Result<(), ::fidl_next::EncodeError> {
816 ::fidl_next::munge! {
817 let Self::Encoded {
818 rv,
819
820 } = out;
821 }
822
823 ::fidl_next::EncodeRef::encode_ref(&self.rv, encoder, rv)?;
824
825 Ok(())
826 }
827}
828
829impl ::fidl_next::EncodableOption for LoaderCloneResponse {
830 type EncodedOption = ::fidl_next::WireBox<'static, WireLoaderCloneResponse>;
831}
832
833unsafe impl<___E> ::fidl_next::EncodeOption<___E> for LoaderCloneResponse
834where
835 ___E: ::fidl_next::Encoder + ?Sized,
836 LoaderCloneResponse: ::fidl_next::Encode<___E>,
837{
838 #[inline]
839 fn encode_option(
840 this: Option<Self>,
841 encoder: &mut ___E,
842 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
843 ) -> Result<(), ::fidl_next::EncodeError> {
844 if let Some(inner) = this {
845 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
846 ::fidl_next::WireBox::encode_present(out);
847 } else {
848 ::fidl_next::WireBox::encode_absent(out);
849 }
850
851 Ok(())
852 }
853}
854
855unsafe impl<___E> ::fidl_next::EncodeOptionRef<___E> for LoaderCloneResponse
856where
857 ___E: ::fidl_next::Encoder + ?Sized,
858 LoaderCloneResponse: ::fidl_next::EncodeRef<___E>,
859{
860 #[inline]
861 fn encode_option_ref(
862 this: Option<&Self>,
863 encoder: &mut ___E,
864 out: &mut ::core::mem::MaybeUninit<Self::EncodedOption>,
865 ) -> Result<(), ::fidl_next::EncodeError> {
866 if let Some(inner) = this {
867 ::fidl_next::EncoderExt::encode_next(encoder, inner)?;
868 ::fidl_next::WireBox::encode_present(out);
869 } else {
870 ::fidl_next::WireBox::encode_absent(out);
871 }
872
873 Ok(())
874 }
875}
876
877impl ::fidl_next::FromWire<WireLoaderCloneResponse> for LoaderCloneResponse {
878 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<WireLoaderCloneResponse, Self> = unsafe {
879 ::fidl_next::CopyOptimization::enable_if(
880 true && <i32 as ::fidl_next::FromWire<::fidl_next::WireI32>>::COPY_OPTIMIZATION
881 .is_enabled(),
882 )
883 };
884
885 #[inline]
886 fn from_wire(wire: WireLoaderCloneResponse) -> Self {
887 Self { rv: ::fidl_next::FromWire::from_wire(wire.rv) }
888 }
889}
890
891impl ::fidl_next::FromWireRef<WireLoaderCloneResponse> for LoaderCloneResponse {
892 #[inline]
893 fn from_wire_ref(wire: &WireLoaderCloneResponse) -> Self {
894 Self { rv: ::fidl_next::FromWireRef::from_wire_ref(&wire.rv) }
895 }
896}
897
898#[derive(Clone, Debug)]
900#[repr(C)]
901pub struct WireLoaderCloneResponse {
902 pub rv: ::fidl_next::WireI32,
903}
904
905unsafe impl ::fidl_next::Wire for WireLoaderCloneResponse {
906 type Decoded<'de> = WireLoaderCloneResponse;
907
908 #[inline]
909 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {}
910}
911
912unsafe impl<___D> ::fidl_next::Decode<___D> for WireLoaderCloneResponse
913where
914 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
915{
916 fn decode(
917 slot: ::fidl_next::Slot<'_, Self>,
918 decoder: &mut ___D,
919 ) -> Result<(), ::fidl_next::DecodeError> {
920 ::fidl_next::munge! {
921 let Self {
922 mut rv,
923
924 } = slot;
925 }
926
927 ::fidl_next::Decode::decode(rv.as_mut(), decoder)?;
928
929 Ok(())
930 }
931}
932
933#[doc = " See //docs/concepts/process/program_loading.md for a more complete\n description of this and related process bootstrapping protocols, and\n for specifics about the default global loader service\'s\n interpretation of names, paths, and configurations.\n"]
935#[derive(Debug)]
936pub struct Loader;
937
938pub mod loader {
939 pub mod prelude {
940 pub use crate::{Loader, LoaderClientHandler, LoaderServerHandler, loader};
941
942 pub use crate::LoaderCloneRequest;
943
944 pub use crate::LoaderCloneResponse;
945
946 pub use crate::LoaderConfigRequest;
947
948 pub use crate::LoaderConfigResponse;
949
950 pub use crate::LoaderLoadObjectRequest;
951
952 pub use crate::LoaderLoadObjectResponse;
953 }
954
955 pub struct Done;
956
957 impl ::fidl_next::Method for Done {
958 const ORDINAL: u64 = 7186174313520107521;
959
960 type Protocol = crate::Loader;
961
962 type Request = ();
963
964 type Response = ::fidl_next::Never;
965 }
966
967 pub struct LoadObject;
968
969 impl ::fidl_next::Method for LoadObject {
970 const ORDINAL: u64 = 5243774714012182611;
971
972 type Protocol = crate::Loader;
973
974 type Request = crate::WireLoaderLoadObjectRequest<'static>;
975
976 type Response = crate::WireLoaderLoadObjectResponse;
977 }
978
979 pub struct Config;
980
981 impl ::fidl_next::Method for Config {
982 const ORDINAL: u64 = 7676977189692319809;
983
984 type Protocol = crate::Loader;
985
986 type Request = crate::WireLoaderConfigRequest<'static>;
987
988 type Response = crate::WireLoaderConfigResponse;
989 }
990
991 pub struct Clone;
992
993 impl ::fidl_next::Method for Clone {
994 const ORDINAL: u64 = 6333824321947847721;
995
996 type Protocol = crate::Loader;
997
998 type Request = crate::WireLoaderCloneRequest;
999
1000 type Response = crate::WireLoaderCloneResponse;
1001 }
1002
1003 mod ___detail {
1004
1005 pub struct LoadObject<T0> {
1006 object_name: T0,
1007 }
1008
1009 impl<T0> ::fidl_next::Encodable for LoadObject<T0>
1010 where
1011 T0: ::fidl_next::Encodable<Encoded = ::fidl_next::WireString<'static>>,
1012 {
1013 type Encoded = crate::WireLoaderLoadObjectRequest<'static>;
1014 }
1015
1016 unsafe impl<___E, T0> ::fidl_next::Encode<___E> for LoadObject<T0>
1017 where
1018 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1019 ___E: ::fidl_next::Encoder,
1020 T0: ::fidl_next::Encode<___E, Encoded = ::fidl_next::WireString<'static>>,
1021 {
1022 #[inline]
1023 fn encode(
1024 self,
1025 encoder: &mut ___E,
1026 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
1027 ) -> Result<(), ::fidl_next::EncodeError> {
1028 ::fidl_next::munge! {
1029 let Self::Encoded {
1030 object_name,
1031
1032 } = out;
1033 }
1034
1035 ::fidl_next::Encode::encode(self.object_name, encoder, object_name)?;
1036
1037 Ok(())
1038 }
1039 }
1040
1041 pub struct Config<T0> {
1042 config: T0,
1043 }
1044
1045 impl<T0> ::fidl_next::Encodable for Config<T0>
1046 where
1047 T0: ::fidl_next::Encodable<Encoded = ::fidl_next::WireString<'static>>,
1048 {
1049 type Encoded = crate::WireLoaderConfigRequest<'static>;
1050 }
1051
1052 unsafe impl<___E, T0> ::fidl_next::Encode<___E> for Config<T0>
1053 where
1054 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1055 ___E: ::fidl_next::Encoder,
1056 T0: ::fidl_next::Encode<___E, Encoded = ::fidl_next::WireString<'static>>,
1057 {
1058 #[inline]
1059 fn encode(
1060 self,
1061 encoder: &mut ___E,
1062 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
1063 ) -> Result<(), ::fidl_next::EncodeError> {
1064 ::fidl_next::munge! {
1065 let Self::Encoded {
1066 config,
1067
1068 } = out;
1069 }
1070
1071 ::fidl_next::Encode::encode(self.config, encoder, config)?;
1072
1073 Ok(())
1074 }
1075 }
1076
1077 pub struct Clone<T0> {
1078 loader: T0,
1079 }
1080
1081 impl<T0> ::fidl_next::Encodable for Clone<T0>
1082 where
1083 T0: ::fidl_next::Encodable<
1084 Encoded = ::fidl_next::ServerEnd<
1085 crate::Loader,
1086 ::fidl_next::fuchsia::WireChannel,
1087 >,
1088 >,
1089 {
1090 type Encoded = crate::WireLoaderCloneRequest;
1091 }
1092
1093 unsafe impl<___E, T0> ::fidl_next::Encode<___E> for Clone<T0>
1094 where
1095 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1096 ___E: ::fidl_next::fuchsia::HandleEncoder,
1097 T0: ::fidl_next::Encode<
1098 ___E,
1099 Encoded = ::fidl_next::ServerEnd<
1100 crate::Loader,
1101 ::fidl_next::fuchsia::WireChannel,
1102 >,
1103 >,
1104 {
1105 #[inline]
1106 fn encode(
1107 self,
1108 encoder: &mut ___E,
1109 out: &mut ::core::mem::MaybeUninit<Self::Encoded>,
1110 ) -> Result<(), ::fidl_next::EncodeError> {
1111 ::fidl_next::munge! {
1112 let Self::Encoded {
1113 loader,
1114
1115 } = out;
1116 }
1117
1118 ::fidl_next::Encode::encode(self.loader, encoder, loader)?;
1119
1120 Ok(())
1121 }
1122 }
1123
1124 unsafe impl<___T> ::fidl_next::Protocol<___T> for crate::Loader
1125 where
1126 ___T: ::fidl_next::Transport,
1127 {
1128 type ClientSender = LoaderClientSender<___T>;
1129 type ServerSender = LoaderServerSender<___T>;
1130 }
1131
1132 #[repr(transparent)]
1134 pub struct LoaderClientSender<___T: ::fidl_next::Transport> {
1135 #[allow(dead_code)]
1136 sender: ::fidl_next::protocol::ClientSender<___T>,
1137 }
1138
1139 impl<___T> LoaderClientSender<___T>
1140 where
1141 ___T: ::fidl_next::Transport,
1142 {
1143 #[doc = " Cleanly shutdown the connection to the Loader service.\n"]
1144 pub fn done(&self) -> ::fidl_next::SendFuture<'_, ___T> {
1145 ::fidl_next::SendFuture::from_untyped(
1146 self.sender.send_one_way(7186174313520107521, ()),
1147 )
1148 }
1149
1150 #[doc = " The dynamic linker sends `object_name` and gets back a VMO\n handle containing the file.\n"]
1151 pub fn load_object(
1152 &self,
1153
1154 object_name: impl ::fidl_next::Encode<
1155 <___T as ::fidl_next::Transport>::SendBuffer,
1156 Encoded = ::fidl_next::WireString<'static>,
1157 >,
1158 ) -> ::fidl_next::TwoWayFuture<'_, super::LoadObject, ___T>
1159 where
1160 <___T as ::fidl_next::Transport>::SendBuffer:
1161 ::fidl_next::encoder::InternalHandleEncoder,
1162 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
1163 {
1164 self.load_object_with(LoadObject { object_name })
1165 }
1166
1167 #[doc = " The dynamic linker sends `object_name` and gets back a VMO\n handle containing the file.\n"]
1168 pub fn load_object_with<___R>(
1169 &self,
1170 request: ___R,
1171 ) -> ::fidl_next::TwoWayFuture<'_, super::LoadObject, ___T>
1172 where
1173 ___R: ::fidl_next::Encode<
1174 <___T as ::fidl_next::Transport>::SendBuffer,
1175 Encoded = crate::WireLoaderLoadObjectRequest<'static>,
1176 >,
1177 {
1178 ::fidl_next::TwoWayFuture::from_untyped(
1179 self.sender.send_two_way(5243774714012182611, request),
1180 )
1181 }
1182
1183 #[doc = " The dynamic linker sends a `config` identifying its load\n configuration. This is intended to affect how later\n `LoadObject` requests decide what particular implementation\n file to supply for a given name.\n"]
1184 pub fn config(
1185 &self,
1186
1187 config: impl ::fidl_next::Encode<
1188 <___T as ::fidl_next::Transport>::SendBuffer,
1189 Encoded = ::fidl_next::WireString<'static>,
1190 >,
1191 ) -> ::fidl_next::TwoWayFuture<'_, super::Config, ___T>
1192 where
1193 <___T as ::fidl_next::Transport>::SendBuffer:
1194 ::fidl_next::encoder::InternalHandleEncoder,
1195 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
1196 {
1197 self.config_with(Config { config })
1198 }
1199
1200 #[doc = " The dynamic linker sends a `config` identifying its load\n configuration. This is intended to affect how later\n `LoadObject` requests decide what particular implementation\n file to supply for a given name.\n"]
1201 pub fn config_with<___R>(
1202 &self,
1203 request: ___R,
1204 ) -> ::fidl_next::TwoWayFuture<'_, super::Config, ___T>
1205 where
1206 ___R: ::fidl_next::Encode<
1207 <___T as ::fidl_next::Transport>::SendBuffer,
1208 Encoded = crate::WireLoaderConfigRequest<'static>,
1209 >,
1210 {
1211 ::fidl_next::TwoWayFuture::from_untyped(
1212 self.sender.send_two_way(7676977189692319809, request),
1213 )
1214 }
1215
1216 #[doc = " Obtain a new loader service connection.\n"]
1217 pub fn clone(
1218 &self,
1219
1220 loader: impl ::fidl_next::Encode<
1221 <___T as ::fidl_next::Transport>::SendBuffer,
1222 Encoded = ::fidl_next::ServerEnd<
1223 crate::Loader,
1224 ::fidl_next::fuchsia::WireChannel,
1225 >,
1226 >,
1227 ) -> ::fidl_next::TwoWayFuture<'_, super::Clone, ___T>
1228 where
1229 <___T as ::fidl_next::Transport>::SendBuffer:
1230 ::fidl_next::encoder::InternalHandleEncoder,
1231 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
1232 {
1233 self.clone_with(Clone { loader })
1234 }
1235
1236 #[doc = " Obtain a new loader service connection.\n"]
1237 pub fn clone_with<___R>(
1238 &self,
1239 request: ___R,
1240 ) -> ::fidl_next::TwoWayFuture<'_, super::Clone, ___T>
1241 where
1242 ___R: ::fidl_next::Encode<
1243 <___T as ::fidl_next::Transport>::SendBuffer,
1244 Encoded = crate::WireLoaderCloneRequest,
1245 >,
1246 {
1247 ::fidl_next::TwoWayFuture::from_untyped(
1248 self.sender.send_two_way(6333824321947847721, request),
1249 )
1250 }
1251 }
1252
1253 #[repr(transparent)]
1255 pub struct LoaderServerSender<___T: ::fidl_next::Transport> {
1256 sender: ::fidl_next::protocol::ServerSender<___T>,
1257 }
1258
1259 impl<___T> LoaderServerSender<___T> where ___T: ::fidl_next::Transport {}
1260 }
1261}
1262
1263pub trait LoaderClientHandler<
1267 #[cfg(not(feature = "fuchsia"))] ___T: ::fidl_next::Transport,
1268 #[cfg(feature = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
1269>
1270{
1271}
1272
1273impl<___H, ___T> ::fidl_next::DispatchClientMessage<___H, ___T> for Loader
1274where
1275 ___H: LoaderClientHandler<___T> + ::core::marker::Send,
1276 ___T: ::fidl_next::Transport,
1277 <loader::LoadObject as ::fidl_next::Method>::Response:
1278 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
1279 <loader::Config as ::fidl_next::Method>::Response:
1280 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
1281 <loader::Clone as ::fidl_next::Method>::Response:
1282 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
1283{
1284 async fn on_event(
1285 handler: &mut ___H,
1286 sender: &::fidl_next::ClientSender<Self, ___T>,
1287 ordinal: u64,
1288 buffer: ___T::RecvBuffer,
1289 ) {
1290 match ordinal {
1291 ordinal => sender.close(),
1292 }
1293 }
1294}
1295
1296pub trait LoaderServerHandler<
1300 #[cfg(not(feature = "fuchsia"))] ___T: ::fidl_next::Transport,
1301 #[cfg(feature = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
1302>
1303{
1304 #[doc = " Cleanly shutdown the connection to the Loader service.\n"]
1305 fn done(
1306 &mut self,
1307 sender: &::fidl_next::ServerSender<Loader, ___T>,
1308 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
1309
1310 #[doc = " The dynamic linker sends `object_name` and gets back a VMO\n handle containing the file.\n"]
1311 fn load_object(
1312 &mut self,
1313 sender: &::fidl_next::ServerSender<Loader, ___T>,
1314
1315 request: ::fidl_next::Request<loader::LoadObject, ___T>,
1316
1317 responder: ::fidl_next::Responder<loader::LoadObject>,
1318 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
1319
1320 #[doc = " The dynamic linker sends a `config` identifying its load\n configuration. This is intended to affect how later\n `LoadObject` requests decide what particular implementation\n file to supply for a given name.\n"]
1321 fn config(
1322 &mut self,
1323 sender: &::fidl_next::ServerSender<Loader, ___T>,
1324
1325 request: ::fidl_next::Request<loader::Config, ___T>,
1326
1327 responder: ::fidl_next::Responder<loader::Config>,
1328 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
1329
1330 #[doc = " Obtain a new loader service connection.\n"]
1331 fn clone(
1332 &mut self,
1333 sender: &::fidl_next::ServerSender<Loader, ___T>,
1334
1335 request: ::fidl_next::Request<loader::Clone, ___T>,
1336
1337 responder: ::fidl_next::Responder<loader::Clone>,
1338 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
1339}
1340
1341impl<___H, ___T> ::fidl_next::DispatchServerMessage<___H, ___T> for Loader
1342where
1343 ___H: LoaderServerHandler<___T> + ::core::marker::Send,
1344 ___T: ::fidl_next::Transport,
1345 <loader::LoadObject as ::fidl_next::Method>::Request:
1346 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
1347 <loader::Config as ::fidl_next::Method>::Request:
1348 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
1349 <loader::Clone as ::fidl_next::Method>::Request:
1350 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
1351{
1352 async fn on_one_way(
1353 handler: &mut ___H,
1354 sender: &::fidl_next::ServerSender<Self, ___T>,
1355 ordinal: u64,
1356 buffer: ___T::RecvBuffer,
1357 ) {
1358 match ordinal {
1359 7186174313520107521 => {
1360 handler.done(sender).await;
1361 }
1362
1363 ordinal => sender.close(),
1364 }
1365 }
1366
1367 async fn on_two_way(
1368 handler: &mut ___H,
1369 sender: &::fidl_next::ServerSender<Self, ___T>,
1370 ordinal: u64,
1371 buffer: ___T::RecvBuffer,
1372 responder: ::fidl_next::protocol::Responder,
1373 ) {
1374 match ordinal {
1375 5243774714012182611 => {
1376 let responder = ::fidl_next::Responder::from_untyped(responder);
1377
1378 match ::fidl_next::DecoderExt::decode(buffer) {
1379 Ok(decoded) => handler.load_object(sender, decoded, responder).await,
1380 Err(e) => sender.close(),
1381 }
1382 }
1383
1384 7676977189692319809 => {
1385 let responder = ::fidl_next::Responder::from_untyped(responder);
1386
1387 match ::fidl_next::DecoderExt::decode(buffer) {
1388 Ok(decoded) => handler.config(sender, decoded, responder).await,
1389 Err(e) => sender.close(),
1390 }
1391 }
1392
1393 6333824321947847721 => {
1394 let responder = ::fidl_next::Responder::from_untyped(responder);
1395
1396 match ::fidl_next::DecoderExt::decode(buffer) {
1397 Ok(decoded) => handler.clone(sender, decoded, responder).await,
1398 Err(e) => sender.close(),
1399 }
1400 }
1401
1402 ordinal => sender.close(),
1403 }
1404 }
1405}
1406
1407pub mod compat {
1409
1410 impl ::fidl_next::CompatFrom<crate::LoaderLoadObjectRequest>
1411 for ::fidl_fuchsia_ldsvc::LoaderLoadObjectRequest
1412 {
1413 #[inline]
1414 fn compat_from(value: crate::LoaderLoadObjectRequest) -> Self {
1415 Self { object_name: ::fidl_next::CompatFrom::compat_from(value.object_name) }
1416 }
1417 }
1418
1419 impl ::fidl_next::CompatFrom<::fidl_fuchsia_ldsvc::LoaderLoadObjectRequest>
1420 for crate::LoaderLoadObjectRequest
1421 {
1422 #[inline]
1423 fn compat_from(value: ::fidl_fuchsia_ldsvc::LoaderLoadObjectRequest) -> Self {
1424 Self { object_name: ::fidl_next::CompatFrom::compat_from(value.object_name) }
1425 }
1426 }
1427
1428 impl ::fidl_next::CompatFrom<crate::LoaderLoadObjectResponse>
1429 for ::fidl_fuchsia_ldsvc::LoaderLoadObjectResponse
1430 {
1431 #[inline]
1432 fn compat_from(value: crate::LoaderLoadObjectResponse) -> Self {
1433 Self {
1434 rv: ::fidl_next::CompatFrom::compat_from(value.rv),
1435
1436 object: ::fidl_next::CompatFrom::compat_from(value.object),
1437 }
1438 }
1439 }
1440
1441 impl ::fidl_next::CompatFrom<::fidl_fuchsia_ldsvc::LoaderLoadObjectResponse>
1442 for crate::LoaderLoadObjectResponse
1443 {
1444 #[inline]
1445 fn compat_from(value: ::fidl_fuchsia_ldsvc::LoaderLoadObjectResponse) -> Self {
1446 Self {
1447 rv: ::fidl_next::CompatFrom::compat_from(value.rv),
1448
1449 object: ::fidl_next::CompatFrom::compat_from(value.object),
1450 }
1451 }
1452 }
1453
1454 impl ::fidl_next::CompatFrom<crate::LoaderConfigRequest>
1455 for ::fidl_fuchsia_ldsvc::LoaderConfigRequest
1456 {
1457 #[inline]
1458 fn compat_from(value: crate::LoaderConfigRequest) -> Self {
1459 Self { config: ::fidl_next::CompatFrom::compat_from(value.config) }
1460 }
1461 }
1462
1463 impl ::fidl_next::CompatFrom<::fidl_fuchsia_ldsvc::LoaderConfigRequest>
1464 for crate::LoaderConfigRequest
1465 {
1466 #[inline]
1467 fn compat_from(value: ::fidl_fuchsia_ldsvc::LoaderConfigRequest) -> Self {
1468 Self { config: ::fidl_next::CompatFrom::compat_from(value.config) }
1469 }
1470 }
1471
1472 impl ::fidl_next::CompatFrom<crate::LoaderConfigResponse>
1473 for ::fidl_fuchsia_ldsvc::LoaderConfigResponse
1474 {
1475 #[inline]
1476 fn compat_from(value: crate::LoaderConfigResponse) -> Self {
1477 Self { rv: ::fidl_next::CompatFrom::compat_from(value.rv) }
1478 }
1479 }
1480
1481 impl ::fidl_next::CompatFrom<::fidl_fuchsia_ldsvc::LoaderConfigResponse>
1482 for crate::LoaderConfigResponse
1483 {
1484 #[inline]
1485 fn compat_from(value: ::fidl_fuchsia_ldsvc::LoaderConfigResponse) -> Self {
1486 Self { rv: ::fidl_next::CompatFrom::compat_from(value.rv) }
1487 }
1488 }
1489
1490 impl ::fidl_next::CompatFrom<crate::LoaderCloneRequest>
1491 for ::fidl_fuchsia_ldsvc::LoaderCloneRequest
1492 {
1493 #[inline]
1494 fn compat_from(value: crate::LoaderCloneRequest) -> Self {
1495 Self { loader: ::fidl_next::CompatFrom::compat_from(value.loader) }
1496 }
1497 }
1498
1499 impl ::fidl_next::CompatFrom<::fidl_fuchsia_ldsvc::LoaderCloneRequest>
1500 for crate::LoaderCloneRequest
1501 {
1502 #[inline]
1503 fn compat_from(value: ::fidl_fuchsia_ldsvc::LoaderCloneRequest) -> Self {
1504 Self { loader: ::fidl_next::CompatFrom::compat_from(value.loader) }
1505 }
1506 }
1507
1508 impl ::fidl_next::CompatFrom<crate::LoaderCloneResponse>
1509 for ::fidl_fuchsia_ldsvc::LoaderCloneResponse
1510 {
1511 #[inline]
1512 fn compat_from(value: crate::LoaderCloneResponse) -> Self {
1513 Self { rv: ::fidl_next::CompatFrom::compat_from(value.rv) }
1514 }
1515 }
1516
1517 impl ::fidl_next::CompatFrom<::fidl_fuchsia_ldsvc::LoaderCloneResponse>
1518 for crate::LoaderCloneResponse
1519 {
1520 #[inline]
1521 fn compat_from(value: ::fidl_fuchsia_ldsvc::LoaderCloneResponse) -> Self {
1522 Self { rv: ::fidl_next::CompatFrom::compat_from(value.rv) }
1523 }
1524 }
1525
1526 #[cfg(target_os = "fuchsia")]
1527 pub type LoaderProxy = ::fidl_next::ClientSender<crate::Loader>;
1530
1531 impl ::fidl_next::CompatFrom<crate::Loader> for ::fidl_fuchsia_ldsvc::LoaderMarker {
1532 fn compat_from(_: crate::Loader) -> Self {
1533 Self
1534 }
1535 }
1536
1537 impl ::fidl_next::CompatFrom<::fidl_fuchsia_ldsvc::LoaderMarker> for crate::Loader {
1538 fn compat_from(_: ::fidl_fuchsia_ldsvc::LoaderMarker) -> Self {
1539 Self
1540 }
1541 }
1542
1543 #[cfg(target_os = "fuchsia")]
1544
1545 impl ::fidl_next::ClientCompatFrom<::fidl_fuchsia_ldsvc::LoaderProxy> for crate::Loader {
1546 fn client_compat_from(
1547 proxy: ::fidl_fuchsia_ldsvc::LoaderProxy,
1548 ) -> ::fidl_next::Client<Self, ::fidl_next::fuchsia::zx::Channel> {
1549 let channel = ::fidl::endpoints::Proxy::into_channel(proxy).unwrap().into_zx_channel();
1550 let client_end = ::fidl_next::ClientEnd::from_untyped(channel);
1551 ::fidl_next::Client::new(client_end)
1552 }
1553 }
1554}