1#![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_component::natural::*;
8
9 #[doc = " Payload for CapabilityRequested events\n"]
10 #[derive(PartialEq, Debug, Default)]
11 pub struct CapabilityRequestedPayload {
12 pub name: ::core::option::Option<::std::string::String>,
13
14 pub capability: ::core::option::Option<::fidl_next::fuchsia::zx::Channel>,
15 }
16
17 impl CapabilityRequestedPayload {
18 fn __max_ordinal(&self) -> usize {
19 if self.capability.is_some() {
20 return 2;
21 }
22
23 if self.name.is_some() {
24 return 1;
25 }
26
27 0
28 }
29 }
30
31 unsafe impl<___E> ::fidl_next::Encode<crate::wire::CapabilityRequestedPayload<'static>, ___E>
32 for CapabilityRequestedPayload
33 where
34 ___E: ::fidl_next::Encoder + ?Sized,
35 ___E: ::fidl_next::fuchsia::HandleEncoder,
36 {
37 #[inline]
38 fn encode(
39 mut self,
40 encoder: &mut ___E,
41 out: &mut ::core::mem::MaybeUninit<crate::wire::CapabilityRequestedPayload<'static>>,
42 _: (),
43 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
44 ::fidl_next::munge!(let crate::wire::CapabilityRequestedPayload { table } = out);
45
46 let max_ord = self.__max_ordinal();
47
48 let mut out = ::core::mem::MaybeUninit::<::fidl_next::WireEnvelope>::uninit();
49 ::fidl_next::Wire::zero_padding(&mut out);
50
51 let mut preallocated =
52 ::fidl_next::EncoderExt::preallocate::<::fidl_next::WireEnvelope>(encoder, max_ord);
53
54 for i in 1..=max_ord {
55 match i {
56 2 => {
57 if let Some(value) = self.capability.take() {
58 ::fidl_next::WireEnvelope::encode_value::<
59 ::fidl_next::fuchsia::WireChannel,
60 ___E,
61 >(
62 value, preallocated.encoder, &mut out, ()
63 )?;
64 } else {
65 ::fidl_next::WireEnvelope::encode_zero(&mut out)
66 }
67 }
68
69 1 => {
70 if let Some(value) = self.name.take() {
71 ::fidl_next::WireEnvelope::encode_value::<
72 ::fidl_next::WireString<'static>,
73 ___E,
74 >(
75 value, preallocated.encoder, &mut out, 255
76 )?;
77 } else {
78 ::fidl_next::WireEnvelope::encode_zero(&mut out)
79 }
80 }
81
82 _ => ::fidl_next::WireEnvelope::encode_zero(&mut out),
83 }
84 unsafe {
85 preallocated.write_next(out.assume_init_ref());
86 }
87 }
88
89 ::fidl_next::WireTable::encode_len(table, max_ord);
90
91 Ok(())
92 }
93 }
94
95 impl<'de> ::fidl_next::FromWire<crate::wire::CapabilityRequestedPayload<'de>>
96 for CapabilityRequestedPayload
97 {
98 #[inline]
99 fn from_wire(wire_: crate::wire::CapabilityRequestedPayload<'de>) -> Self {
100 let wire_ = ::core::mem::ManuallyDrop::new(wire_);
101
102 let name = wire_.table.get(1);
103
104 let capability = wire_.table.get(2);
105
106 Self {
107 name: name.map(|envelope| {
108 ::fidl_next::FromWire::from_wire(unsafe {
109 envelope.read_unchecked::<::fidl_next::WireString<'de>>()
110 })
111 }),
112
113 capability: capability.map(|envelope| {
114 ::fidl_next::FromWire::from_wire(unsafe {
115 envelope.read_unchecked::<::fidl_next::fuchsia::WireChannel>()
116 })
117 }),
118 }
119 }
120 }
121
122 #[derive(PartialEq, Debug)]
123 #[repr(C)]
124 pub struct ControllerIsStartedResponse {
125 pub is_started: bool,
126 }
127
128 unsafe impl<___E> ::fidl_next::Encode<crate::wire::ControllerIsStartedResponse, ___E>
129 for ControllerIsStartedResponse
130 where
131 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
132 ___E: ::fidl_next::fuchsia::HandleEncoder,
133 {
134 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<
135 Self,
136 crate::wire::ControllerIsStartedResponse,
137 > = unsafe {
138 ::fidl_next::CopyOptimization::enable_if(
139 true && <bool as ::fidl_next::Encode<bool, ___E>>::COPY_OPTIMIZATION.is_enabled(),
140 )
141 };
142
143 #[inline]
144 fn encode(
145 self,
146 encoder_: &mut ___E,
147 out_: &mut ::core::mem::MaybeUninit<crate::wire::ControllerIsStartedResponse>,
148 _: (),
149 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
150 ::fidl_next::munge! {
151 let crate::wire::ControllerIsStartedResponse {
152 is_started,
153
154 } = out_;
155 }
156
157 ::fidl_next::Encode::encode(self.is_started, encoder_, is_started, ())?;
158
159 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(is_started.as_mut_ptr()) };
160
161 Ok(())
162 }
163 }
164
165 unsafe impl<___E>
166 ::fidl_next::EncodeOption<
167 ::fidl_next::WireBox<'static, crate::wire::ControllerIsStartedResponse>,
168 ___E,
169 > for ControllerIsStartedResponse
170 where
171 ___E: ::fidl_next::Encoder + ?Sized,
172 ControllerIsStartedResponse:
173 ::fidl_next::Encode<crate::wire::ControllerIsStartedResponse, ___E>,
174 {
175 #[inline]
176 fn encode_option(
177 this: ::core::option::Option<Self>,
178 encoder: &mut ___E,
179 out: &mut ::core::mem::MaybeUninit<
180 ::fidl_next::WireBox<'static, crate::wire::ControllerIsStartedResponse>,
181 >,
182 _: (),
183 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
184 if let Some(inner) = this {
185 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
186 ::fidl_next::WireBox::encode_present(out);
187 } else {
188 ::fidl_next::WireBox::encode_absent(out);
189 }
190
191 Ok(())
192 }
193 }
194
195 impl ::fidl_next::FromWire<crate::wire::ControllerIsStartedResponse>
196 for ControllerIsStartedResponse
197 {
198 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<
199 crate::wire::ControllerIsStartedResponse,
200 Self,
201 > = unsafe {
202 ::fidl_next::CopyOptimization::enable_if(
203 true && <bool as ::fidl_next::FromWire<bool>>::COPY_OPTIMIZATION.is_enabled(),
204 )
205 };
206
207 #[inline]
208 fn from_wire(wire: crate::wire::ControllerIsStartedResponse) -> Self {
209 Self { is_started: ::fidl_next::FromWire::from_wire(wire.is_started) }
210 }
211 }
212
213 #[derive(PartialEq, Debug)]
214 #[repr(C)]
215 pub struct ControllerGetExposedDictionaryResponse {
216 pub dictionary: ::fidl_next_fuchsia_component_sandbox::natural::DictionaryRef,
217 }
218
219 unsafe impl<___E> ::fidl_next::Encode<crate::wire::ControllerGetExposedDictionaryResponse, ___E>
220 for ControllerGetExposedDictionaryResponse
221 where
222 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
223 ___E: ::fidl_next::fuchsia::HandleEncoder,
224 {
225 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<
226 Self,
227 crate::wire::ControllerGetExposedDictionaryResponse,
228 > = unsafe {
229 ::fidl_next::CopyOptimization::enable_if(
230 true
231
232 && <
233 ::fidl_next_fuchsia_component_sandbox::natural::DictionaryRef as ::fidl_next::Encode<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef, ___E>
234 >::COPY_OPTIMIZATION.is_enabled()
235
236 )
237 };
238
239 #[inline]
240 fn encode(
241 self,
242 encoder_: &mut ___E,
243 out_: &mut ::core::mem::MaybeUninit<
244 crate::wire::ControllerGetExposedDictionaryResponse,
245 >,
246 _: (),
247 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
248 ::fidl_next::munge! {
249 let crate::wire::ControllerGetExposedDictionaryResponse {
250 dictionary,
251
252 } = out_;
253 }
254
255 ::fidl_next::Encode::encode(self.dictionary, encoder_, dictionary, ())?;
256
257 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(dictionary.as_mut_ptr()) };
258
259 Ok(())
260 }
261 }
262
263 unsafe impl<___E>
264 ::fidl_next::EncodeOption<
265 ::fidl_next::WireBox<'static, crate::wire::ControllerGetExposedDictionaryResponse>,
266 ___E,
267 > for ControllerGetExposedDictionaryResponse
268 where
269 ___E: ::fidl_next::Encoder + ?Sized,
270 ControllerGetExposedDictionaryResponse:
271 ::fidl_next::Encode<crate::wire::ControllerGetExposedDictionaryResponse, ___E>,
272 {
273 #[inline]
274 fn encode_option(
275 this: ::core::option::Option<Self>,
276 encoder: &mut ___E,
277 out: &mut ::core::mem::MaybeUninit<
278 ::fidl_next::WireBox<'static, crate::wire::ControllerGetExposedDictionaryResponse>,
279 >,
280 _: (),
281 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
282 if let Some(inner) = this {
283 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
284 ::fidl_next::WireBox::encode_present(out);
285 } else {
286 ::fidl_next::WireBox::encode_absent(out);
287 }
288
289 Ok(())
290 }
291 }
292
293 impl ::fidl_next::FromWire<crate::wire::ControllerGetExposedDictionaryResponse>
294 for ControllerGetExposedDictionaryResponse
295 {
296 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<
297 crate::wire::ControllerGetExposedDictionaryResponse,
298 Self,
299 > = unsafe {
300 ::fidl_next::CopyOptimization::enable_if(
301 true
302
303 && <
304 ::fidl_next_fuchsia_component_sandbox::natural::DictionaryRef as ::fidl_next::FromWire<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef>
305 >::COPY_OPTIMIZATION.is_enabled()
306
307 )
308 };
309
310 #[inline]
311 fn from_wire(wire: crate::wire::ControllerGetExposedDictionaryResponse) -> Self {
312 Self { dictionary: ::fidl_next::FromWire::from_wire(wire.dictionary) }
313 }
314 }
315
316 #[doc = " A single component namespace entry, which describes a namespace mount point\n (`path`) and the directory backing it (`directory`). This type is usually\n composed inside a vector. See `ComponentStartInfo.ns` for more details.\n"]
317 #[derive(PartialEq, Debug, Default)]
318 pub struct NamespaceEntry {
319 pub path: ::core::option::Option<::std::string::String>,
320
321 pub directory: ::core::option::Option<
322 ::fidl_next::ClientEnd<
323 ::fidl_next_fuchsia_io::Directory,
324 ::fidl_next::fuchsia::zx::Channel,
325 >,
326 >,
327 }
328
329 impl NamespaceEntry {
330 fn __max_ordinal(&self) -> usize {
331 if self.directory.is_some() {
332 return 2;
333 }
334
335 if self.path.is_some() {
336 return 1;
337 }
338
339 0
340 }
341 }
342
343 unsafe impl<___E> ::fidl_next::Encode<crate::wire::NamespaceEntry<'static>, ___E> for NamespaceEntry
344 where
345 ___E: ::fidl_next::Encoder + ?Sized,
346 ___E: ::fidl_next::fuchsia::HandleEncoder,
347 {
348 #[inline]
349 fn encode(
350 mut self,
351 encoder: &mut ___E,
352 out: &mut ::core::mem::MaybeUninit<crate::wire::NamespaceEntry<'static>>,
353 _: (),
354 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
355 ::fidl_next::munge!(let crate::wire::NamespaceEntry { table } = out);
356
357 let max_ord = self.__max_ordinal();
358
359 let mut out = ::core::mem::MaybeUninit::<::fidl_next::WireEnvelope>::uninit();
360 ::fidl_next::Wire::zero_padding(&mut out);
361
362 let mut preallocated =
363 ::fidl_next::EncoderExt::preallocate::<::fidl_next::WireEnvelope>(encoder, max_ord);
364
365 for i in 1..=max_ord {
366 match i {
367 2 => {
368 if let Some(value) = self.directory.take() {
369 ::fidl_next::WireEnvelope::encode_value::<
370 ::fidl_next::ClientEnd<
371 ::fidl_next_fuchsia_io::Directory,
372 ::fidl_next::fuchsia::WireChannel,
373 >,
374 ___E,
375 >(
376 value, preallocated.encoder, &mut out, ()
377 )?;
378 } else {
379 ::fidl_next::WireEnvelope::encode_zero(&mut out)
380 }
381 }
382
383 1 => {
384 if let Some(value) = self.path.take() {
385 ::fidl_next::WireEnvelope::encode_value::<
386 ::fidl_next::WireString<'static>,
387 ___E,
388 >(
389 value, preallocated.encoder, &mut out, 4095
390 )?;
391 } else {
392 ::fidl_next::WireEnvelope::encode_zero(&mut out)
393 }
394 }
395
396 _ => ::fidl_next::WireEnvelope::encode_zero(&mut out),
397 }
398 unsafe {
399 preallocated.write_next(out.assume_init_ref());
400 }
401 }
402
403 ::fidl_next::WireTable::encode_len(table, max_ord);
404
405 Ok(())
406 }
407 }
408
409 impl<'de> ::fidl_next::FromWire<crate::wire::NamespaceEntry<'de>> for NamespaceEntry {
410 #[inline]
411 fn from_wire(wire_: crate::wire::NamespaceEntry<'de>) -> Self {
412 let wire_ = ::core::mem::ManuallyDrop::new(wire_);
413
414 let path = wire_.table.get(1);
415
416 let directory = wire_.table.get(2);
417
418 Self {
419 path: path.map(|envelope| {
420 ::fidl_next::FromWire::from_wire(unsafe {
421 envelope.read_unchecked::<::fidl_next::WireString<'de>>()
422 })
423 }),
424
425 directory: directory.map(|envelope| {
426 ::fidl_next::FromWire::from_wire(unsafe {
427 envelope.read_unchecked::<::fidl_next::ClientEnd<
428 ::fidl_next_fuchsia_io::Directory,
429 ::fidl_next::fuchsia::WireChannel,
430 >>()
431 })
432 }),
433 }
434 }
435 }
436
437 #[derive(PartialEq, Debug, Default)]
438 pub struct StartChildArgs {
439 pub numbered_handles: ::core::option::Option<
440 ::std::vec::Vec<::fidl_next_fuchsia_process::natural::HandleInfo>,
441 >,
442
443 pub namespace_entries:
444 ::core::option::Option<::std::vec::Vec<crate::natural::NamespaceEntry>>,
445
446 pub dictionary:
447 ::core::option::Option<::fidl_next_fuchsia_component_sandbox::natural::DictionaryRef>,
448 }
449
450 impl StartChildArgs {
451 fn __max_ordinal(&self) -> usize {
452 if self.dictionary.is_some() {
453 return 3;
454 }
455
456 if self.namespace_entries.is_some() {
457 return 2;
458 }
459
460 if self.numbered_handles.is_some() {
461 return 1;
462 }
463
464 0
465 }
466 }
467
468 unsafe impl<___E> ::fidl_next::Encode<crate::wire::StartChildArgs<'static>, ___E> for StartChildArgs
469 where
470 ___E: ::fidl_next::Encoder + ?Sized,
471 ___E: ::fidl_next::fuchsia::HandleEncoder,
472 {
473 #[inline]
474 fn encode(
475 mut self,
476 encoder: &mut ___E,
477 out: &mut ::core::mem::MaybeUninit<crate::wire::StartChildArgs<'static>>,
478 _: (),
479 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
480 ::fidl_next::munge!(let crate::wire::StartChildArgs { table } = out);
481
482 let max_ord = self.__max_ordinal();
483
484 let mut out = ::core::mem::MaybeUninit::<::fidl_next::WireEnvelope>::uninit();
485 ::fidl_next::Wire::zero_padding(&mut out);
486
487 let mut preallocated =
488 ::fidl_next::EncoderExt::preallocate::<::fidl_next::WireEnvelope>(encoder, max_ord);
489
490 for i in 1..=max_ord {
491 match i {
492 3 => {
493 if let Some(value) = self.dictionary.take() {
494 ::fidl_next::WireEnvelope::encode_value::<
495 ::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef,
496 ___E,
497 >(
498 value, preallocated.encoder, &mut out, ()
499 )?;
500 } else {
501 ::fidl_next::WireEnvelope::encode_zero(&mut out)
502 }
503 }
504
505 2 => {
506 if let Some(value) = self.namespace_entries.take() {
507 ::fidl_next::WireEnvelope::encode_value::<
508 ::fidl_next::WireVector<
509 'static,
510 crate::wire::NamespaceEntry<'static>,
511 >,
512 ___E,
513 >(
514 value, preallocated.encoder, &mut out, (32, ())
515 )?;
516 } else {
517 ::fidl_next::WireEnvelope::encode_zero(&mut out)
518 }
519 }
520
521 1 => {
522 if let Some(value) = self.numbered_handles.take() {
523 ::fidl_next::WireEnvelope::encode_value::<
524 ::fidl_next::WireVector<
525 'static,
526 ::fidl_next_fuchsia_process::wire::HandleInfo,
527 >,
528 ___E,
529 >(
530 value, preallocated.encoder, &mut out, (128, ())
531 )?;
532 } else {
533 ::fidl_next::WireEnvelope::encode_zero(&mut out)
534 }
535 }
536
537 _ => ::fidl_next::WireEnvelope::encode_zero(&mut out),
538 }
539 unsafe {
540 preallocated.write_next(out.assume_init_ref());
541 }
542 }
543
544 ::fidl_next::WireTable::encode_len(table, max_ord);
545
546 Ok(())
547 }
548 }
549
550 impl<'de> ::fidl_next::FromWire<crate::wire::StartChildArgs<'de>> for StartChildArgs {
551 #[inline]
552 fn from_wire(wire_: crate::wire::StartChildArgs<'de>) -> Self {
553 let wire_ = ::core::mem::ManuallyDrop::new(wire_);
554
555 let numbered_handles = wire_.table.get(1);
556
557 let namespace_entries = wire_.table.get(2);
558
559 let dictionary = wire_.table.get(3);
560
561 Self {
562
563
564 numbered_handles: numbered_handles.map(|envelope| ::fidl_next::FromWire::from_wire(
565 unsafe { envelope.read_unchecked::<::fidl_next::WireVector<'de, ::fidl_next_fuchsia_process::wire::HandleInfo>>() }
566 )),
567
568
569 namespace_entries: namespace_entries.map(|envelope| ::fidl_next::FromWire::from_wire(
570 unsafe { envelope.read_unchecked::<::fidl_next::WireVector<'de, crate::wire::NamespaceEntry<'de>>>() }
571 )),
572
573
574 dictionary: dictionary.map(|envelope| ::fidl_next::FromWire::from_wire(
575 unsafe { envelope.read_unchecked::<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef>() }
576 )),
577
578 }
579 }
580 }
581
582 #[derive(PartialEq, Debug)]
583 pub struct ControllerStartRequest {
584 pub args: crate::natural::StartChildArgs,
585
586 pub execution_controller:
587 ::fidl_next::ServerEnd<crate::ExecutionController, ::fidl_next::fuchsia::zx::Channel>,
588 }
589
590 unsafe impl<___E> ::fidl_next::Encode<crate::wire::ControllerStartRequest<'static>, ___E>
591 for ControllerStartRequest
592 where
593 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
594 ___E: ::fidl_next::Encoder,
595 ___E: ::fidl_next::fuchsia::HandleEncoder,
596 {
597 #[inline]
598 fn encode(
599 self,
600 encoder_: &mut ___E,
601 out_: &mut ::core::mem::MaybeUninit<crate::wire::ControllerStartRequest<'static>>,
602 _: (),
603 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
604 ::fidl_next::munge! {
605 let crate::wire::ControllerStartRequest {
606 args,
607 execution_controller,
608
609 } = out_;
610 }
611
612 ::fidl_next::Encode::encode(self.args, encoder_, args, ())?;
613
614 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(args.as_mut_ptr()) };
615
616 ::fidl_next::Encode::encode(
617 self.execution_controller,
618 encoder_,
619 execution_controller,
620 (),
621 )?;
622
623 let mut _field =
624 unsafe { ::fidl_next::Slot::new_unchecked(execution_controller.as_mut_ptr()) };
625
626 Ok(())
627 }
628 }
629
630 unsafe impl<___E>
631 ::fidl_next::EncodeOption<
632 ::fidl_next::WireBox<'static, crate::wire::ControllerStartRequest<'static>>,
633 ___E,
634 > for ControllerStartRequest
635 where
636 ___E: ::fidl_next::Encoder + ?Sized,
637 ControllerStartRequest:
638 ::fidl_next::Encode<crate::wire::ControllerStartRequest<'static>, ___E>,
639 {
640 #[inline]
641 fn encode_option(
642 this: ::core::option::Option<Self>,
643 encoder: &mut ___E,
644 out: &mut ::core::mem::MaybeUninit<
645 ::fidl_next::WireBox<'static, crate::wire::ControllerStartRequest<'static>>,
646 >,
647 _: (),
648 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
649 if let Some(inner) = this {
650 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
651 ::fidl_next::WireBox::encode_present(out);
652 } else {
653 ::fidl_next::WireBox::encode_absent(out);
654 }
655
656 Ok(())
657 }
658 }
659
660 impl<'de> ::fidl_next::FromWire<crate::wire::ControllerStartRequest<'de>>
661 for ControllerStartRequest
662 {
663 #[inline]
664 fn from_wire(wire: crate::wire::ControllerStartRequest<'de>) -> Self {
665 Self {
666 args: ::fidl_next::FromWire::from_wire(wire.args),
667
668 execution_controller: ::fidl_next::FromWire::from_wire(wire.execution_controller),
669 }
670 }
671 }
672
673 #[derive(PartialEq, Debug, Default)]
674 pub struct CreateChildArgs {
675 pub numbered_handles: ::core::option::Option<
676 ::std::vec::Vec<::fidl_next_fuchsia_process::natural::HandleInfo>,
677 >,
678
679 pub dynamic_offers: ::core::option::Option<
680 ::std::vec::Vec<::fidl_next_fuchsia_component_decl::natural::Offer>,
681 >,
682
683 pub controller: ::core::option::Option<
684 ::fidl_next::ServerEnd<crate::Controller, ::fidl_next::fuchsia::zx::Channel>,
685 >,
686
687 pub dictionary:
688 ::core::option::Option<::fidl_next_fuchsia_component_sandbox::natural::DictionaryRef>,
689 }
690
691 impl CreateChildArgs {
692 fn __max_ordinal(&self) -> usize {
693 if self.dictionary.is_some() {
694 return 4;
695 }
696
697 if self.controller.is_some() {
698 return 3;
699 }
700
701 if self.dynamic_offers.is_some() {
702 return 2;
703 }
704
705 if self.numbered_handles.is_some() {
706 return 1;
707 }
708
709 0
710 }
711 }
712
713 unsafe impl<___E> ::fidl_next::Encode<crate::wire::CreateChildArgs<'static>, ___E>
714 for CreateChildArgs
715 where
716 ___E: ::fidl_next::Encoder + ?Sized,
717 ___E: ::fidl_next::fuchsia::HandleEncoder,
718 {
719 #[inline]
720 fn encode(
721 mut self,
722 encoder: &mut ___E,
723 out: &mut ::core::mem::MaybeUninit<crate::wire::CreateChildArgs<'static>>,
724 _: (),
725 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
726 ::fidl_next::munge!(let crate::wire::CreateChildArgs { table } = out);
727
728 let max_ord = self.__max_ordinal();
729
730 let mut out = ::core::mem::MaybeUninit::<::fidl_next::WireEnvelope>::uninit();
731 ::fidl_next::Wire::zero_padding(&mut out);
732
733 let mut preallocated =
734 ::fidl_next::EncoderExt::preallocate::<::fidl_next::WireEnvelope>(encoder, max_ord);
735
736 for i in 1..=max_ord {
737 match i {
738 4 => {
739 if let Some(value) = self.dictionary.take() {
740 ::fidl_next::WireEnvelope::encode_value::<
741 ::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef,
742 ___E,
743 >(
744 value, preallocated.encoder, &mut out, ()
745 )?;
746 } else {
747 ::fidl_next::WireEnvelope::encode_zero(&mut out)
748 }
749 }
750
751 3 => {
752 if let Some(value) = self.controller.take() {
753 ::fidl_next::WireEnvelope::encode_value::<
754 ::fidl_next::ServerEnd<
755 crate::Controller,
756 ::fidl_next::fuchsia::WireChannel,
757 >,
758 ___E,
759 >(
760 value, preallocated.encoder, &mut out, ()
761 )?;
762 } else {
763 ::fidl_next::WireEnvelope::encode_zero(&mut out)
764 }
765 }
766
767 2 => {
768 if let Some(value) = self.dynamic_offers.take() {
769 ::fidl_next::WireEnvelope::encode_value::<
770 ::fidl_next::WireVector<
771 'static,
772 ::fidl_next_fuchsia_component_decl::wire::Offer<'static>,
773 >,
774 ___E,
775 >(
776 value, preallocated.encoder, &mut out, (128, ())
777 )?;
778 } else {
779 ::fidl_next::WireEnvelope::encode_zero(&mut out)
780 }
781 }
782
783 1 => {
784 if let Some(value) = self.numbered_handles.take() {
785 ::fidl_next::WireEnvelope::encode_value::<
786 ::fidl_next::WireVector<
787 'static,
788 ::fidl_next_fuchsia_process::wire::HandleInfo,
789 >,
790 ___E,
791 >(
792 value, preallocated.encoder, &mut out, (128, ())
793 )?;
794 } else {
795 ::fidl_next::WireEnvelope::encode_zero(&mut out)
796 }
797 }
798
799 _ => ::fidl_next::WireEnvelope::encode_zero(&mut out),
800 }
801 unsafe {
802 preallocated.write_next(out.assume_init_ref());
803 }
804 }
805
806 ::fidl_next::WireTable::encode_len(table, max_ord);
807
808 Ok(())
809 }
810 }
811
812 impl<'de> ::fidl_next::FromWire<crate::wire::CreateChildArgs<'de>> for CreateChildArgs {
813 #[inline]
814 fn from_wire(wire_: crate::wire::CreateChildArgs<'de>) -> Self {
815 let wire_ = ::core::mem::ManuallyDrop::new(wire_);
816
817 let numbered_handles = wire_.table.get(1);
818
819 let dynamic_offers = wire_.table.get(2);
820
821 let controller = wire_.table.get(3);
822
823 let dictionary = wire_.table.get(4);
824
825 Self {
826
827
828 numbered_handles: numbered_handles.map(|envelope| ::fidl_next::FromWire::from_wire(
829 unsafe { envelope.read_unchecked::<::fidl_next::WireVector<'de, ::fidl_next_fuchsia_process::wire::HandleInfo>>() }
830 )),
831
832
833 dynamic_offers: dynamic_offers.map(|envelope| ::fidl_next::FromWire::from_wire(
834 unsafe { envelope.read_unchecked::<::fidl_next::WireVector<'de, ::fidl_next_fuchsia_component_decl::wire::Offer<'de>>>() }
835 )),
836
837
838 controller: controller.map(|envelope| ::fidl_next::FromWire::from_wire(
839 unsafe { envelope.read_unchecked::<::fidl_next::ServerEnd<crate::Controller, ::fidl_next::fuchsia::WireChannel>>() }
840 )),
841
842
843 dictionary: dictionary.map(|envelope| ::fidl_next::FromWire::from_wire(
844 unsafe { envelope.read_unchecked::<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef>() }
845 )),
846
847 }
848 }
849 }
850
851 #[doc = " Payload for DebugStarted events.\n"]
852 #[derive(PartialEq, Debug, Default)]
853 pub struct DebugStartedPayload {
854 pub runtime_dir: ::core::option::Option<
855 ::fidl_next::ClientEnd<
856 ::fidl_next_fuchsia_io::Directory,
857 ::fidl_next::fuchsia::zx::Channel,
858 >,
859 >,
860
861 pub break_on_start: ::core::option::Option<::fidl_next::fuchsia::zx::EventPair>,
862 }
863
864 impl DebugStartedPayload {
865 fn __max_ordinal(&self) -> usize {
866 if self.break_on_start.is_some() {
867 return 2;
868 }
869
870 if self.runtime_dir.is_some() {
871 return 1;
872 }
873
874 0
875 }
876 }
877
878 unsafe impl<___E> ::fidl_next::Encode<crate::wire::DebugStartedPayload<'static>, ___E>
879 for DebugStartedPayload
880 where
881 ___E: ::fidl_next::Encoder + ?Sized,
882 ___E: ::fidl_next::fuchsia::HandleEncoder,
883 {
884 #[inline]
885 fn encode(
886 mut self,
887 encoder: &mut ___E,
888 out: &mut ::core::mem::MaybeUninit<crate::wire::DebugStartedPayload<'static>>,
889 _: (),
890 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
891 ::fidl_next::munge!(let crate::wire::DebugStartedPayload { table } = out);
892
893 let max_ord = self.__max_ordinal();
894
895 let mut out = ::core::mem::MaybeUninit::<::fidl_next::WireEnvelope>::uninit();
896 ::fidl_next::Wire::zero_padding(&mut out);
897
898 let mut preallocated =
899 ::fidl_next::EncoderExt::preallocate::<::fidl_next::WireEnvelope>(encoder, max_ord);
900
901 for i in 1..=max_ord {
902 match i {
903 2 => {
904 if let Some(value) = self.break_on_start.take() {
905 ::fidl_next::WireEnvelope::encode_value::<
906 ::fidl_next::fuchsia::WireEventPair,
907 ___E,
908 >(
909 value, preallocated.encoder, &mut out, ()
910 )?;
911 } else {
912 ::fidl_next::WireEnvelope::encode_zero(&mut out)
913 }
914 }
915
916 1 => {
917 if let Some(value) = self.runtime_dir.take() {
918 ::fidl_next::WireEnvelope::encode_value::<
919 ::fidl_next::ClientEnd<
920 ::fidl_next_fuchsia_io::Directory,
921 ::fidl_next::fuchsia::WireChannel,
922 >,
923 ___E,
924 >(
925 value, preallocated.encoder, &mut out, ()
926 )?;
927 } else {
928 ::fidl_next::WireEnvelope::encode_zero(&mut out)
929 }
930 }
931
932 _ => ::fidl_next::WireEnvelope::encode_zero(&mut out),
933 }
934 unsafe {
935 preallocated.write_next(out.assume_init_ref());
936 }
937 }
938
939 ::fidl_next::WireTable::encode_len(table, max_ord);
940
941 Ok(())
942 }
943 }
944
945 impl<'de> ::fidl_next::FromWire<crate::wire::DebugStartedPayload<'de>> for DebugStartedPayload {
946 #[inline]
947 fn from_wire(wire_: crate::wire::DebugStartedPayload<'de>) -> Self {
948 let wire_ = ::core::mem::ManuallyDrop::new(wire_);
949
950 let runtime_dir = wire_.table.get(1);
951
952 let break_on_start = wire_.table.get(2);
953
954 Self {
955 runtime_dir: runtime_dir.map(|envelope| {
956 ::fidl_next::FromWire::from_wire(unsafe {
957 envelope.read_unchecked::<::fidl_next::ClientEnd<
958 ::fidl_next_fuchsia_io::Directory,
959 ::fidl_next::fuchsia::WireChannel,
960 >>()
961 })
962 }),
963
964 break_on_start: break_on_start.map(|envelope| {
965 ::fidl_next::FromWire::from_wire(unsafe {
966 envelope.read_unchecked::<::fidl_next::fuchsia::WireEventPair>()
967 })
968 }),
969 }
970 }
971 }
972
973 #[doc = " Encapsulates additional data/protocols for some event types.\n"]
974 #[derive(PartialEq, Debug)]
975 pub enum EventPayload {
976 CapabilityRequested(crate::natural::CapabilityRequestedPayload),
977
978 Purged(crate::natural::PurgedPayload),
979
980 Discovered(crate::natural::DiscoveredPayload),
981
982 Destroyed(crate::natural::DestroyedPayload),
983
984 Resolved(crate::natural::ResolvedPayload),
985
986 Started(crate::natural::StartedPayload),
987
988 Stopped(crate::natural::StoppedPayload),
989
990 DebugStarted(crate::natural::DebugStartedPayload),
991
992 Unresolved(crate::natural::UnresolvedPayload),
993
994 UnknownOrdinal_(u64),
995 }
996
997 impl EventPayload {
998 pub fn is_unknown(&self) -> bool {
999 #[allow(unreachable_patterns)]
1000 match self {
1001 Self::UnknownOrdinal_(_) => true,
1002 _ => false,
1003 }
1004 }
1005 }
1006
1007 unsafe impl<___E> ::fidl_next::Encode<crate::wire::EventPayload<'static>, ___E> for EventPayload
1008 where
1009 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1010 ___E: ::fidl_next::Encoder,
1011 ___E: ::fidl_next::fuchsia::HandleEncoder,
1012 {
1013 #[inline]
1014 fn encode(
1015 self,
1016 encoder: &mut ___E,
1017 out: &mut ::core::mem::MaybeUninit<crate::wire::EventPayload<'static>>,
1018 _: (),
1019 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1020 ::fidl_next::munge!(let crate::wire::EventPayload { raw, _phantom: _ } = out);
1021
1022 match self {
1023 Self::CapabilityRequested(value) => ::fidl_next::RawWireUnion::encode_as::<
1024 ___E,
1025 crate::wire::CapabilityRequestedPayload<'static>,
1026 >(value, 1, encoder, raw, ())?,
1027
1028 Self::Purged(value) => ::fidl_next::RawWireUnion::encode_as::<
1029 ___E,
1030 crate::wire::PurgedPayload<'static>,
1031 >(value, 2, encoder, raw, ())?,
1032
1033 Self::Discovered(value) => ::fidl_next::RawWireUnion::encode_as::<
1034 ___E,
1035 crate::wire::DiscoveredPayload<'static>,
1036 >(value, 4, encoder, raw, ())?,
1037
1038 Self::Destroyed(value) => ::fidl_next::RawWireUnion::encode_as::<
1039 ___E,
1040 crate::wire::DestroyedPayload<'static>,
1041 >(value, 5, encoder, raw, ())?,
1042
1043 Self::Resolved(value) => ::fidl_next::RawWireUnion::encode_as::<
1044 ___E,
1045 crate::wire::ResolvedPayload<'static>,
1046 >(value, 6, encoder, raw, ())?,
1047
1048 Self::Started(value) => ::fidl_next::RawWireUnion::encode_as::<
1049 ___E,
1050 crate::wire::StartedPayload<'static>,
1051 >(value, 7, encoder, raw, ())?,
1052
1053 Self::Stopped(value) => ::fidl_next::RawWireUnion::encode_as::<
1054 ___E,
1055 crate::wire::StoppedPayload<'static>,
1056 >(value, 8, encoder, raw, ())?,
1057
1058 Self::DebugStarted(value) => ::fidl_next::RawWireUnion::encode_as::<
1059 ___E,
1060 crate::wire::DebugStartedPayload<'static>,
1061 >(value, 9, encoder, raw, ())?,
1062
1063 Self::Unresolved(value) => ::fidl_next::RawWireUnion::encode_as::<
1064 ___E,
1065 crate::wire::UnresolvedPayload<'static>,
1066 >(value, 10, encoder, raw, ())?,
1067
1068 Self::UnknownOrdinal_(ordinal) => {
1069 return Err(::fidl_next::EncodeError::UnknownUnionOrdinal(ordinal as usize));
1070 }
1071 }
1072
1073 Ok(())
1074 }
1075 }
1076
1077 unsafe impl<___E> ::fidl_next::EncodeOption<crate::wire_optional::EventPayload<'static>, ___E>
1078 for EventPayload
1079 where
1080 ___E: ?Sized,
1081 EventPayload: ::fidl_next::Encode<crate::wire::EventPayload<'static>, ___E>,
1082 {
1083 #[inline]
1084 fn encode_option(
1085 this: ::core::option::Option<Self>,
1086 encoder: &mut ___E,
1087 out: &mut ::core::mem::MaybeUninit<crate::wire_optional::EventPayload<'static>>,
1088 _: (),
1089 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1090 ::fidl_next::munge!(let crate::wire_optional::EventPayload { raw, _phantom: _ } = &mut *out);
1091
1092 if let Some(inner) = this {
1093 let value_out = unsafe { &mut *out.as_mut_ptr().cast() };
1094 ::fidl_next::Encode::encode(inner, encoder, value_out, ())?;
1095 } else {
1096 ::fidl_next::RawWireUnion::encode_absent(raw);
1097 }
1098
1099 Ok(())
1100 }
1101 }
1102
1103 impl<'de> ::fidl_next::FromWire<crate::wire::EventPayload<'de>> for EventPayload {
1104 #[inline]
1105 fn from_wire(wire: crate::wire::EventPayload<'de>) -> Self {
1106 let wire = ::core::mem::ManuallyDrop::new(wire);
1107 match wire.raw.ordinal() {
1108 1 => Self::CapabilityRequested(::fidl_next::FromWire::from_wire(unsafe {
1109 wire.raw.get().read_unchecked::<crate::wire::CapabilityRequestedPayload<'de>>()
1110 })),
1111
1112 2 => Self::Purged(::fidl_next::FromWire::from_wire(unsafe {
1113 wire.raw.get().read_unchecked::<crate::wire::PurgedPayload<'de>>()
1114 })),
1115
1116 4 => Self::Discovered(::fidl_next::FromWire::from_wire(unsafe {
1117 wire.raw.get().read_unchecked::<crate::wire::DiscoveredPayload<'de>>()
1118 })),
1119
1120 5 => Self::Destroyed(::fidl_next::FromWire::from_wire(unsafe {
1121 wire.raw.get().read_unchecked::<crate::wire::DestroyedPayload<'de>>()
1122 })),
1123
1124 6 => Self::Resolved(::fidl_next::FromWire::from_wire(unsafe {
1125 wire.raw.get().read_unchecked::<crate::wire::ResolvedPayload<'de>>()
1126 })),
1127
1128 7 => Self::Started(::fidl_next::FromWire::from_wire(unsafe {
1129 wire.raw.get().read_unchecked::<crate::wire::StartedPayload<'de>>()
1130 })),
1131
1132 8 => Self::Stopped(::fidl_next::FromWire::from_wire(unsafe {
1133 wire.raw.get().read_unchecked::<crate::wire::StoppedPayload<'de>>()
1134 })),
1135
1136 9 => Self::DebugStarted(::fidl_next::FromWire::from_wire(unsafe {
1137 wire.raw.get().read_unchecked::<crate::wire::DebugStartedPayload<'de>>()
1138 })),
1139
1140 10 => Self::Unresolved(::fidl_next::FromWire::from_wire(unsafe {
1141 wire.raw.get().read_unchecked::<crate::wire::UnresolvedPayload<'de>>()
1142 })),
1143
1144 ord => return Self::UnknownOrdinal_(ord as u64),
1145 }
1146 }
1147 }
1148
1149 impl<'de> ::fidl_next::FromWireOption<crate::wire_optional::EventPayload<'de>> for EventPayload {
1150 #[inline]
1151 fn from_wire_option(
1152 wire: crate::wire_optional::EventPayload<'de>,
1153 ) -> ::core::option::Option<Self> {
1154 if let Some(inner) = wire.into_option() {
1155 Some(::fidl_next::FromWire::from_wire(inner))
1156 } else {
1157 None
1158 }
1159 }
1160 }
1161
1162 impl<'de> ::fidl_next::FromWireOption<crate::wire_optional::EventPayload<'de>>
1163 for Box<EventPayload>
1164 {
1165 #[inline]
1166 fn from_wire_option(
1167 wire: crate::wire_optional::EventPayload<'de>,
1168 ) -> ::core::option::Option<Self> {
1169 <
1170 EventPayload as ::fidl_next::FromWireOption<crate::wire_optional::EventPayload<'de>>
1171 >::from_wire_option(wire).map(Box::new)
1172 }
1173 }
1174
1175 #[doc = " Contains all information about a single event\n"]
1176 #[derive(PartialEq, Debug, Default)]
1177 pub struct Event {
1178 pub header: ::core::option::Option<crate::natural::EventHeader>,
1179
1180 pub payload: ::core::option::Option<crate::natural::EventPayload>,
1181 }
1182
1183 impl Event {
1184 fn __max_ordinal(&self) -> usize {
1185 if self.payload.is_some() {
1186 return 2;
1187 }
1188
1189 if self.header.is_some() {
1190 return 1;
1191 }
1192
1193 0
1194 }
1195 }
1196
1197 unsafe impl<___E> ::fidl_next::Encode<crate::wire::Event<'static>, ___E> for Event
1198 where
1199 ___E: ::fidl_next::Encoder + ?Sized,
1200 ___E: ::fidl_next::fuchsia::HandleEncoder,
1201 {
1202 #[inline]
1203 fn encode(
1204 mut self,
1205 encoder: &mut ___E,
1206 out: &mut ::core::mem::MaybeUninit<crate::wire::Event<'static>>,
1207 _: (),
1208 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1209 ::fidl_next::munge!(let crate::wire::Event { table } = out);
1210
1211 let max_ord = self.__max_ordinal();
1212
1213 let mut out = ::core::mem::MaybeUninit::<::fidl_next::WireEnvelope>::uninit();
1214 ::fidl_next::Wire::zero_padding(&mut out);
1215
1216 let mut preallocated =
1217 ::fidl_next::EncoderExt::preallocate::<::fidl_next::WireEnvelope>(encoder, max_ord);
1218
1219 for i in 1..=max_ord {
1220 match i {
1221 2 => {
1222 if let Some(value) = self.payload.take() {
1223 ::fidl_next::WireEnvelope::encode_value::<
1224 crate::wire::EventPayload<'static>,
1225 ___E,
1226 >(
1227 value, preallocated.encoder, &mut out, ()
1228 )?;
1229 } else {
1230 ::fidl_next::WireEnvelope::encode_zero(&mut out)
1231 }
1232 }
1233
1234 1 => {
1235 if let Some(value) = self.header.take() {
1236 ::fidl_next::WireEnvelope::encode_value::<
1237 crate::wire::EventHeader<'static>,
1238 ___E,
1239 >(
1240 value, preallocated.encoder, &mut out, ()
1241 )?;
1242 } else {
1243 ::fidl_next::WireEnvelope::encode_zero(&mut out)
1244 }
1245 }
1246
1247 _ => ::fidl_next::WireEnvelope::encode_zero(&mut out),
1248 }
1249 unsafe {
1250 preallocated.write_next(out.assume_init_ref());
1251 }
1252 }
1253
1254 ::fidl_next::WireTable::encode_len(table, max_ord);
1255
1256 Ok(())
1257 }
1258 }
1259
1260 impl<'de> ::fidl_next::FromWire<crate::wire::Event<'de>> for Event {
1261 #[inline]
1262 fn from_wire(wire_: crate::wire::Event<'de>) -> Self {
1263 let wire_ = ::core::mem::ManuallyDrop::new(wire_);
1264
1265 let header = wire_.table.get(1);
1266
1267 let payload = wire_.table.get(2);
1268
1269 Self {
1270 header: header.map(|envelope| {
1271 ::fidl_next::FromWire::from_wire(unsafe {
1272 envelope.read_unchecked::<crate::wire::EventHeader<'de>>()
1273 })
1274 }),
1275
1276 payload: payload.map(|envelope| {
1277 ::fidl_next::FromWire::from_wire(unsafe {
1278 envelope.read_unchecked::<crate::wire::EventPayload<'de>>()
1279 })
1280 }),
1281 }
1282 }
1283 }
1284
1285 #[derive(PartialEq, Debug)]
1286 pub struct EventStreamGetNextResponse {
1287 pub events: ::std::vec::Vec<crate::natural::Event>,
1288 }
1289
1290 unsafe impl<___E> ::fidl_next::Encode<crate::wire::EventStreamGetNextResponse<'static>, ___E>
1291 for EventStreamGetNextResponse
1292 where
1293 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1294 ___E: ::fidl_next::Encoder,
1295 ___E: ::fidl_next::fuchsia::HandleEncoder,
1296 {
1297 #[inline]
1298 fn encode(
1299 self,
1300 encoder_: &mut ___E,
1301 out_: &mut ::core::mem::MaybeUninit<crate::wire::EventStreamGetNextResponse<'static>>,
1302 _: (),
1303 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1304 ::fidl_next::munge! {
1305 let crate::wire::EventStreamGetNextResponse {
1306 events,
1307
1308 } = out_;
1309 }
1310
1311 ::fidl_next::Encode::encode(self.events, encoder_, events, (4294967295, ()))?;
1312
1313 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(events.as_mut_ptr()) };
1314 ::fidl_next::Constrained::validate(_field, (4294967295, ()))?;
1315
1316 Ok(())
1317 }
1318 }
1319
1320 unsafe impl<___E>
1321 ::fidl_next::EncodeOption<
1322 ::fidl_next::WireBox<'static, crate::wire::EventStreamGetNextResponse<'static>>,
1323 ___E,
1324 > for EventStreamGetNextResponse
1325 where
1326 ___E: ::fidl_next::Encoder + ?Sized,
1327 EventStreamGetNextResponse:
1328 ::fidl_next::Encode<crate::wire::EventStreamGetNextResponse<'static>, ___E>,
1329 {
1330 #[inline]
1331 fn encode_option(
1332 this: ::core::option::Option<Self>,
1333 encoder: &mut ___E,
1334 out: &mut ::core::mem::MaybeUninit<
1335 ::fidl_next::WireBox<'static, crate::wire::EventStreamGetNextResponse<'static>>,
1336 >,
1337 _: (),
1338 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1339 if let Some(inner) = this {
1340 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
1341 ::fidl_next::WireBox::encode_present(out);
1342 } else {
1343 ::fidl_next::WireBox::encode_absent(out);
1344 }
1345
1346 Ok(())
1347 }
1348 }
1349
1350 impl<'de> ::fidl_next::FromWire<crate::wire::EventStreamGetNextResponse<'de>>
1351 for EventStreamGetNextResponse
1352 {
1353 #[inline]
1354 fn from_wire(wire: crate::wire::EventStreamGetNextResponse<'de>) -> Self {
1355 Self { events: ::fidl_next::FromWire::from_wire(wire.events) }
1356 }
1357 }
1358
1359 #[derive(PartialEq, Debug)]
1360 #[repr(C)]
1361 pub struct IntrospectorGetMonikerRequest {
1362 pub component_instance: ::fidl_next::fuchsia::zx::Event,
1363 }
1364
1365 unsafe impl<___E> ::fidl_next::Encode<crate::wire::IntrospectorGetMonikerRequest, ___E>
1366 for IntrospectorGetMonikerRequest
1367 where
1368 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1369 ___E: ::fidl_next::fuchsia::HandleEncoder,
1370 {
1371 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<
1372 Self,
1373 crate::wire::IntrospectorGetMonikerRequest,
1374 > = unsafe {
1375 ::fidl_next::CopyOptimization::enable_if(
1376 true && <::fidl_next::fuchsia::zx::Event as ::fidl_next::Encode<
1377 ::fidl_next::fuchsia::WireEvent,
1378 ___E,
1379 >>::COPY_OPTIMIZATION
1380 .is_enabled(),
1381 )
1382 };
1383
1384 #[inline]
1385 fn encode(
1386 self,
1387 encoder_: &mut ___E,
1388 out_: &mut ::core::mem::MaybeUninit<crate::wire::IntrospectorGetMonikerRequest>,
1389 _: (),
1390 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1391 ::fidl_next::munge! {
1392 let crate::wire::IntrospectorGetMonikerRequest {
1393 component_instance,
1394
1395 } = out_;
1396 }
1397
1398 ::fidl_next::Encode::encode(self.component_instance, encoder_, component_instance, ())?;
1399
1400 let mut _field =
1401 unsafe { ::fidl_next::Slot::new_unchecked(component_instance.as_mut_ptr()) };
1402
1403 Ok(())
1404 }
1405 }
1406
1407 unsafe impl<___E>
1408 ::fidl_next::EncodeOption<
1409 ::fidl_next::WireBox<'static, crate::wire::IntrospectorGetMonikerRequest>,
1410 ___E,
1411 > for IntrospectorGetMonikerRequest
1412 where
1413 ___E: ::fidl_next::Encoder + ?Sized,
1414 IntrospectorGetMonikerRequest:
1415 ::fidl_next::Encode<crate::wire::IntrospectorGetMonikerRequest, ___E>,
1416 {
1417 #[inline]
1418 fn encode_option(
1419 this: ::core::option::Option<Self>,
1420 encoder: &mut ___E,
1421 out: &mut ::core::mem::MaybeUninit<
1422 ::fidl_next::WireBox<'static, crate::wire::IntrospectorGetMonikerRequest>,
1423 >,
1424 _: (),
1425 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1426 if let Some(inner) = this {
1427 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
1428 ::fidl_next::WireBox::encode_present(out);
1429 } else {
1430 ::fidl_next::WireBox::encode_absent(out);
1431 }
1432
1433 Ok(())
1434 }
1435 }
1436
1437 impl ::fidl_next::FromWire<crate::wire::IntrospectorGetMonikerRequest>
1438 for IntrospectorGetMonikerRequest
1439 {
1440 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<
1441 crate::wire::IntrospectorGetMonikerRequest,
1442 Self,
1443 > = unsafe {
1444 ::fidl_next::CopyOptimization::enable_if(
1445 true && <::fidl_next::fuchsia::zx::Event as ::fidl_next::FromWire<
1446 ::fidl_next::fuchsia::WireEvent,
1447 >>::COPY_OPTIMIZATION
1448 .is_enabled(),
1449 )
1450 };
1451
1452 #[inline]
1453 fn from_wire(wire: crate::wire::IntrospectorGetMonikerRequest) -> Self {
1454 Self { component_instance: ::fidl_next::FromWire::from_wire(wire.component_instance) }
1455 }
1456 }
1457
1458 #[derive(PartialEq, Debug)]
1459 pub struct NamespaceInputEntry {
1460 pub path: ::std::string::String,
1461
1462 pub dictionary: ::fidl_next::ClientEnd<
1463 ::fidl_next_fuchsia_component_sandbox::Dictionary,
1464 ::fidl_next::fuchsia::zx::Channel,
1465 >,
1466 }
1467
1468 unsafe impl<___E> ::fidl_next::Encode<crate::wire::NamespaceInputEntry<'static>, ___E>
1469 for NamespaceInputEntry
1470 where
1471 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1472 ___E: ::fidl_next::Encoder,
1473 ___E: ::fidl_next::fuchsia::HandleEncoder,
1474 {
1475 #[inline]
1476 fn encode(
1477 self,
1478 encoder_: &mut ___E,
1479 out_: &mut ::core::mem::MaybeUninit<crate::wire::NamespaceInputEntry<'static>>,
1480 _: (),
1481 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1482 ::fidl_next::munge! {
1483 let crate::wire::NamespaceInputEntry {
1484 path,
1485 dictionary,
1486
1487 } = out_;
1488 }
1489
1490 ::fidl_next::Encode::encode(self.path, encoder_, path, 4095)?;
1491
1492 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(path.as_mut_ptr()) };
1493 ::fidl_next::Constrained::validate(_field, 4095)?;
1494
1495 ::fidl_next::Encode::encode(self.dictionary, encoder_, dictionary, ())?;
1496
1497 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(dictionary.as_mut_ptr()) };
1498
1499 Ok(())
1500 }
1501 }
1502
1503 unsafe impl<___E>
1504 ::fidl_next::EncodeOption<
1505 ::fidl_next::WireBox<'static, crate::wire::NamespaceInputEntry<'static>>,
1506 ___E,
1507 > for NamespaceInputEntry
1508 where
1509 ___E: ::fidl_next::Encoder + ?Sized,
1510 NamespaceInputEntry: ::fidl_next::Encode<crate::wire::NamespaceInputEntry<'static>, ___E>,
1511 {
1512 #[inline]
1513 fn encode_option(
1514 this: ::core::option::Option<Self>,
1515 encoder: &mut ___E,
1516 out: &mut ::core::mem::MaybeUninit<
1517 ::fidl_next::WireBox<'static, crate::wire::NamespaceInputEntry<'static>>,
1518 >,
1519 _: (),
1520 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1521 if let Some(inner) = this {
1522 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
1523 ::fidl_next::WireBox::encode_present(out);
1524 } else {
1525 ::fidl_next::WireBox::encode_absent(out);
1526 }
1527
1528 Ok(())
1529 }
1530 }
1531
1532 impl<'de> ::fidl_next::FromWire<crate::wire::NamespaceInputEntry<'de>> for NamespaceInputEntry {
1533 #[inline]
1534 fn from_wire(wire: crate::wire::NamespaceInputEntry<'de>) -> Self {
1535 Self {
1536 path: ::fidl_next::FromWire::from_wire(wire.path),
1537
1538 dictionary: ::fidl_next::FromWire::from_wire(wire.dictionary),
1539 }
1540 }
1541 }
1542
1543 #[derive(PartialEq, Debug)]
1544 pub struct NamespaceCreateRequest {
1545 pub entries: ::std::vec::Vec<crate::natural::NamespaceInputEntry>,
1546 }
1547
1548 unsafe impl<___E> ::fidl_next::Encode<crate::wire::NamespaceCreateRequest<'static>, ___E>
1549 for NamespaceCreateRequest
1550 where
1551 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1552 ___E: ::fidl_next::Encoder,
1553 ___E: ::fidl_next::fuchsia::HandleEncoder,
1554 {
1555 #[inline]
1556 fn encode(
1557 self,
1558 encoder_: &mut ___E,
1559 out_: &mut ::core::mem::MaybeUninit<crate::wire::NamespaceCreateRequest<'static>>,
1560 _: (),
1561 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1562 ::fidl_next::munge! {
1563 let crate::wire::NamespaceCreateRequest {
1564 entries,
1565
1566 } = out_;
1567 }
1568
1569 ::fidl_next::Encode::encode(self.entries, encoder_, entries, (4294967295, ()))?;
1570
1571 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(entries.as_mut_ptr()) };
1572 ::fidl_next::Constrained::validate(_field, (4294967295, ()))?;
1573
1574 Ok(())
1575 }
1576 }
1577
1578 unsafe impl<___E>
1579 ::fidl_next::EncodeOption<
1580 ::fidl_next::WireBox<'static, crate::wire::NamespaceCreateRequest<'static>>,
1581 ___E,
1582 > for NamespaceCreateRequest
1583 where
1584 ___E: ::fidl_next::Encoder + ?Sized,
1585 NamespaceCreateRequest:
1586 ::fidl_next::Encode<crate::wire::NamespaceCreateRequest<'static>, ___E>,
1587 {
1588 #[inline]
1589 fn encode_option(
1590 this: ::core::option::Option<Self>,
1591 encoder: &mut ___E,
1592 out: &mut ::core::mem::MaybeUninit<
1593 ::fidl_next::WireBox<'static, crate::wire::NamespaceCreateRequest<'static>>,
1594 >,
1595 _: (),
1596 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1597 if let Some(inner) = this {
1598 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
1599 ::fidl_next::WireBox::encode_present(out);
1600 } else {
1601 ::fidl_next::WireBox::encode_absent(out);
1602 }
1603
1604 Ok(())
1605 }
1606 }
1607
1608 impl<'de> ::fidl_next::FromWire<crate::wire::NamespaceCreateRequest<'de>>
1609 for NamespaceCreateRequest
1610 {
1611 #[inline]
1612 fn from_wire(wire: crate::wire::NamespaceCreateRequest<'de>) -> Self {
1613 Self { entries: ::fidl_next::FromWire::from_wire(wire.entries) }
1614 }
1615 }
1616
1617 #[derive(PartialEq, Debug)]
1618 pub struct NamespaceCreateResponse {
1619 pub entries: ::std::vec::Vec<crate::natural::NamespaceEntry>,
1620 }
1621
1622 unsafe impl<___E> ::fidl_next::Encode<crate::wire::NamespaceCreateResponse<'static>, ___E>
1623 for NamespaceCreateResponse
1624 where
1625 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1626 ___E: ::fidl_next::Encoder,
1627 ___E: ::fidl_next::fuchsia::HandleEncoder,
1628 {
1629 #[inline]
1630 fn encode(
1631 self,
1632 encoder_: &mut ___E,
1633 out_: &mut ::core::mem::MaybeUninit<crate::wire::NamespaceCreateResponse<'static>>,
1634 _: (),
1635 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1636 ::fidl_next::munge! {
1637 let crate::wire::NamespaceCreateResponse {
1638 entries,
1639
1640 } = out_;
1641 }
1642
1643 ::fidl_next::Encode::encode(self.entries, encoder_, entries, (4294967295, ()))?;
1644
1645 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(entries.as_mut_ptr()) };
1646 ::fidl_next::Constrained::validate(_field, (4294967295, ()))?;
1647
1648 Ok(())
1649 }
1650 }
1651
1652 unsafe impl<___E>
1653 ::fidl_next::EncodeOption<
1654 ::fidl_next::WireBox<'static, crate::wire::NamespaceCreateResponse<'static>>,
1655 ___E,
1656 > for NamespaceCreateResponse
1657 where
1658 ___E: ::fidl_next::Encoder + ?Sized,
1659 NamespaceCreateResponse:
1660 ::fidl_next::Encode<crate::wire::NamespaceCreateResponse<'static>, ___E>,
1661 {
1662 #[inline]
1663 fn encode_option(
1664 this: ::core::option::Option<Self>,
1665 encoder: &mut ___E,
1666 out: &mut ::core::mem::MaybeUninit<
1667 ::fidl_next::WireBox<'static, crate::wire::NamespaceCreateResponse<'static>>,
1668 >,
1669 _: (),
1670 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1671 if let Some(inner) = this {
1672 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
1673 ::fidl_next::WireBox::encode_present(out);
1674 } else {
1675 ::fidl_next::WireBox::encode_absent(out);
1676 }
1677
1678 Ok(())
1679 }
1680 }
1681
1682 impl<'de> ::fidl_next::FromWire<crate::wire::NamespaceCreateResponse<'de>>
1683 for NamespaceCreateResponse
1684 {
1685 #[inline]
1686 fn from_wire(wire: crate::wire::NamespaceCreateResponse<'de>) -> Self {
1687 Self { entries: ::fidl_next::FromWire::from_wire(wire.entries) }
1688 }
1689 }
1690
1691 #[derive(PartialEq, Debug)]
1692 pub struct RealmListChildrenRequest {
1693 pub collection: ::fidl_next_fuchsia_component_decl::natural::CollectionRef,
1694
1695 pub iter: ::fidl_next::ServerEnd<crate::ChildIterator, ::fidl_next::fuchsia::zx::Channel>,
1696 }
1697
1698 unsafe impl<___E> ::fidl_next::Encode<crate::wire::RealmListChildrenRequest<'static>, ___E>
1699 for RealmListChildrenRequest
1700 where
1701 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1702 ___E: ::fidl_next::Encoder,
1703 ___E: ::fidl_next::fuchsia::HandleEncoder,
1704 {
1705 #[inline]
1706 fn encode(
1707 self,
1708 encoder_: &mut ___E,
1709 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmListChildrenRequest<'static>>,
1710 _: (),
1711 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1712 ::fidl_next::munge! {
1713 let crate::wire::RealmListChildrenRequest {
1714 collection,
1715 iter,
1716
1717 } = out_;
1718 }
1719
1720 ::fidl_next::Encode::encode(self.collection, encoder_, collection, ())?;
1721
1722 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(collection.as_mut_ptr()) };
1723
1724 ::fidl_next::Encode::encode(self.iter, encoder_, iter, ())?;
1725
1726 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(iter.as_mut_ptr()) };
1727
1728 Ok(())
1729 }
1730 }
1731
1732 unsafe impl<___E>
1733 ::fidl_next::EncodeOption<
1734 ::fidl_next::WireBox<'static, crate::wire::RealmListChildrenRequest<'static>>,
1735 ___E,
1736 > for RealmListChildrenRequest
1737 where
1738 ___E: ::fidl_next::Encoder + ?Sized,
1739 RealmListChildrenRequest:
1740 ::fidl_next::Encode<crate::wire::RealmListChildrenRequest<'static>, ___E>,
1741 {
1742 #[inline]
1743 fn encode_option(
1744 this: ::core::option::Option<Self>,
1745 encoder: &mut ___E,
1746 out: &mut ::core::mem::MaybeUninit<
1747 ::fidl_next::WireBox<'static, crate::wire::RealmListChildrenRequest<'static>>,
1748 >,
1749 _: (),
1750 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1751 if let Some(inner) = this {
1752 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
1753 ::fidl_next::WireBox::encode_present(out);
1754 } else {
1755 ::fidl_next::WireBox::encode_absent(out);
1756 }
1757
1758 Ok(())
1759 }
1760 }
1761
1762 impl<'de> ::fidl_next::FromWire<crate::wire::RealmListChildrenRequest<'de>>
1763 for RealmListChildrenRequest
1764 {
1765 #[inline]
1766 fn from_wire(wire: crate::wire::RealmListChildrenRequest<'de>) -> Self {
1767 Self {
1768 collection: ::fidl_next::FromWire::from_wire(wire.collection),
1769
1770 iter: ::fidl_next::FromWire::from_wire(wire.iter),
1771 }
1772 }
1773 }
1774
1775 #[derive(PartialEq, Debug)]
1776 pub struct RealmGetChildOutputDictionaryRequest {
1777 pub child: ::fidl_next_fuchsia_component_decl::natural::ChildRef,
1778 }
1779
1780 unsafe impl<___E>
1781 ::fidl_next::Encode<crate::wire::RealmGetChildOutputDictionaryRequest<'static>, ___E>
1782 for RealmGetChildOutputDictionaryRequest
1783 where
1784 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1785 ___E: ::fidl_next::Encoder,
1786 ___E: ::fidl_next::fuchsia::HandleEncoder,
1787 {
1788 #[inline]
1789 fn encode(
1790 self,
1791 encoder_: &mut ___E,
1792 out_: &mut ::core::mem::MaybeUninit<
1793 crate::wire::RealmGetChildOutputDictionaryRequest<'static>,
1794 >,
1795 _: (),
1796 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1797 ::fidl_next::munge! {
1798 let crate::wire::RealmGetChildOutputDictionaryRequest {
1799 child,
1800
1801 } = out_;
1802 }
1803
1804 ::fidl_next::Encode::encode(self.child, encoder_, child, ())?;
1805
1806 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(child.as_mut_ptr()) };
1807
1808 Ok(())
1809 }
1810 }
1811
1812 unsafe impl<___E>
1813 ::fidl_next::EncodeOption<
1814 ::fidl_next::WireBox<
1815 'static,
1816 crate::wire::RealmGetChildOutputDictionaryRequest<'static>,
1817 >,
1818 ___E,
1819 > for RealmGetChildOutputDictionaryRequest
1820 where
1821 ___E: ::fidl_next::Encoder + ?Sized,
1822 RealmGetChildOutputDictionaryRequest:
1823 ::fidl_next::Encode<crate::wire::RealmGetChildOutputDictionaryRequest<'static>, ___E>,
1824 {
1825 #[inline]
1826 fn encode_option(
1827 this: ::core::option::Option<Self>,
1828 encoder: &mut ___E,
1829 out: &mut ::core::mem::MaybeUninit<
1830 ::fidl_next::WireBox<
1831 'static,
1832 crate::wire::RealmGetChildOutputDictionaryRequest<'static>,
1833 >,
1834 >,
1835 _: (),
1836 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1837 if let Some(inner) = this {
1838 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
1839 ::fidl_next::WireBox::encode_present(out);
1840 } else {
1841 ::fidl_next::WireBox::encode_absent(out);
1842 }
1843
1844 Ok(())
1845 }
1846 }
1847
1848 impl<'de> ::fidl_next::FromWire<crate::wire::RealmGetChildOutputDictionaryRequest<'de>>
1849 for RealmGetChildOutputDictionaryRequest
1850 {
1851 #[inline]
1852 fn from_wire(wire: crate::wire::RealmGetChildOutputDictionaryRequest<'de>) -> Self {
1853 Self { child: ::fidl_next::FromWire::from_wire(wire.child) }
1854 }
1855 }
1856
1857 #[derive(PartialEq, Debug)]
1858 #[repr(C)]
1859 pub struct RealmGetChildOutputDictionaryResponse {
1860 pub dictionary: ::fidl_next_fuchsia_component_sandbox::natural::DictionaryRef,
1861 }
1862
1863 unsafe impl<___E> ::fidl_next::Encode<crate::wire::RealmGetChildOutputDictionaryResponse, ___E>
1864 for RealmGetChildOutputDictionaryResponse
1865 where
1866 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1867 ___E: ::fidl_next::fuchsia::HandleEncoder,
1868 {
1869 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<
1870 Self,
1871 crate::wire::RealmGetChildOutputDictionaryResponse,
1872 > = unsafe {
1873 ::fidl_next::CopyOptimization::enable_if(
1874 true
1875
1876 && <
1877 ::fidl_next_fuchsia_component_sandbox::natural::DictionaryRef as ::fidl_next::Encode<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef, ___E>
1878 >::COPY_OPTIMIZATION.is_enabled()
1879
1880 )
1881 };
1882
1883 #[inline]
1884 fn encode(
1885 self,
1886 encoder_: &mut ___E,
1887 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmGetChildOutputDictionaryResponse>,
1888 _: (),
1889 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1890 ::fidl_next::munge! {
1891 let crate::wire::RealmGetChildOutputDictionaryResponse {
1892 dictionary,
1893
1894 } = out_;
1895 }
1896
1897 ::fidl_next::Encode::encode(self.dictionary, encoder_, dictionary, ())?;
1898
1899 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(dictionary.as_mut_ptr()) };
1900
1901 Ok(())
1902 }
1903 }
1904
1905 unsafe impl<___E>
1906 ::fidl_next::EncodeOption<
1907 ::fidl_next::WireBox<'static, crate::wire::RealmGetChildOutputDictionaryResponse>,
1908 ___E,
1909 > for RealmGetChildOutputDictionaryResponse
1910 where
1911 ___E: ::fidl_next::Encoder + ?Sized,
1912 RealmGetChildOutputDictionaryResponse:
1913 ::fidl_next::Encode<crate::wire::RealmGetChildOutputDictionaryResponse, ___E>,
1914 {
1915 #[inline]
1916 fn encode_option(
1917 this: ::core::option::Option<Self>,
1918 encoder: &mut ___E,
1919 out: &mut ::core::mem::MaybeUninit<
1920 ::fidl_next::WireBox<'static, crate::wire::RealmGetChildOutputDictionaryResponse>,
1921 >,
1922 _: (),
1923 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1924 if let Some(inner) = this {
1925 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
1926 ::fidl_next::WireBox::encode_present(out);
1927 } else {
1928 ::fidl_next::WireBox::encode_absent(out);
1929 }
1930
1931 Ok(())
1932 }
1933 }
1934
1935 impl ::fidl_next::FromWire<crate::wire::RealmGetChildOutputDictionaryResponse>
1936 for RealmGetChildOutputDictionaryResponse
1937 {
1938 const COPY_OPTIMIZATION: ::fidl_next::CopyOptimization<
1939 crate::wire::RealmGetChildOutputDictionaryResponse,
1940 Self,
1941 > = unsafe {
1942 ::fidl_next::CopyOptimization::enable_if(
1943 true
1944
1945 && <
1946 ::fidl_next_fuchsia_component_sandbox::natural::DictionaryRef as ::fidl_next::FromWire<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef>
1947 >::COPY_OPTIMIZATION.is_enabled()
1948
1949 )
1950 };
1951
1952 #[inline]
1953 fn from_wire(wire: crate::wire::RealmGetChildOutputDictionaryResponse) -> Self {
1954 Self { dictionary: ::fidl_next::FromWire::from_wire(wire.dictionary) }
1955 }
1956 }
1957
1958 #[derive(PartialEq, Debug)]
1959 pub struct RealmOpenControllerRequest {
1960 pub child: ::fidl_next_fuchsia_component_decl::natural::ChildRef,
1961
1962 pub controller:
1963 ::fidl_next::ServerEnd<crate::Controller, ::fidl_next::fuchsia::zx::Channel>,
1964 }
1965
1966 unsafe impl<___E> ::fidl_next::Encode<crate::wire::RealmOpenControllerRequest<'static>, ___E>
1967 for RealmOpenControllerRequest
1968 where
1969 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
1970 ___E: ::fidl_next::Encoder,
1971 ___E: ::fidl_next::fuchsia::HandleEncoder,
1972 {
1973 #[inline]
1974 fn encode(
1975 self,
1976 encoder_: &mut ___E,
1977 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmOpenControllerRequest<'static>>,
1978 _: (),
1979 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
1980 ::fidl_next::munge! {
1981 let crate::wire::RealmOpenControllerRequest {
1982 child,
1983 controller,
1984
1985 } = out_;
1986 }
1987
1988 ::fidl_next::Encode::encode(self.child, encoder_, child, ())?;
1989
1990 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(child.as_mut_ptr()) };
1991
1992 ::fidl_next::Encode::encode(self.controller, encoder_, controller, ())?;
1993
1994 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(controller.as_mut_ptr()) };
1995
1996 Ok(())
1997 }
1998 }
1999
2000 unsafe impl<___E>
2001 ::fidl_next::EncodeOption<
2002 ::fidl_next::WireBox<'static, crate::wire::RealmOpenControllerRequest<'static>>,
2003 ___E,
2004 > for RealmOpenControllerRequest
2005 where
2006 ___E: ::fidl_next::Encoder + ?Sized,
2007 RealmOpenControllerRequest:
2008 ::fidl_next::Encode<crate::wire::RealmOpenControllerRequest<'static>, ___E>,
2009 {
2010 #[inline]
2011 fn encode_option(
2012 this: ::core::option::Option<Self>,
2013 encoder: &mut ___E,
2014 out: &mut ::core::mem::MaybeUninit<
2015 ::fidl_next::WireBox<'static, crate::wire::RealmOpenControllerRequest<'static>>,
2016 >,
2017 _: (),
2018 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2019 if let Some(inner) = this {
2020 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
2021 ::fidl_next::WireBox::encode_present(out);
2022 } else {
2023 ::fidl_next::WireBox::encode_absent(out);
2024 }
2025
2026 Ok(())
2027 }
2028 }
2029
2030 impl<'de> ::fidl_next::FromWire<crate::wire::RealmOpenControllerRequest<'de>>
2031 for RealmOpenControllerRequest
2032 {
2033 #[inline]
2034 fn from_wire(wire: crate::wire::RealmOpenControllerRequest<'de>) -> Self {
2035 Self {
2036 child: ::fidl_next::FromWire::from_wire(wire.child),
2037
2038 controller: ::fidl_next::FromWire::from_wire(wire.controller),
2039 }
2040 }
2041 }
2042
2043 #[derive(PartialEq, Debug)]
2044 pub struct RealmOpenExposedDirRequest {
2045 pub child: ::fidl_next_fuchsia_component_decl::natural::ChildRef,
2046
2047 pub exposed_dir: ::fidl_next::ServerEnd<
2048 ::fidl_next_fuchsia_io::Directory,
2049 ::fidl_next::fuchsia::zx::Channel,
2050 >,
2051 }
2052
2053 unsafe impl<___E> ::fidl_next::Encode<crate::wire::RealmOpenExposedDirRequest<'static>, ___E>
2054 for RealmOpenExposedDirRequest
2055 where
2056 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
2057 ___E: ::fidl_next::Encoder,
2058 ___E: ::fidl_next::fuchsia::HandleEncoder,
2059 {
2060 #[inline]
2061 fn encode(
2062 self,
2063 encoder_: &mut ___E,
2064 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmOpenExposedDirRequest<'static>>,
2065 _: (),
2066 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2067 ::fidl_next::munge! {
2068 let crate::wire::RealmOpenExposedDirRequest {
2069 child,
2070 exposed_dir,
2071
2072 } = out_;
2073 }
2074
2075 ::fidl_next::Encode::encode(self.child, encoder_, child, ())?;
2076
2077 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(child.as_mut_ptr()) };
2078
2079 ::fidl_next::Encode::encode(self.exposed_dir, encoder_, exposed_dir, ())?;
2080
2081 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(exposed_dir.as_mut_ptr()) };
2082
2083 Ok(())
2084 }
2085 }
2086
2087 unsafe impl<___E>
2088 ::fidl_next::EncodeOption<
2089 ::fidl_next::WireBox<'static, crate::wire::RealmOpenExposedDirRequest<'static>>,
2090 ___E,
2091 > for RealmOpenExposedDirRequest
2092 where
2093 ___E: ::fidl_next::Encoder + ?Sized,
2094 RealmOpenExposedDirRequest:
2095 ::fidl_next::Encode<crate::wire::RealmOpenExposedDirRequest<'static>, ___E>,
2096 {
2097 #[inline]
2098 fn encode_option(
2099 this: ::core::option::Option<Self>,
2100 encoder: &mut ___E,
2101 out: &mut ::core::mem::MaybeUninit<
2102 ::fidl_next::WireBox<'static, crate::wire::RealmOpenExposedDirRequest<'static>>,
2103 >,
2104 _: (),
2105 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2106 if let Some(inner) = this {
2107 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
2108 ::fidl_next::WireBox::encode_present(out);
2109 } else {
2110 ::fidl_next::WireBox::encode_absent(out);
2111 }
2112
2113 Ok(())
2114 }
2115 }
2116
2117 impl<'de> ::fidl_next::FromWire<crate::wire::RealmOpenExposedDirRequest<'de>>
2118 for RealmOpenExposedDirRequest
2119 {
2120 #[inline]
2121 fn from_wire(wire: crate::wire::RealmOpenExposedDirRequest<'de>) -> Self {
2122 Self {
2123 child: ::fidl_next::FromWire::from_wire(wire.child),
2124
2125 exposed_dir: ::fidl_next::FromWire::from_wire(wire.exposed_dir),
2126 }
2127 }
2128 }
2129
2130 #[derive(PartialEq, Debug)]
2131 pub struct RealmCreateChildRequest {
2132 pub collection: ::fidl_next_fuchsia_component_decl::natural::CollectionRef,
2133
2134 pub decl: ::fidl_next_fuchsia_component_decl::natural::Child,
2135
2136 pub args: crate::natural::CreateChildArgs,
2137 }
2138
2139 unsafe impl<___E> ::fidl_next::Encode<crate::wire::RealmCreateChildRequest<'static>, ___E>
2140 for RealmCreateChildRequest
2141 where
2142 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
2143 ___E: ::fidl_next::Encoder,
2144 ___E: ::fidl_next::fuchsia::HandleEncoder,
2145 {
2146 #[inline]
2147 fn encode(
2148 self,
2149 encoder_: &mut ___E,
2150 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmCreateChildRequest<'static>>,
2151 _: (),
2152 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2153 ::fidl_next::munge! {
2154 let crate::wire::RealmCreateChildRequest {
2155 collection,
2156 decl,
2157 args,
2158
2159 } = out_;
2160 }
2161
2162 ::fidl_next::Encode::encode(self.collection, encoder_, collection, ())?;
2163
2164 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(collection.as_mut_ptr()) };
2165
2166 ::fidl_next::Encode::encode(self.decl, encoder_, decl, ())?;
2167
2168 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(decl.as_mut_ptr()) };
2169
2170 ::fidl_next::Encode::encode(self.args, encoder_, args, ())?;
2171
2172 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(args.as_mut_ptr()) };
2173
2174 Ok(())
2175 }
2176 }
2177
2178 unsafe impl<___E>
2179 ::fidl_next::EncodeOption<
2180 ::fidl_next::WireBox<'static, crate::wire::RealmCreateChildRequest<'static>>,
2181 ___E,
2182 > for RealmCreateChildRequest
2183 where
2184 ___E: ::fidl_next::Encoder + ?Sized,
2185 RealmCreateChildRequest:
2186 ::fidl_next::Encode<crate::wire::RealmCreateChildRequest<'static>, ___E>,
2187 {
2188 #[inline]
2189 fn encode_option(
2190 this: ::core::option::Option<Self>,
2191 encoder: &mut ___E,
2192 out: &mut ::core::mem::MaybeUninit<
2193 ::fidl_next::WireBox<'static, crate::wire::RealmCreateChildRequest<'static>>,
2194 >,
2195 _: (),
2196 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2197 if let Some(inner) = this {
2198 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
2199 ::fidl_next::WireBox::encode_present(out);
2200 } else {
2201 ::fidl_next::WireBox::encode_absent(out);
2202 }
2203
2204 Ok(())
2205 }
2206 }
2207
2208 impl<'de> ::fidl_next::FromWire<crate::wire::RealmCreateChildRequest<'de>>
2209 for RealmCreateChildRequest
2210 {
2211 #[inline]
2212 fn from_wire(wire: crate::wire::RealmCreateChildRequest<'de>) -> Self {
2213 Self {
2214 collection: ::fidl_next::FromWire::from_wire(wire.collection),
2215
2216 decl: ::fidl_next::FromWire::from_wire(wire.decl),
2217
2218 args: ::fidl_next::FromWire::from_wire(wire.args),
2219 }
2220 }
2221 }
2222
2223 #[derive(PartialEq, Debug)]
2224 pub struct RealmGetResolvedInfoResponse {
2225 pub resolved_info: ::fidl_next_fuchsia_component_resolution::natural::Component,
2226 }
2227
2228 unsafe impl<___E> ::fidl_next::Encode<crate::wire::RealmGetResolvedInfoResponse<'static>, ___E>
2229 for RealmGetResolvedInfoResponse
2230 where
2231 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
2232 ___E: ::fidl_next::Encoder,
2233 ___E: ::fidl_next::fuchsia::HandleEncoder,
2234 {
2235 #[inline]
2236 fn encode(
2237 self,
2238 encoder_: &mut ___E,
2239 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmGetResolvedInfoResponse<'static>>,
2240 _: (),
2241 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2242 ::fidl_next::munge! {
2243 let crate::wire::RealmGetResolvedInfoResponse {
2244 resolved_info,
2245
2246 } = out_;
2247 }
2248
2249 ::fidl_next::Encode::encode(self.resolved_info, encoder_, resolved_info, ())?;
2250
2251 let mut _field =
2252 unsafe { ::fidl_next::Slot::new_unchecked(resolved_info.as_mut_ptr()) };
2253
2254 Ok(())
2255 }
2256 }
2257
2258 unsafe impl<___E>
2259 ::fidl_next::EncodeOption<
2260 ::fidl_next::WireBox<'static, crate::wire::RealmGetResolvedInfoResponse<'static>>,
2261 ___E,
2262 > for RealmGetResolvedInfoResponse
2263 where
2264 ___E: ::fidl_next::Encoder + ?Sized,
2265 RealmGetResolvedInfoResponse:
2266 ::fidl_next::Encode<crate::wire::RealmGetResolvedInfoResponse<'static>, ___E>,
2267 {
2268 #[inline]
2269 fn encode_option(
2270 this: ::core::option::Option<Self>,
2271 encoder: &mut ___E,
2272 out: &mut ::core::mem::MaybeUninit<
2273 ::fidl_next::WireBox<'static, crate::wire::RealmGetResolvedInfoResponse<'static>>,
2274 >,
2275 _: (),
2276 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2277 if let Some(inner) = this {
2278 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
2279 ::fidl_next::WireBox::encode_present(out);
2280 } else {
2281 ::fidl_next::WireBox::encode_absent(out);
2282 }
2283
2284 Ok(())
2285 }
2286 }
2287
2288 impl<'de> ::fidl_next::FromWire<crate::wire::RealmGetResolvedInfoResponse<'de>>
2289 for RealmGetResolvedInfoResponse
2290 {
2291 #[inline]
2292 fn from_wire(wire: crate::wire::RealmGetResolvedInfoResponse<'de>) -> Self {
2293 Self { resolved_info: ::fidl_next::FromWire::from_wire(wire.resolved_info) }
2294 }
2295 }
2296
2297 #[derive(PartialEq, Debug)]
2298 pub struct StorageAdminListStorageInRealmRequest {
2299 pub relative_moniker: ::std::string::String,
2300
2301 pub iterator:
2302 ::fidl_next::ServerEnd<crate::StorageIterator, ::fidl_next::fuchsia::zx::Channel>,
2303 }
2304
2305 unsafe impl<___E>
2306 ::fidl_next::Encode<crate::wire::StorageAdminListStorageInRealmRequest<'static>, ___E>
2307 for StorageAdminListStorageInRealmRequest
2308 where
2309 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
2310 ___E: ::fidl_next::Encoder,
2311 ___E: ::fidl_next::fuchsia::HandleEncoder,
2312 {
2313 #[inline]
2314 fn encode(
2315 self,
2316 encoder_: &mut ___E,
2317 out_: &mut ::core::mem::MaybeUninit<
2318 crate::wire::StorageAdminListStorageInRealmRequest<'static>,
2319 >,
2320 _: (),
2321 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2322 ::fidl_next::munge! {
2323 let crate::wire::StorageAdminListStorageInRealmRequest {
2324 relative_moniker,
2325 iterator,
2326
2327 } = out_;
2328 }
2329
2330 ::fidl_next::Encode::encode(self.relative_moniker, encoder_, relative_moniker, 4096)?;
2331
2332 let mut _field =
2333 unsafe { ::fidl_next::Slot::new_unchecked(relative_moniker.as_mut_ptr()) };
2334 ::fidl_next::Constrained::validate(_field, 4096)?;
2335
2336 ::fidl_next::Encode::encode(self.iterator, encoder_, iterator, ())?;
2337
2338 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(iterator.as_mut_ptr()) };
2339
2340 Ok(())
2341 }
2342 }
2343
2344 unsafe impl<___E>
2345 ::fidl_next::EncodeOption<
2346 ::fidl_next::WireBox<
2347 'static,
2348 crate::wire::StorageAdminListStorageInRealmRequest<'static>,
2349 >,
2350 ___E,
2351 > for StorageAdminListStorageInRealmRequest
2352 where
2353 ___E: ::fidl_next::Encoder + ?Sized,
2354 StorageAdminListStorageInRealmRequest:
2355 ::fidl_next::Encode<crate::wire::StorageAdminListStorageInRealmRequest<'static>, ___E>,
2356 {
2357 #[inline]
2358 fn encode_option(
2359 this: ::core::option::Option<Self>,
2360 encoder: &mut ___E,
2361 out: &mut ::core::mem::MaybeUninit<
2362 ::fidl_next::WireBox<
2363 'static,
2364 crate::wire::StorageAdminListStorageInRealmRequest<'static>,
2365 >,
2366 >,
2367 _: (),
2368 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2369 if let Some(inner) = this {
2370 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
2371 ::fidl_next::WireBox::encode_present(out);
2372 } else {
2373 ::fidl_next::WireBox::encode_absent(out);
2374 }
2375
2376 Ok(())
2377 }
2378 }
2379
2380 impl<'de> ::fidl_next::FromWire<crate::wire::StorageAdminListStorageInRealmRequest<'de>>
2381 for StorageAdminListStorageInRealmRequest
2382 {
2383 #[inline]
2384 fn from_wire(wire: crate::wire::StorageAdminListStorageInRealmRequest<'de>) -> Self {
2385 Self {
2386 relative_moniker: ::fidl_next::FromWire::from_wire(wire.relative_moniker),
2387
2388 iterator: ::fidl_next::FromWire::from_wire(wire.iterator),
2389 }
2390 }
2391 }
2392
2393 #[derive(PartialEq, Debug)]
2394 pub struct StorageAdminOpenStorageRequest {
2395 pub relative_moniker: ::std::string::String,
2396
2397 pub object:
2398 ::fidl_next::ServerEnd<::fidl_next_fuchsia_io::Node, ::fidl_next::fuchsia::zx::Channel>,
2399 }
2400
2401 unsafe impl<___E>
2402 ::fidl_next::Encode<crate::wire::StorageAdminOpenStorageRequest<'static>, ___E>
2403 for StorageAdminOpenStorageRequest
2404 where
2405 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
2406 ___E: ::fidl_next::Encoder,
2407 ___E: ::fidl_next::fuchsia::HandleEncoder,
2408 {
2409 #[inline]
2410 fn encode(
2411 self,
2412 encoder_: &mut ___E,
2413 out_: &mut ::core::mem::MaybeUninit<
2414 crate::wire::StorageAdminOpenStorageRequest<'static>,
2415 >,
2416 _: (),
2417 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2418 ::fidl_next::munge! {
2419 let crate::wire::StorageAdminOpenStorageRequest {
2420 relative_moniker,
2421 object,
2422
2423 } = out_;
2424 }
2425
2426 ::fidl_next::Encode::encode(self.relative_moniker, encoder_, relative_moniker, 4096)?;
2427
2428 let mut _field =
2429 unsafe { ::fidl_next::Slot::new_unchecked(relative_moniker.as_mut_ptr()) };
2430 ::fidl_next::Constrained::validate(_field, 4096)?;
2431
2432 ::fidl_next::Encode::encode(self.object, encoder_, object, ())?;
2433
2434 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(object.as_mut_ptr()) };
2435
2436 Ok(())
2437 }
2438 }
2439
2440 unsafe impl<___E>
2441 ::fidl_next::EncodeOption<
2442 ::fidl_next::WireBox<'static, crate::wire::StorageAdminOpenStorageRequest<'static>>,
2443 ___E,
2444 > for StorageAdminOpenStorageRequest
2445 where
2446 ___E: ::fidl_next::Encoder + ?Sized,
2447 StorageAdminOpenStorageRequest:
2448 ::fidl_next::Encode<crate::wire::StorageAdminOpenStorageRequest<'static>, ___E>,
2449 {
2450 #[inline]
2451 fn encode_option(
2452 this: ::core::option::Option<Self>,
2453 encoder: &mut ___E,
2454 out: &mut ::core::mem::MaybeUninit<
2455 ::fidl_next::WireBox<'static, crate::wire::StorageAdminOpenStorageRequest<'static>>,
2456 >,
2457 _: (),
2458 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2459 if let Some(inner) = this {
2460 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
2461 ::fidl_next::WireBox::encode_present(out);
2462 } else {
2463 ::fidl_next::WireBox::encode_absent(out);
2464 }
2465
2466 Ok(())
2467 }
2468 }
2469
2470 impl<'de> ::fidl_next::FromWire<crate::wire::StorageAdminOpenStorageRequest<'de>>
2471 for StorageAdminOpenStorageRequest
2472 {
2473 #[inline]
2474 fn from_wire(wire: crate::wire::StorageAdminOpenStorageRequest<'de>) -> Self {
2475 Self {
2476 relative_moniker: ::fidl_next::FromWire::from_wire(wire.relative_moniker),
2477
2478 object: ::fidl_next::FromWire::from_wire(wire.object),
2479 }
2480 }
2481 }
2482
2483 #[derive(PartialEq, Debug)]
2484 pub struct StorageAdminOpenComponentStorageByIdRequest {
2485 pub id: ::std::string::String,
2486
2487 pub object:
2488 ::fidl_next::ServerEnd<::fidl_next_fuchsia_io::Node, ::fidl_next::fuchsia::zx::Channel>,
2489 }
2490
2491 unsafe impl<___E>
2492 ::fidl_next::Encode<crate::wire::StorageAdminOpenComponentStorageByIdRequest<'static>, ___E>
2493 for StorageAdminOpenComponentStorageByIdRequest
2494 where
2495 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
2496 ___E: ::fidl_next::Encoder,
2497 ___E: ::fidl_next::fuchsia::HandleEncoder,
2498 {
2499 #[inline]
2500 fn encode(
2501 self,
2502 encoder_: &mut ___E,
2503 out_: &mut ::core::mem::MaybeUninit<
2504 crate::wire::StorageAdminOpenComponentStorageByIdRequest<'static>,
2505 >,
2506 _: (),
2507 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2508 ::fidl_next::munge! {
2509 let crate::wire::StorageAdminOpenComponentStorageByIdRequest {
2510 id,
2511 object,
2512
2513 } = out_;
2514 }
2515
2516 ::fidl_next::Encode::encode(self.id, encoder_, id, 64)?;
2517
2518 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(id.as_mut_ptr()) };
2519 ::fidl_next::Constrained::validate(_field, 64)?;
2520
2521 ::fidl_next::Encode::encode(self.object, encoder_, object, ())?;
2522
2523 let mut _field = unsafe { ::fidl_next::Slot::new_unchecked(object.as_mut_ptr()) };
2524
2525 Ok(())
2526 }
2527 }
2528
2529 unsafe impl<___E>
2530 ::fidl_next::EncodeOption<
2531 ::fidl_next::WireBox<
2532 'static,
2533 crate::wire::StorageAdminOpenComponentStorageByIdRequest<'static>,
2534 >,
2535 ___E,
2536 > for StorageAdminOpenComponentStorageByIdRequest
2537 where
2538 ___E: ::fidl_next::Encoder + ?Sized,
2539 StorageAdminOpenComponentStorageByIdRequest: ::fidl_next::Encode<
2540 crate::wire::StorageAdminOpenComponentStorageByIdRequest<'static>,
2541 ___E,
2542 >,
2543 {
2544 #[inline]
2545 fn encode_option(
2546 this: ::core::option::Option<Self>,
2547 encoder: &mut ___E,
2548 out: &mut ::core::mem::MaybeUninit<
2549 ::fidl_next::WireBox<
2550 'static,
2551 crate::wire::StorageAdminOpenComponentStorageByIdRequest<'static>,
2552 >,
2553 >,
2554 _: (),
2555 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
2556 if let Some(inner) = this {
2557 ::fidl_next::EncoderExt::encode_next(encoder, inner, ())?;
2558 ::fidl_next::WireBox::encode_present(out);
2559 } else {
2560 ::fidl_next::WireBox::encode_absent(out);
2561 }
2562
2563 Ok(())
2564 }
2565 }
2566
2567 impl<'de> ::fidl_next::FromWire<crate::wire::StorageAdminOpenComponentStorageByIdRequest<'de>>
2568 for StorageAdminOpenComponentStorageByIdRequest
2569 {
2570 #[inline]
2571 fn from_wire(wire: crate::wire::StorageAdminOpenComponentStorageByIdRequest<'de>) -> Self {
2572 Self {
2573 id: ::fidl_next::FromWire::from_wire(wire.id),
2574
2575 object: ::fidl_next::FromWire::from_wire(wire.object),
2576 }
2577 }
2578 }
2579}
2580
2581pub mod wire {
2582
2583 pub use fidl_next_common_fuchsia_component::wire::*;
2584
2585 #[repr(C)]
2587 pub struct CapabilityRequestedPayload<'de> {
2588 pub(crate) table: ::fidl_next::WireTable<'de>,
2589 }
2590
2591 impl<'de> Drop for CapabilityRequestedPayload<'de> {
2592 fn drop(&mut self) {
2593 let _ = self.table.get(1).map(|envelope| unsafe {
2594 envelope.read_unchecked::<::fidl_next::WireString<'de>>()
2595 });
2596
2597 let _ = self.table.get(2).map(|envelope| unsafe {
2598 envelope.read_unchecked::<::fidl_next::fuchsia::WireChannel>()
2599 });
2600 }
2601 }
2602
2603 unsafe impl ::fidl_next::Wire for CapabilityRequestedPayload<'static> {
2604 type Owned<'de> = CapabilityRequestedPayload<'de>;
2605
2606 #[inline]
2607 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
2608 ::fidl_next::munge!(let Self { table } = out);
2609 ::fidl_next::WireTable::zero_padding(table);
2610 }
2611 }
2612
2613 unsafe impl<___D> ::fidl_next::Decode<___D> for CapabilityRequestedPayload<'static>
2614 where
2615 ___D: ::fidl_next::Decoder + ?Sized,
2616 ___D: ::fidl_next::fuchsia::HandleDecoder,
2617 {
2618 fn decode(
2619 slot: ::fidl_next::Slot<'_, Self>,
2620 decoder: &mut ___D,
2621 _: (),
2622 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
2623 ::fidl_next::munge!(let Self { table } = slot);
2624
2625 ::fidl_next::WireTable::decode_with(table, decoder, |ordinal, mut slot, decoder| {
2626 match ordinal {
2627 0 => unsafe { ::core::hint::unreachable_unchecked() },
2628
2629 1 => {
2630 ::fidl_next::WireEnvelope::decode_as::<
2631 ___D,
2632 ::fidl_next::WireString<'static>,
2633 >(slot.as_mut(), decoder, 255)?;
2634
2635 let value = unsafe {
2636 slot.deref_unchecked().deref_unchecked::<::fidl_next::WireString<'_>>()
2637 };
2638
2639 if value.len() > 255 {
2640 return Err(::fidl_next::DecodeError::VectorTooLong {
2641 size: value.len() as u64,
2642 limit: 255,
2643 });
2644 }
2645
2646 Ok(())
2647 }
2648
2649 2 => {
2650 ::fidl_next::WireEnvelope::decode_as::<
2651 ___D,
2652 ::fidl_next::fuchsia::WireChannel,
2653 >(slot.as_mut(), decoder, ())?;
2654
2655 Ok(())
2656 }
2657
2658 _ => ::fidl_next::WireEnvelope::decode_unknown(slot, decoder),
2659 }
2660 })
2661 }
2662 }
2663
2664 impl<'de> CapabilityRequestedPayload<'de> {
2665 pub fn name(&self) -> ::core::option::Option<&::fidl_next::WireString<'de>> {
2666 unsafe { Some(self.table.get(1)?.deref_unchecked()) }
2667 }
2668
2669 pub fn capability(&self) -> ::core::option::Option<&::fidl_next::fuchsia::WireChannel> {
2670 unsafe { Some(self.table.get(2)?.deref_unchecked()) }
2671 }
2672 }
2673
2674 impl<'de> ::core::fmt::Debug for CapabilityRequestedPayload<'de> {
2675 fn fmt(
2676 &self,
2677 f: &mut ::core::fmt::Formatter<'_>,
2678 ) -> ::core::result::Result<(), ::core::fmt::Error> {
2679 f.debug_struct("CapabilityRequestedPayload")
2680 .field("name", &self.name())
2681 .field("capability", &self.capability())
2682 .finish()
2683 }
2684 }
2685
2686 impl<'de> ::fidl_next::IntoNatural for CapabilityRequestedPayload<'de> {
2687 type Natural = crate::natural::CapabilityRequestedPayload;
2688 }
2689
2690 impl ::fidl_next::Unconstrained for CapabilityRequestedPayload<'_> {}
2691
2692 #[derive(Debug)]
2694 #[repr(C)]
2695 pub struct ControllerIsStartedResponse {
2696 pub is_started: bool,
2697 }
2698
2699 static_assertions::const_assert_eq!(std::mem::size_of::<ControllerIsStartedResponse>(), 1);
2700 static_assertions::const_assert_eq!(std::mem::align_of::<ControllerIsStartedResponse>(), 1);
2701
2702 static_assertions::const_assert_eq!(
2703 std::mem::offset_of!(ControllerIsStartedResponse, is_started),
2704 0
2705 );
2706
2707 unsafe impl ::fidl_next::Wire for ControllerIsStartedResponse {
2708 type Owned<'de> = ControllerIsStartedResponse;
2709
2710 #[inline]
2711 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
2712 ::fidl_next::munge! {
2713 let Self {
2714
2715 is_started,
2716
2717 } = &mut *out_;
2718 }
2719
2720 ::fidl_next::Wire::zero_padding(is_started);
2721 }
2722 }
2723
2724 unsafe impl<___D> ::fidl_next::Decode<___D> for ControllerIsStartedResponse
2725 where
2726 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
2727 ___D: ::fidl_next::fuchsia::HandleDecoder,
2728 {
2729 fn decode(
2730 slot_: ::fidl_next::Slot<'_, Self>,
2731 decoder_: &mut ___D,
2732 _: (),
2733 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
2734 ::fidl_next::munge! {
2735 let Self {
2736
2737 mut is_started,
2738
2739 } = slot_;
2740 }
2741
2742 let _field = is_started.as_mut();
2743
2744 ::fidl_next::Decode::decode(is_started.as_mut(), decoder_, ())?;
2745
2746 Ok(())
2747 }
2748 }
2749
2750 impl ::fidl_next::IntoNatural for ControllerIsStartedResponse {
2751 type Natural = crate::natural::ControllerIsStartedResponse;
2752 }
2753
2754 impl ::fidl_next::Unconstrained for ControllerIsStartedResponse {}
2755
2756 #[derive(Debug)]
2758 #[repr(C)]
2759 pub struct ControllerGetExposedDictionaryResponse {
2760 pub dictionary: ::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef,
2761 }
2762
2763 static_assertions::const_assert_eq!(
2764 std::mem::size_of::<ControllerGetExposedDictionaryResponse>(),
2765 4
2766 );
2767 static_assertions::const_assert_eq!(
2768 std::mem::align_of::<ControllerGetExposedDictionaryResponse>(),
2769 4
2770 );
2771
2772 static_assertions::const_assert_eq!(
2773 std::mem::offset_of!(ControllerGetExposedDictionaryResponse, dictionary),
2774 0
2775 );
2776
2777 unsafe impl ::fidl_next::Wire for ControllerGetExposedDictionaryResponse {
2778 type Owned<'de> = ControllerGetExposedDictionaryResponse;
2779
2780 #[inline]
2781 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
2782 ::fidl_next::munge! {
2783 let Self {
2784
2785 dictionary,
2786
2787 } = &mut *out_;
2788 }
2789
2790 ::fidl_next::Wire::zero_padding(dictionary);
2791 }
2792 }
2793
2794 unsafe impl<___D> ::fidl_next::Decode<___D> for ControllerGetExposedDictionaryResponse
2795 where
2796 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
2797 ___D: ::fidl_next::fuchsia::HandleDecoder,
2798 {
2799 fn decode(
2800 slot_: ::fidl_next::Slot<'_, Self>,
2801 decoder_: &mut ___D,
2802 _: (),
2803 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
2804 ::fidl_next::munge! {
2805 let Self {
2806
2807 mut dictionary,
2808
2809 } = slot_;
2810 }
2811
2812 let _field = dictionary.as_mut();
2813
2814 ::fidl_next::Decode::decode(dictionary.as_mut(), decoder_, ())?;
2815
2816 Ok(())
2817 }
2818 }
2819
2820 impl ::fidl_next::IntoNatural for ControllerGetExposedDictionaryResponse {
2821 type Natural = crate::natural::ControllerGetExposedDictionaryResponse;
2822 }
2823
2824 impl ::fidl_next::Unconstrained for ControllerGetExposedDictionaryResponse {}
2825
2826 #[repr(C)]
2828 pub struct NamespaceEntry<'de> {
2829 pub(crate) table: ::fidl_next::WireTable<'de>,
2830 }
2831
2832 impl<'de> Drop for NamespaceEntry<'de> {
2833 fn drop(&mut self) {
2834 let _ = self.table.get(1).map(|envelope| unsafe {
2835 envelope.read_unchecked::<::fidl_next::WireString<'de>>()
2836 });
2837
2838 let _ = self.table.get(2).map(|envelope| unsafe {
2839 envelope.read_unchecked::<::fidl_next::ClientEnd<
2840 ::fidl_next_fuchsia_io::Directory,
2841 ::fidl_next::fuchsia::WireChannel,
2842 >>()
2843 });
2844 }
2845 }
2846
2847 unsafe impl ::fidl_next::Wire for NamespaceEntry<'static> {
2848 type Owned<'de> = NamespaceEntry<'de>;
2849
2850 #[inline]
2851 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
2852 ::fidl_next::munge!(let Self { table } = out);
2853 ::fidl_next::WireTable::zero_padding(table);
2854 }
2855 }
2856
2857 unsafe impl<___D> ::fidl_next::Decode<___D> for NamespaceEntry<'static>
2858 where
2859 ___D: ::fidl_next::Decoder + ?Sized,
2860 ___D: ::fidl_next::fuchsia::HandleDecoder,
2861 {
2862 fn decode(
2863 slot: ::fidl_next::Slot<'_, Self>,
2864 decoder: &mut ___D,
2865 _: (),
2866 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
2867 ::fidl_next::munge!(let Self { table } = slot);
2868
2869 ::fidl_next::WireTable::decode_with(table, decoder, |ordinal, mut slot, decoder| {
2870 match ordinal {
2871 0 => unsafe { ::core::hint::unreachable_unchecked() },
2872
2873 1 => {
2874 ::fidl_next::WireEnvelope::decode_as::<
2875 ___D,
2876 ::fidl_next::WireString<'static>,
2877 >(slot.as_mut(), decoder, 4095)?;
2878
2879 let value = unsafe {
2880 slot.deref_unchecked().deref_unchecked::<::fidl_next::WireString<'_>>()
2881 };
2882
2883 if value.len() > 4095 {
2884 return Err(::fidl_next::DecodeError::VectorTooLong {
2885 size: value.len() as u64,
2886 limit: 4095,
2887 });
2888 }
2889
2890 Ok(())
2891 }
2892
2893 2 => {
2894 ::fidl_next::WireEnvelope::decode_as::<
2895 ___D,
2896 ::fidl_next::ClientEnd<
2897 ::fidl_next_fuchsia_io::Directory,
2898 ::fidl_next::fuchsia::WireChannel,
2899 >,
2900 >(slot.as_mut(), decoder, ())?;
2901
2902 Ok(())
2903 }
2904
2905 _ => ::fidl_next::WireEnvelope::decode_unknown(slot, decoder),
2906 }
2907 })
2908 }
2909 }
2910
2911 impl<'de> NamespaceEntry<'de> {
2912 pub fn path(&self) -> ::core::option::Option<&::fidl_next::WireString<'de>> {
2913 unsafe { Some(self.table.get(1)?.deref_unchecked()) }
2914 }
2915
2916 pub fn directory(
2917 &self,
2918 ) -> ::core::option::Option<
2919 &::fidl_next::ClientEnd<
2920 ::fidl_next_fuchsia_io::Directory,
2921 ::fidl_next::fuchsia::WireChannel,
2922 >,
2923 > {
2924 unsafe { Some(self.table.get(2)?.deref_unchecked()) }
2925 }
2926 }
2927
2928 impl<'de> ::core::fmt::Debug for NamespaceEntry<'de> {
2929 fn fmt(
2930 &self,
2931 f: &mut ::core::fmt::Formatter<'_>,
2932 ) -> ::core::result::Result<(), ::core::fmt::Error> {
2933 f.debug_struct("NamespaceEntry")
2934 .field("path", &self.path())
2935 .field("directory", &self.directory())
2936 .finish()
2937 }
2938 }
2939
2940 impl<'de> ::fidl_next::IntoNatural for NamespaceEntry<'de> {
2941 type Natural = crate::natural::NamespaceEntry;
2942 }
2943
2944 impl ::fidl_next::Unconstrained for NamespaceEntry<'_> {}
2945
2946 #[repr(C)]
2948 pub struct StartChildArgs<'de> {
2949 pub(crate) table: ::fidl_next::WireTable<'de>,
2950 }
2951
2952 impl<'de> Drop for StartChildArgs<'de> {
2953 fn drop(&mut self) {
2954 let _ = self.table.get(1)
2955 .map(|envelope| unsafe {
2956 envelope.read_unchecked::<::fidl_next::WireVector<'de, ::fidl_next_fuchsia_process::wire::HandleInfo>>()
2957 });
2958
2959 let _ = self.table.get(2)
2960 .map(|envelope| unsafe {
2961 envelope.read_unchecked::<::fidl_next::WireVector<'de, crate::wire::NamespaceEntry<'de>>>()
2962 });
2963
2964 let _ = self.table.get(3)
2965 .map(|envelope| unsafe {
2966 envelope.read_unchecked::<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef>()
2967 });
2968 }
2969 }
2970
2971 unsafe impl ::fidl_next::Wire for StartChildArgs<'static> {
2972 type Owned<'de> = StartChildArgs<'de>;
2973
2974 #[inline]
2975 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
2976 ::fidl_next::munge!(let Self { table } = out);
2977 ::fidl_next::WireTable::zero_padding(table);
2978 }
2979 }
2980
2981 unsafe impl<___D> ::fidl_next::Decode<___D> for StartChildArgs<'static>
2982 where
2983 ___D: ::fidl_next::Decoder + ?Sized,
2984 ___D: ::fidl_next::fuchsia::HandleDecoder,
2985 {
2986 fn decode(
2987 slot: ::fidl_next::Slot<'_, Self>,
2988 decoder: &mut ___D,
2989 _: (),
2990 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
2991 ::fidl_next::munge!(let Self { table } = slot);
2992
2993 ::fidl_next::WireTable::decode_with(table, decoder, |ordinal, mut slot, decoder| {
2994 match ordinal {
2995 0 => unsafe { ::core::hint::unreachable_unchecked() },
2996
2997 1 => {
2998 ::fidl_next::WireEnvelope::decode_as::<
2999 ___D,
3000 ::fidl_next::WireVector<
3001 'static,
3002 ::fidl_next_fuchsia_process::wire::HandleInfo,
3003 >,
3004 >(slot.as_mut(), decoder, (128, ()))?;
3005
3006 let value = unsafe {
3007 slot.deref_unchecked().deref_unchecked::<::fidl_next::WireVector<
3008 '_,
3009 ::fidl_next_fuchsia_process::wire::HandleInfo,
3010 >>()
3011 };
3012
3013 if value.len() > 128 {
3014 return Err(::fidl_next::DecodeError::VectorTooLong {
3015 size: value.len() as u64,
3016 limit: 128,
3017 });
3018 }
3019
3020 Ok(())
3021 }
3022
3023 2 => {
3024 ::fidl_next::WireEnvelope::decode_as::<
3025 ___D,
3026 ::fidl_next::WireVector<'static, crate::wire::NamespaceEntry<'static>>,
3027 >(slot.as_mut(), decoder, (32, ()))?;
3028
3029 let value = unsafe {
3030 slot
3031 .deref_unchecked()
3032 .deref_unchecked::<
3033 ::fidl_next::WireVector<'_, crate::wire::NamespaceEntry<'_>>
3034 >()
3035 };
3036
3037 if value.len() > 32 {
3038 return Err(::fidl_next::DecodeError::VectorTooLong {
3039 size: value.len() as u64,
3040 limit: 32,
3041 });
3042 }
3043
3044 Ok(())
3045 }
3046
3047 3 => {
3048 ::fidl_next::WireEnvelope::decode_as::<
3049 ___D,
3050 ::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef,
3051 >(slot.as_mut(), decoder, ())?;
3052
3053 Ok(())
3054 }
3055
3056 _ => ::fidl_next::WireEnvelope::decode_unknown(slot, decoder),
3057 }
3058 })
3059 }
3060 }
3061
3062 impl<'de> StartChildArgs<'de> {
3063 pub fn numbered_handles(
3064 &self,
3065 ) -> ::core::option::Option<
3066 &::fidl_next::WireVector<'de, ::fidl_next_fuchsia_process::wire::HandleInfo>,
3067 > {
3068 unsafe { Some(self.table.get(1)?.deref_unchecked()) }
3069 }
3070
3071 pub fn namespace_entries(
3072 &self,
3073 ) -> ::core::option::Option<&::fidl_next::WireVector<'de, crate::wire::NamespaceEntry<'de>>>
3074 {
3075 unsafe { Some(self.table.get(2)?.deref_unchecked()) }
3076 }
3077
3078 pub fn dictionary(
3079 &self,
3080 ) -> ::core::option::Option<&::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef>
3081 {
3082 unsafe { Some(self.table.get(3)?.deref_unchecked()) }
3083 }
3084 }
3085
3086 impl<'de> ::core::fmt::Debug for StartChildArgs<'de> {
3087 fn fmt(
3088 &self,
3089 f: &mut ::core::fmt::Formatter<'_>,
3090 ) -> ::core::result::Result<(), ::core::fmt::Error> {
3091 f.debug_struct("StartChildArgs")
3092 .field("numbered_handles", &self.numbered_handles())
3093 .field("namespace_entries", &self.namespace_entries())
3094 .field("dictionary", &self.dictionary())
3095 .finish()
3096 }
3097 }
3098
3099 impl<'de> ::fidl_next::IntoNatural for StartChildArgs<'de> {
3100 type Natural = crate::natural::StartChildArgs;
3101 }
3102
3103 impl ::fidl_next::Unconstrained for StartChildArgs<'_> {}
3104
3105 #[derive(Debug)]
3107 #[repr(C)]
3108 pub struct ControllerStartRequest<'de> {
3109 pub args: crate::wire::StartChildArgs<'de>,
3110
3111 pub execution_controller:
3112 ::fidl_next::ServerEnd<crate::ExecutionController, ::fidl_next::fuchsia::WireChannel>,
3113 }
3114
3115 static_assertions::const_assert_eq!(std::mem::size_of::<ControllerStartRequest<'_>>(), 24);
3116 static_assertions::const_assert_eq!(std::mem::align_of::<ControllerStartRequest<'_>>(), 8);
3117
3118 static_assertions::const_assert_eq!(std::mem::offset_of!(ControllerStartRequest<'_>, args), 0);
3119
3120 static_assertions::const_assert_eq!(
3121 std::mem::offset_of!(ControllerStartRequest<'_>, execution_controller),
3122 16
3123 );
3124
3125 unsafe impl ::fidl_next::Wire for ControllerStartRequest<'static> {
3126 type Owned<'de> = ControllerStartRequest<'de>;
3127
3128 #[inline]
3129 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
3130 ::fidl_next::munge! {
3131 let Self {
3132
3133 args,
3134 execution_controller,
3135
3136 } = &mut *out_;
3137 }
3138
3139 ::fidl_next::Wire::zero_padding(args);
3140
3141 ::fidl_next::Wire::zero_padding(execution_controller);
3142
3143 unsafe {
3144 out_.as_mut_ptr().cast::<u8>().add(20).write_bytes(0, 4);
3145 }
3146 }
3147 }
3148
3149 unsafe impl<___D> ::fidl_next::Decode<___D> for ControllerStartRequest<'static>
3150 where
3151 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
3152 ___D: ::fidl_next::Decoder,
3153 ___D: ::fidl_next::fuchsia::HandleDecoder,
3154 {
3155 fn decode(
3156 slot_: ::fidl_next::Slot<'_, Self>,
3157 decoder_: &mut ___D,
3158 _: (),
3159 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
3160 if slot_.as_bytes()[20..24] != [0u8; 4] {
3161 return Err(::fidl_next::DecodeError::InvalidPadding);
3162 }
3163
3164 ::fidl_next::munge! {
3165 let Self {
3166
3167 mut args,
3168 mut execution_controller,
3169
3170 } = slot_;
3171 }
3172
3173 let _field = args.as_mut();
3174
3175 ::fidl_next::Decode::decode(args.as_mut(), decoder_, ())?;
3176
3177 let _field = execution_controller.as_mut();
3178
3179 ::fidl_next::Decode::decode(execution_controller.as_mut(), decoder_, ())?;
3180
3181 Ok(())
3182 }
3183 }
3184
3185 impl<'de> ::fidl_next::IntoNatural for ControllerStartRequest<'de> {
3186 type Natural = crate::natural::ControllerStartRequest;
3187 }
3188
3189 impl ::fidl_next::Unconstrained for ControllerStartRequest<'static> {}
3190
3191 #[repr(C)]
3193 pub struct CreateChildArgs<'de> {
3194 pub(crate) table: ::fidl_next::WireTable<'de>,
3195 }
3196
3197 impl<'de> Drop for CreateChildArgs<'de> {
3198 fn drop(&mut self) {
3199 let _ = self.table.get(1)
3200 .map(|envelope| unsafe {
3201 envelope.read_unchecked::<::fidl_next::WireVector<'de, ::fidl_next_fuchsia_process::wire::HandleInfo>>()
3202 });
3203
3204 let _ = self.table.get(2).map(|envelope| unsafe {
3205 envelope.read_unchecked::<::fidl_next::WireVector<
3206 'de,
3207 ::fidl_next_fuchsia_component_decl::wire::Offer<'de>,
3208 >>()
3209 });
3210
3211 let _ = self.table.get(3)
3212 .map(|envelope| unsafe {
3213 envelope.read_unchecked::<::fidl_next::ServerEnd<crate::Controller, ::fidl_next::fuchsia::WireChannel>>()
3214 });
3215
3216 let _ = self.table.get(4)
3217 .map(|envelope| unsafe {
3218 envelope.read_unchecked::<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef>()
3219 });
3220 }
3221 }
3222
3223 unsafe impl ::fidl_next::Wire for CreateChildArgs<'static> {
3224 type Owned<'de> = CreateChildArgs<'de>;
3225
3226 #[inline]
3227 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
3228 ::fidl_next::munge!(let Self { table } = out);
3229 ::fidl_next::WireTable::zero_padding(table);
3230 }
3231 }
3232
3233 unsafe impl<___D> ::fidl_next::Decode<___D> for CreateChildArgs<'static>
3234 where
3235 ___D: ::fidl_next::Decoder + ?Sized,
3236 ___D: ::fidl_next::fuchsia::HandleDecoder,
3237 {
3238 fn decode(
3239 slot: ::fidl_next::Slot<'_, Self>,
3240 decoder: &mut ___D,
3241 _: (),
3242 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
3243 ::fidl_next::munge!(let Self { table } = slot);
3244
3245 ::fidl_next::WireTable::decode_with(table, decoder, |ordinal, mut slot, decoder| {
3246 match ordinal {
3247 0 => unsafe { ::core::hint::unreachable_unchecked() },
3248
3249 1 => {
3250 ::fidl_next::WireEnvelope::decode_as::<
3251 ___D,
3252 ::fidl_next::WireVector<
3253 'static,
3254 ::fidl_next_fuchsia_process::wire::HandleInfo,
3255 >,
3256 >(slot.as_mut(), decoder, (128, ()))?;
3257
3258 let value = unsafe {
3259 slot.deref_unchecked().deref_unchecked::<::fidl_next::WireVector<
3260 '_,
3261 ::fidl_next_fuchsia_process::wire::HandleInfo,
3262 >>()
3263 };
3264
3265 if value.len() > 128 {
3266 return Err(::fidl_next::DecodeError::VectorTooLong {
3267 size: value.len() as u64,
3268 limit: 128,
3269 });
3270 }
3271
3272 Ok(())
3273 }
3274
3275 2 => {
3276 ::fidl_next::WireEnvelope::decode_as::<
3277 ___D,
3278 ::fidl_next::WireVector<
3279 'static,
3280 ::fidl_next_fuchsia_component_decl::wire::Offer<'static>,
3281 >,
3282 >(slot.as_mut(), decoder, (128, ()))?;
3283
3284 let value = unsafe {
3285 slot.deref_unchecked().deref_unchecked::<::fidl_next::WireVector<
3286 '_,
3287 ::fidl_next_fuchsia_component_decl::wire::Offer<'_>,
3288 >>()
3289 };
3290
3291 if value.len() > 128 {
3292 return Err(::fidl_next::DecodeError::VectorTooLong {
3293 size: value.len() as u64,
3294 limit: 128,
3295 });
3296 }
3297
3298 Ok(())
3299 }
3300
3301 3 => {
3302 ::fidl_next::WireEnvelope::decode_as::<
3303 ___D,
3304 ::fidl_next::ServerEnd<
3305 crate::Controller,
3306 ::fidl_next::fuchsia::WireChannel,
3307 >,
3308 >(slot.as_mut(), decoder, ())?;
3309
3310 Ok(())
3311 }
3312
3313 4 => {
3314 ::fidl_next::WireEnvelope::decode_as::<
3315 ___D,
3316 ::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef,
3317 >(slot.as_mut(), decoder, ())?;
3318
3319 Ok(())
3320 }
3321
3322 _ => ::fidl_next::WireEnvelope::decode_unknown(slot, decoder),
3323 }
3324 })
3325 }
3326 }
3327
3328 impl<'de> CreateChildArgs<'de> {
3329 pub fn numbered_handles(
3330 &self,
3331 ) -> ::core::option::Option<
3332 &::fidl_next::WireVector<'de, ::fidl_next_fuchsia_process::wire::HandleInfo>,
3333 > {
3334 unsafe { Some(self.table.get(1)?.deref_unchecked()) }
3335 }
3336
3337 pub fn dynamic_offers(
3338 &self,
3339 ) -> ::core::option::Option<
3340 &::fidl_next::WireVector<'de, ::fidl_next_fuchsia_component_decl::wire::Offer<'de>>,
3341 > {
3342 unsafe { Some(self.table.get(2)?.deref_unchecked()) }
3343 }
3344
3345 pub fn controller(
3346 &self,
3347 ) -> ::core::option::Option<
3348 &::fidl_next::ServerEnd<crate::Controller, ::fidl_next::fuchsia::WireChannel>,
3349 > {
3350 unsafe { Some(self.table.get(3)?.deref_unchecked()) }
3351 }
3352
3353 pub fn dictionary(
3354 &self,
3355 ) -> ::core::option::Option<&::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef>
3356 {
3357 unsafe { Some(self.table.get(4)?.deref_unchecked()) }
3358 }
3359 }
3360
3361 impl<'de> ::core::fmt::Debug for CreateChildArgs<'de> {
3362 fn fmt(
3363 &self,
3364 f: &mut ::core::fmt::Formatter<'_>,
3365 ) -> ::core::result::Result<(), ::core::fmt::Error> {
3366 f.debug_struct("CreateChildArgs")
3367 .field("numbered_handles", &self.numbered_handles())
3368 .field("dynamic_offers", &self.dynamic_offers())
3369 .field("controller", &self.controller())
3370 .field("dictionary", &self.dictionary())
3371 .finish()
3372 }
3373 }
3374
3375 impl<'de> ::fidl_next::IntoNatural for CreateChildArgs<'de> {
3376 type Natural = crate::natural::CreateChildArgs;
3377 }
3378
3379 impl ::fidl_next::Unconstrained for CreateChildArgs<'_> {}
3380
3381 #[repr(C)]
3383 pub struct DebugStartedPayload<'de> {
3384 pub(crate) table: ::fidl_next::WireTable<'de>,
3385 }
3386
3387 impl<'de> Drop for DebugStartedPayload<'de> {
3388 fn drop(&mut self) {
3389 let _ = self.table.get(1).map(|envelope| unsafe {
3390 envelope.read_unchecked::<::fidl_next::ClientEnd<
3391 ::fidl_next_fuchsia_io::Directory,
3392 ::fidl_next::fuchsia::WireChannel,
3393 >>()
3394 });
3395
3396 let _ = self.table.get(2).map(|envelope| unsafe {
3397 envelope.read_unchecked::<::fidl_next::fuchsia::WireEventPair>()
3398 });
3399 }
3400 }
3401
3402 unsafe impl ::fidl_next::Wire for DebugStartedPayload<'static> {
3403 type Owned<'de> = DebugStartedPayload<'de>;
3404
3405 #[inline]
3406 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
3407 ::fidl_next::munge!(let Self { table } = out);
3408 ::fidl_next::WireTable::zero_padding(table);
3409 }
3410 }
3411
3412 unsafe impl<___D> ::fidl_next::Decode<___D> for DebugStartedPayload<'static>
3413 where
3414 ___D: ::fidl_next::Decoder + ?Sized,
3415 ___D: ::fidl_next::fuchsia::HandleDecoder,
3416 {
3417 fn decode(
3418 slot: ::fidl_next::Slot<'_, Self>,
3419 decoder: &mut ___D,
3420 _: (),
3421 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
3422 ::fidl_next::munge!(let Self { table } = slot);
3423
3424 ::fidl_next::WireTable::decode_with(table, decoder, |ordinal, mut slot, decoder| {
3425 match ordinal {
3426 0 => unsafe { ::core::hint::unreachable_unchecked() },
3427
3428 1 => {
3429 ::fidl_next::WireEnvelope::decode_as::<
3430 ___D,
3431 ::fidl_next::ClientEnd<
3432 ::fidl_next_fuchsia_io::Directory,
3433 ::fidl_next::fuchsia::WireChannel,
3434 >,
3435 >(slot.as_mut(), decoder, ())?;
3436
3437 Ok(())
3438 }
3439
3440 2 => {
3441 ::fidl_next::WireEnvelope::decode_as::<
3442 ___D,
3443 ::fidl_next::fuchsia::WireEventPair,
3444 >(slot.as_mut(), decoder, ())?;
3445
3446 Ok(())
3447 }
3448
3449 _ => ::fidl_next::WireEnvelope::decode_unknown(slot, decoder),
3450 }
3451 })
3452 }
3453 }
3454
3455 impl<'de> DebugStartedPayload<'de> {
3456 pub fn runtime_dir(
3457 &self,
3458 ) -> ::core::option::Option<
3459 &::fidl_next::ClientEnd<
3460 ::fidl_next_fuchsia_io::Directory,
3461 ::fidl_next::fuchsia::WireChannel,
3462 >,
3463 > {
3464 unsafe { Some(self.table.get(1)?.deref_unchecked()) }
3465 }
3466
3467 pub fn break_on_start(
3468 &self,
3469 ) -> ::core::option::Option<&::fidl_next::fuchsia::WireEventPair> {
3470 unsafe { Some(self.table.get(2)?.deref_unchecked()) }
3471 }
3472 }
3473
3474 impl<'de> ::core::fmt::Debug for DebugStartedPayload<'de> {
3475 fn fmt(
3476 &self,
3477 f: &mut ::core::fmt::Formatter<'_>,
3478 ) -> ::core::result::Result<(), ::core::fmt::Error> {
3479 f.debug_struct("DebugStartedPayload")
3480 .field("runtime_dir", &self.runtime_dir())
3481 .field("break_on_start", &self.break_on_start())
3482 .finish()
3483 }
3484 }
3485
3486 impl<'de> ::fidl_next::IntoNatural for DebugStartedPayload<'de> {
3487 type Natural = crate::natural::DebugStartedPayload;
3488 }
3489
3490 impl ::fidl_next::Unconstrained for DebugStartedPayload<'_> {}
3491
3492 #[repr(transparent)]
3494 pub struct EventPayload<'de> {
3495 pub(crate) raw: ::fidl_next::RawWireUnion,
3496 pub(crate) _phantom: ::core::marker::PhantomData<&'de mut [::fidl_next::Chunk]>,
3497 }
3498
3499 impl<'de> Drop for EventPayload<'de> {
3500 fn drop(&mut self) {
3501 match self.raw.ordinal() {
3502 1 => {
3503 let _ = unsafe {
3504 self.raw
3505 .get()
3506 .read_unchecked::<crate::wire::CapabilityRequestedPayload<'de>>()
3507 };
3508 }
3509
3510 2 => {
3511 let _ = unsafe {
3512 self.raw.get().read_unchecked::<crate::wire::PurgedPayload<'de>>()
3513 };
3514 }
3515
3516 4 => {
3517 let _ = unsafe {
3518 self.raw.get().read_unchecked::<crate::wire::DiscoveredPayload<'de>>()
3519 };
3520 }
3521
3522 5 => {
3523 let _ = unsafe {
3524 self.raw.get().read_unchecked::<crate::wire::DestroyedPayload<'de>>()
3525 };
3526 }
3527
3528 6 => {
3529 let _ = unsafe {
3530 self.raw.get().read_unchecked::<crate::wire::ResolvedPayload<'de>>()
3531 };
3532 }
3533
3534 7 => {
3535 let _ = unsafe {
3536 self.raw.get().read_unchecked::<crate::wire::StartedPayload<'de>>()
3537 };
3538 }
3539
3540 8 => {
3541 let _ = unsafe {
3542 self.raw.get().read_unchecked::<crate::wire::StoppedPayload<'de>>()
3543 };
3544 }
3545
3546 9 => {
3547 let _ = unsafe {
3548 self.raw.get().read_unchecked::<crate::wire::DebugStartedPayload<'de>>()
3549 };
3550 }
3551
3552 10 => {
3553 let _ = unsafe {
3554 self.raw.get().read_unchecked::<crate::wire::UnresolvedPayload<'de>>()
3555 };
3556 }
3557
3558 _ => (),
3559 }
3560 }
3561 }
3562
3563 unsafe impl ::fidl_next::Wire for EventPayload<'static> {
3564 type Owned<'de> = EventPayload<'de>;
3565
3566 #[inline]
3567 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
3568 ::fidl_next::munge!(let Self { raw, _phantom: _ } = out);
3569 ::fidl_next::RawWireUnion::zero_padding(raw);
3570 }
3571 }
3572
3573 pub mod event_payload {
3574 pub enum Ref<'de> {
3575 CapabilityRequested(&'de crate::wire::CapabilityRequestedPayload<'de>),
3576
3577 Purged(&'de crate::wire::PurgedPayload<'de>),
3578
3579 Discovered(&'de crate::wire::DiscoveredPayload<'de>),
3580
3581 Destroyed(&'de crate::wire::DestroyedPayload<'de>),
3582
3583 Resolved(&'de crate::wire::ResolvedPayload<'de>),
3584
3585 Started(&'de crate::wire::StartedPayload<'de>),
3586
3587 Stopped(&'de crate::wire::StoppedPayload<'de>),
3588
3589 DebugStarted(&'de crate::wire::DebugStartedPayload<'de>),
3590
3591 Unresolved(&'de crate::wire::UnresolvedPayload<'de>),
3592
3593 UnknownOrdinal_(u64),
3594 }
3595 }
3596
3597 impl<'de> EventPayload<'de> {
3598 pub fn as_ref(&self) -> crate::wire::event_payload::Ref<'_> {
3599 match self.raw.ordinal() {
3600 1 => crate::wire::event_payload::Ref::CapabilityRequested(unsafe {
3601 self.raw.get().deref_unchecked::<crate::wire::CapabilityRequestedPayload<'_>>()
3602 }),
3603
3604 2 => crate::wire::event_payload::Ref::Purged(unsafe {
3605 self.raw.get().deref_unchecked::<crate::wire::PurgedPayload<'_>>()
3606 }),
3607
3608 4 => crate::wire::event_payload::Ref::Discovered(unsafe {
3609 self.raw.get().deref_unchecked::<crate::wire::DiscoveredPayload<'_>>()
3610 }),
3611
3612 5 => crate::wire::event_payload::Ref::Destroyed(unsafe {
3613 self.raw.get().deref_unchecked::<crate::wire::DestroyedPayload<'_>>()
3614 }),
3615
3616 6 => crate::wire::event_payload::Ref::Resolved(unsafe {
3617 self.raw.get().deref_unchecked::<crate::wire::ResolvedPayload<'_>>()
3618 }),
3619
3620 7 => crate::wire::event_payload::Ref::Started(unsafe {
3621 self.raw.get().deref_unchecked::<crate::wire::StartedPayload<'_>>()
3622 }),
3623
3624 8 => crate::wire::event_payload::Ref::Stopped(unsafe {
3625 self.raw.get().deref_unchecked::<crate::wire::StoppedPayload<'_>>()
3626 }),
3627
3628 9 => crate::wire::event_payload::Ref::DebugStarted(unsafe {
3629 self.raw.get().deref_unchecked::<crate::wire::DebugStartedPayload<'_>>()
3630 }),
3631
3632 10 => crate::wire::event_payload::Ref::Unresolved(unsafe {
3633 self.raw.get().deref_unchecked::<crate::wire::UnresolvedPayload<'_>>()
3634 }),
3635
3636 unknown => crate::wire::event_payload::Ref::UnknownOrdinal_(unknown),
3637 }
3638 }
3639 }
3640
3641 unsafe impl<___D> ::fidl_next::Decode<___D> for EventPayload<'static>
3642 where
3643 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
3644 ___D: ::fidl_next::Decoder,
3645 ___D: ::fidl_next::fuchsia::HandleDecoder,
3646 {
3647 fn decode(
3648 mut slot: ::fidl_next::Slot<'_, Self>,
3649 decoder: &mut ___D,
3650 _: (),
3651 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
3652 ::fidl_next::munge!(let Self { mut raw, _phantom: _ } = slot.as_mut());
3653 match ::fidl_next::RawWireUnion::encoded_ordinal(raw.as_mut()) {
3654 1 => ::fidl_next::RawWireUnion::decode_as::<
3655 ___D,
3656 crate::wire::CapabilityRequestedPayload<'static>,
3657 >(raw, decoder, ())?,
3658
3659 2 => ::fidl_next::RawWireUnion::decode_as::<
3660 ___D,
3661 crate::wire::PurgedPayload<'static>,
3662 >(raw, decoder, ())?,
3663
3664 4 => ::fidl_next::RawWireUnion::decode_as::<
3665 ___D,
3666 crate::wire::DiscoveredPayload<'static>,
3667 >(raw, decoder, ())?,
3668
3669 5 => ::fidl_next::RawWireUnion::decode_as::<
3670 ___D,
3671 crate::wire::DestroyedPayload<'static>,
3672 >(raw, decoder, ())?,
3673
3674 6 => ::fidl_next::RawWireUnion::decode_as::<
3675 ___D,
3676 crate::wire::ResolvedPayload<'static>,
3677 >(raw, decoder, ())?,
3678
3679 7 => ::fidl_next::RawWireUnion::decode_as::<
3680 ___D,
3681 crate::wire::StartedPayload<'static>,
3682 >(raw, decoder, ())?,
3683
3684 8 => ::fidl_next::RawWireUnion::decode_as::<
3685 ___D,
3686 crate::wire::StoppedPayload<'static>,
3687 >(raw, decoder, ())?,
3688
3689 9 => ::fidl_next::RawWireUnion::decode_as::<
3690 ___D,
3691 crate::wire::DebugStartedPayload<'static>,
3692 >(raw, decoder, ())?,
3693
3694 10 => ::fidl_next::RawWireUnion::decode_as::<
3695 ___D,
3696 crate::wire::UnresolvedPayload<'static>,
3697 >(raw, decoder, ())?,
3698
3699 _ => ::fidl_next::RawWireUnion::decode_unknown(raw, decoder)?,
3700 }
3701
3702 Ok(())
3703 }
3704 }
3705
3706 impl<'de> ::core::fmt::Debug for EventPayload<'de> {
3707 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
3708 match self.raw.ordinal() {
3709 1 => unsafe {
3710 self.raw
3711 .get()
3712 .deref_unchecked::<crate::wire::CapabilityRequestedPayload<'_>>()
3713 .fmt(f)
3714 },
3715 2 => unsafe {
3716 self.raw.get().deref_unchecked::<crate::wire::PurgedPayload<'_>>().fmt(f)
3717 },
3718 4 => unsafe {
3719 self.raw.get().deref_unchecked::<crate::wire::DiscoveredPayload<'_>>().fmt(f)
3720 },
3721 5 => unsafe {
3722 self.raw.get().deref_unchecked::<crate::wire::DestroyedPayload<'_>>().fmt(f)
3723 },
3724 6 => unsafe {
3725 self.raw.get().deref_unchecked::<crate::wire::ResolvedPayload<'_>>().fmt(f)
3726 },
3727 7 => unsafe {
3728 self.raw.get().deref_unchecked::<crate::wire::StartedPayload<'_>>().fmt(f)
3729 },
3730 8 => unsafe {
3731 self.raw.get().deref_unchecked::<crate::wire::StoppedPayload<'_>>().fmt(f)
3732 },
3733 9 => unsafe {
3734 self.raw.get().deref_unchecked::<crate::wire::DebugStartedPayload<'_>>().fmt(f)
3735 },
3736 10 => unsafe {
3737 self.raw.get().deref_unchecked::<crate::wire::UnresolvedPayload<'_>>().fmt(f)
3738 },
3739 _ => unsafe { ::core::hint::unreachable_unchecked() },
3740 }
3741 }
3742 }
3743
3744 impl<'de> ::fidl_next::IntoNatural for EventPayload<'de> {
3745 type Natural = crate::natural::EventPayload;
3746 }
3747
3748 impl ::fidl_next::Unconstrained for EventPayload<'static> {}
3749
3750 #[repr(C)]
3752 pub struct Event<'de> {
3753 pub(crate) table: ::fidl_next::WireTable<'de>,
3754 }
3755
3756 impl<'de> Drop for Event<'de> {
3757 fn drop(&mut self) {
3758 let _ = self.table.get(1).map(|envelope| unsafe {
3759 envelope.read_unchecked::<crate::wire::EventHeader<'de>>()
3760 });
3761
3762 let _ = self.table.get(2).map(|envelope| unsafe {
3763 envelope.read_unchecked::<crate::wire::EventPayload<'de>>()
3764 });
3765 }
3766 }
3767
3768 unsafe impl ::fidl_next::Wire for Event<'static> {
3769 type Owned<'de> = Event<'de>;
3770
3771 #[inline]
3772 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
3773 ::fidl_next::munge!(let Self { table } = out);
3774 ::fidl_next::WireTable::zero_padding(table);
3775 }
3776 }
3777
3778 unsafe impl<___D> ::fidl_next::Decode<___D> for Event<'static>
3779 where
3780 ___D: ::fidl_next::Decoder + ?Sized,
3781 ___D: ::fidl_next::fuchsia::HandleDecoder,
3782 {
3783 fn decode(
3784 slot: ::fidl_next::Slot<'_, Self>,
3785 decoder: &mut ___D,
3786 _: (),
3787 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
3788 ::fidl_next::munge!(let Self { table } = slot);
3789
3790 ::fidl_next::WireTable::decode_with(table, decoder, |ordinal, mut slot, decoder| {
3791 match ordinal {
3792 0 => unsafe { ::core::hint::unreachable_unchecked() },
3793
3794 1 => {
3795 ::fidl_next::WireEnvelope::decode_as::<
3796 ___D,
3797 crate::wire::EventHeader<'static>,
3798 >(slot.as_mut(), decoder, ())?;
3799
3800 Ok(())
3801 }
3802
3803 2 => {
3804 ::fidl_next::WireEnvelope::decode_as::<
3805 ___D,
3806 crate::wire::EventPayload<'static>,
3807 >(slot.as_mut(), decoder, ())?;
3808
3809 Ok(())
3810 }
3811
3812 _ => ::fidl_next::WireEnvelope::decode_unknown(slot, decoder),
3813 }
3814 })
3815 }
3816 }
3817
3818 impl<'de> Event<'de> {
3819 pub fn header(&self) -> ::core::option::Option<&crate::wire::EventHeader<'de>> {
3820 unsafe { Some(self.table.get(1)?.deref_unchecked()) }
3821 }
3822
3823 pub fn payload(&self) -> ::core::option::Option<&crate::wire::EventPayload<'de>> {
3824 unsafe { Some(self.table.get(2)?.deref_unchecked()) }
3825 }
3826 }
3827
3828 impl<'de> ::core::fmt::Debug for Event<'de> {
3829 fn fmt(
3830 &self,
3831 f: &mut ::core::fmt::Formatter<'_>,
3832 ) -> ::core::result::Result<(), ::core::fmt::Error> {
3833 f.debug_struct("Event")
3834 .field("header", &self.header())
3835 .field("payload", &self.payload())
3836 .finish()
3837 }
3838 }
3839
3840 impl<'de> ::fidl_next::IntoNatural for Event<'de> {
3841 type Natural = crate::natural::Event;
3842 }
3843
3844 impl ::fidl_next::Unconstrained for Event<'_> {}
3845
3846 #[derive(Debug)]
3848 #[repr(C)]
3849 pub struct EventStreamGetNextResponse<'de> {
3850 pub events: ::fidl_next::WireVector<'de, crate::wire::Event<'de>>,
3851 }
3852
3853 static_assertions::const_assert_eq!(std::mem::size_of::<EventStreamGetNextResponse<'_>>(), 16);
3854 static_assertions::const_assert_eq!(std::mem::align_of::<EventStreamGetNextResponse<'_>>(), 8);
3855
3856 static_assertions::const_assert_eq!(
3857 std::mem::offset_of!(EventStreamGetNextResponse<'_>, events),
3858 0
3859 );
3860
3861 unsafe impl ::fidl_next::Wire for EventStreamGetNextResponse<'static> {
3862 type Owned<'de> = EventStreamGetNextResponse<'de>;
3863
3864 #[inline]
3865 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
3866 ::fidl_next::munge! {
3867 let Self {
3868
3869 events,
3870
3871 } = &mut *out_;
3872 }
3873
3874 ::fidl_next::Wire::zero_padding(events);
3875 }
3876 }
3877
3878 unsafe impl<___D> ::fidl_next::Decode<___D> for EventStreamGetNextResponse<'static>
3879 where
3880 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
3881 ___D: ::fidl_next::Decoder,
3882 ___D: ::fidl_next::fuchsia::HandleDecoder,
3883 {
3884 fn decode(
3885 slot_: ::fidl_next::Slot<'_, Self>,
3886 decoder_: &mut ___D,
3887 _: (),
3888 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
3889 ::fidl_next::munge! {
3890 let Self {
3891
3892 mut events,
3893
3894 } = slot_;
3895 }
3896
3897 let _field = events.as_mut();
3898 ::fidl_next::Constrained::validate(_field, (4294967295, ()))?;
3899 ::fidl_next::Decode::decode(events.as_mut(), decoder_, (4294967295, ()))?;
3900
3901 Ok(())
3902 }
3903 }
3904
3905 impl<'de> ::fidl_next::IntoNatural for EventStreamGetNextResponse<'de> {
3906 type Natural = crate::natural::EventStreamGetNextResponse;
3907 }
3908
3909 impl ::fidl_next::Unconstrained for EventStreamGetNextResponse<'static> {}
3910
3911 #[derive(Debug)]
3913 #[repr(C)]
3914 pub struct IntrospectorGetMonikerRequest {
3915 pub component_instance: ::fidl_next::fuchsia::WireEvent,
3916 }
3917
3918 static_assertions::const_assert_eq!(std::mem::size_of::<IntrospectorGetMonikerRequest>(), 4);
3919 static_assertions::const_assert_eq!(std::mem::align_of::<IntrospectorGetMonikerRequest>(), 4);
3920
3921 static_assertions::const_assert_eq!(
3922 std::mem::offset_of!(IntrospectorGetMonikerRequest, component_instance),
3923 0
3924 );
3925
3926 unsafe impl ::fidl_next::Wire for IntrospectorGetMonikerRequest {
3927 type Owned<'de> = IntrospectorGetMonikerRequest;
3928
3929 #[inline]
3930 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
3931 ::fidl_next::munge! {
3932 let Self {
3933
3934 component_instance,
3935
3936 } = &mut *out_;
3937 }
3938
3939 ::fidl_next::Wire::zero_padding(component_instance);
3940 }
3941 }
3942
3943 unsafe impl<___D> ::fidl_next::Decode<___D> for IntrospectorGetMonikerRequest
3944 where
3945 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
3946 ___D: ::fidl_next::fuchsia::HandleDecoder,
3947 {
3948 fn decode(
3949 slot_: ::fidl_next::Slot<'_, Self>,
3950 decoder_: &mut ___D,
3951 _: (),
3952 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
3953 ::fidl_next::munge! {
3954 let Self {
3955
3956 mut component_instance,
3957
3958 } = slot_;
3959 }
3960
3961 let _field = component_instance.as_mut();
3962
3963 ::fidl_next::Decode::decode(component_instance.as_mut(), decoder_, ())?;
3964
3965 Ok(())
3966 }
3967 }
3968
3969 impl ::fidl_next::IntoNatural for IntrospectorGetMonikerRequest {
3970 type Natural = crate::natural::IntrospectorGetMonikerRequest;
3971 }
3972
3973 impl ::fidl_next::Unconstrained for IntrospectorGetMonikerRequest {}
3974
3975 #[derive(Debug)]
3977 #[repr(C)]
3978 pub struct NamespaceInputEntry<'de> {
3979 pub path: ::fidl_next::WireString<'de>,
3980
3981 pub dictionary: ::fidl_next::ClientEnd<
3982 ::fidl_next_fuchsia_component_sandbox::Dictionary,
3983 ::fidl_next::fuchsia::WireChannel,
3984 >,
3985 }
3986
3987 static_assertions::const_assert_eq!(std::mem::size_of::<NamespaceInputEntry<'_>>(), 24);
3988 static_assertions::const_assert_eq!(std::mem::align_of::<NamespaceInputEntry<'_>>(), 8);
3989
3990 static_assertions::const_assert_eq!(std::mem::offset_of!(NamespaceInputEntry<'_>, path), 0);
3991
3992 static_assertions::const_assert_eq!(
3993 std::mem::offset_of!(NamespaceInputEntry<'_>, dictionary),
3994 16
3995 );
3996
3997 unsafe impl ::fidl_next::Wire for NamespaceInputEntry<'static> {
3998 type Owned<'de> = NamespaceInputEntry<'de>;
3999
4000 #[inline]
4001 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4002 ::fidl_next::munge! {
4003 let Self {
4004
4005 path,
4006 dictionary,
4007
4008 } = &mut *out_;
4009 }
4010
4011 ::fidl_next::Wire::zero_padding(path);
4012
4013 ::fidl_next::Wire::zero_padding(dictionary);
4014
4015 unsafe {
4016 out_.as_mut_ptr().cast::<u8>().add(20).write_bytes(0, 4);
4017 }
4018 }
4019 }
4020
4021 unsafe impl<___D> ::fidl_next::Decode<___D> for NamespaceInputEntry<'static>
4022 where
4023 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4024 ___D: ::fidl_next::Decoder,
4025 ___D: ::fidl_next::fuchsia::HandleDecoder,
4026 {
4027 fn decode(
4028 slot_: ::fidl_next::Slot<'_, Self>,
4029 decoder_: &mut ___D,
4030 _: (),
4031 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4032 if slot_.as_bytes()[20..24] != [0u8; 4] {
4033 return Err(::fidl_next::DecodeError::InvalidPadding);
4034 }
4035
4036 ::fidl_next::munge! {
4037 let Self {
4038
4039 mut path,
4040 mut dictionary,
4041
4042 } = slot_;
4043 }
4044
4045 let _field = path.as_mut();
4046 ::fidl_next::Constrained::validate(_field, 4095)?;
4047 ::fidl_next::Decode::decode(path.as_mut(), decoder_, 4095)?;
4048
4049 let path = unsafe { path.deref_unchecked() };
4050
4051 if path.len() > 4095 {
4052 return Err(::fidl_next::DecodeError::VectorTooLong {
4053 size: path.len() as u64,
4054 limit: 4095,
4055 });
4056 }
4057
4058 let _field = dictionary.as_mut();
4059
4060 ::fidl_next::Decode::decode(dictionary.as_mut(), decoder_, ())?;
4061
4062 Ok(())
4063 }
4064 }
4065
4066 impl<'de> ::fidl_next::IntoNatural for NamespaceInputEntry<'de> {
4067 type Natural = crate::natural::NamespaceInputEntry;
4068 }
4069
4070 impl ::fidl_next::Unconstrained for NamespaceInputEntry<'static> {}
4071
4072 #[derive(Debug)]
4074 #[repr(C)]
4075 pub struct NamespaceCreateRequest<'de> {
4076 pub entries: ::fidl_next::WireVector<'de, crate::wire::NamespaceInputEntry<'de>>,
4077 }
4078
4079 static_assertions::const_assert_eq!(std::mem::size_of::<NamespaceCreateRequest<'_>>(), 16);
4080 static_assertions::const_assert_eq!(std::mem::align_of::<NamespaceCreateRequest<'_>>(), 8);
4081
4082 static_assertions::const_assert_eq!(
4083 std::mem::offset_of!(NamespaceCreateRequest<'_>, entries),
4084 0
4085 );
4086
4087 unsafe impl ::fidl_next::Wire for NamespaceCreateRequest<'static> {
4088 type Owned<'de> = NamespaceCreateRequest<'de>;
4089
4090 #[inline]
4091 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4092 ::fidl_next::munge! {
4093 let Self {
4094
4095 entries,
4096
4097 } = &mut *out_;
4098 }
4099
4100 ::fidl_next::Wire::zero_padding(entries);
4101 }
4102 }
4103
4104 unsafe impl<___D> ::fidl_next::Decode<___D> for NamespaceCreateRequest<'static>
4105 where
4106 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4107 ___D: ::fidl_next::Decoder,
4108 ___D: ::fidl_next::fuchsia::HandleDecoder,
4109 {
4110 fn decode(
4111 slot_: ::fidl_next::Slot<'_, Self>,
4112 decoder_: &mut ___D,
4113 _: (),
4114 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4115 ::fidl_next::munge! {
4116 let Self {
4117
4118 mut entries,
4119
4120 } = slot_;
4121 }
4122
4123 let _field = entries.as_mut();
4124 ::fidl_next::Constrained::validate(_field, (4294967295, ()))?;
4125 ::fidl_next::Decode::decode(entries.as_mut(), decoder_, (4294967295, ()))?;
4126
4127 Ok(())
4128 }
4129 }
4130
4131 impl<'de> ::fidl_next::IntoNatural for NamespaceCreateRequest<'de> {
4132 type Natural = crate::natural::NamespaceCreateRequest;
4133 }
4134
4135 impl ::fidl_next::Unconstrained for NamespaceCreateRequest<'static> {}
4136
4137 #[derive(Debug)]
4139 #[repr(C)]
4140 pub struct NamespaceCreateResponse<'de> {
4141 pub entries: ::fidl_next::WireVector<'de, crate::wire::NamespaceEntry<'de>>,
4142 }
4143
4144 static_assertions::const_assert_eq!(std::mem::size_of::<NamespaceCreateResponse<'_>>(), 16);
4145 static_assertions::const_assert_eq!(std::mem::align_of::<NamespaceCreateResponse<'_>>(), 8);
4146
4147 static_assertions::const_assert_eq!(
4148 std::mem::offset_of!(NamespaceCreateResponse<'_>, entries),
4149 0
4150 );
4151
4152 unsafe impl ::fidl_next::Wire for NamespaceCreateResponse<'static> {
4153 type Owned<'de> = NamespaceCreateResponse<'de>;
4154
4155 #[inline]
4156 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4157 ::fidl_next::munge! {
4158 let Self {
4159
4160 entries,
4161
4162 } = &mut *out_;
4163 }
4164
4165 ::fidl_next::Wire::zero_padding(entries);
4166 }
4167 }
4168
4169 unsafe impl<___D> ::fidl_next::Decode<___D> for NamespaceCreateResponse<'static>
4170 where
4171 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4172 ___D: ::fidl_next::Decoder,
4173 ___D: ::fidl_next::fuchsia::HandleDecoder,
4174 {
4175 fn decode(
4176 slot_: ::fidl_next::Slot<'_, Self>,
4177 decoder_: &mut ___D,
4178 _: (),
4179 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4180 ::fidl_next::munge! {
4181 let Self {
4182
4183 mut entries,
4184
4185 } = slot_;
4186 }
4187
4188 let _field = entries.as_mut();
4189 ::fidl_next::Constrained::validate(_field, (4294967295, ()))?;
4190 ::fidl_next::Decode::decode(entries.as_mut(), decoder_, (4294967295, ()))?;
4191
4192 Ok(())
4193 }
4194 }
4195
4196 impl<'de> ::fidl_next::IntoNatural for NamespaceCreateResponse<'de> {
4197 type Natural = crate::natural::NamespaceCreateResponse;
4198 }
4199
4200 impl ::fidl_next::Unconstrained for NamespaceCreateResponse<'static> {}
4201
4202 #[derive(Debug)]
4204 #[repr(C)]
4205 pub struct RealmListChildrenRequest<'de> {
4206 pub collection: ::fidl_next_fuchsia_component_decl::wire::CollectionRef<'de>,
4207
4208 pub iter: ::fidl_next::ServerEnd<crate::ChildIterator, ::fidl_next::fuchsia::WireChannel>,
4209 }
4210
4211 static_assertions::const_assert_eq!(std::mem::size_of::<RealmListChildrenRequest<'_>>(), 24);
4212 static_assertions::const_assert_eq!(std::mem::align_of::<RealmListChildrenRequest<'_>>(), 8);
4213
4214 static_assertions::const_assert_eq!(
4215 std::mem::offset_of!(RealmListChildrenRequest<'_>, collection),
4216 0
4217 );
4218
4219 static_assertions::const_assert_eq!(
4220 std::mem::offset_of!(RealmListChildrenRequest<'_>, iter),
4221 16
4222 );
4223
4224 unsafe impl ::fidl_next::Wire for RealmListChildrenRequest<'static> {
4225 type Owned<'de> = RealmListChildrenRequest<'de>;
4226
4227 #[inline]
4228 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4229 ::fidl_next::munge! {
4230 let Self {
4231
4232 collection,
4233 iter,
4234
4235 } = &mut *out_;
4236 }
4237
4238 ::fidl_next::Wire::zero_padding(collection);
4239
4240 ::fidl_next::Wire::zero_padding(iter);
4241
4242 unsafe {
4243 out_.as_mut_ptr().cast::<u8>().add(20).write_bytes(0, 4);
4244 }
4245 }
4246 }
4247
4248 unsafe impl<___D> ::fidl_next::Decode<___D> for RealmListChildrenRequest<'static>
4249 where
4250 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4251 ___D: ::fidl_next::Decoder,
4252 ___D: ::fidl_next::fuchsia::HandleDecoder,
4253 {
4254 fn decode(
4255 slot_: ::fidl_next::Slot<'_, Self>,
4256 decoder_: &mut ___D,
4257 _: (),
4258 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4259 if slot_.as_bytes()[20..24] != [0u8; 4] {
4260 return Err(::fidl_next::DecodeError::InvalidPadding);
4261 }
4262
4263 ::fidl_next::munge! {
4264 let Self {
4265
4266 mut collection,
4267 mut iter,
4268
4269 } = slot_;
4270 }
4271
4272 let _field = collection.as_mut();
4273
4274 ::fidl_next::Decode::decode(collection.as_mut(), decoder_, ())?;
4275
4276 let _field = iter.as_mut();
4277
4278 ::fidl_next::Decode::decode(iter.as_mut(), decoder_, ())?;
4279
4280 Ok(())
4281 }
4282 }
4283
4284 impl<'de> ::fidl_next::IntoNatural for RealmListChildrenRequest<'de> {
4285 type Natural = crate::natural::RealmListChildrenRequest;
4286 }
4287
4288 impl ::fidl_next::Unconstrained for RealmListChildrenRequest<'static> {}
4289
4290 #[derive(Debug)]
4292 #[repr(C)]
4293 pub struct RealmGetChildOutputDictionaryRequest<'de> {
4294 pub child: ::fidl_next_fuchsia_component_decl::wire::ChildRef<'de>,
4295 }
4296
4297 static_assertions::const_assert_eq!(
4298 std::mem::size_of::<RealmGetChildOutputDictionaryRequest<'_>>(),
4299 32
4300 );
4301 static_assertions::const_assert_eq!(
4302 std::mem::align_of::<RealmGetChildOutputDictionaryRequest<'_>>(),
4303 8
4304 );
4305
4306 static_assertions::const_assert_eq!(
4307 std::mem::offset_of!(RealmGetChildOutputDictionaryRequest<'_>, child),
4308 0
4309 );
4310
4311 unsafe impl ::fidl_next::Wire for RealmGetChildOutputDictionaryRequest<'static> {
4312 type Owned<'de> = RealmGetChildOutputDictionaryRequest<'de>;
4313
4314 #[inline]
4315 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4316 ::fidl_next::munge! {
4317 let Self {
4318
4319 child,
4320
4321 } = &mut *out_;
4322 }
4323
4324 ::fidl_next::Wire::zero_padding(child);
4325 }
4326 }
4327
4328 unsafe impl<___D> ::fidl_next::Decode<___D> for RealmGetChildOutputDictionaryRequest<'static>
4329 where
4330 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4331 ___D: ::fidl_next::Decoder,
4332 ___D: ::fidl_next::fuchsia::HandleDecoder,
4333 {
4334 fn decode(
4335 slot_: ::fidl_next::Slot<'_, Self>,
4336 decoder_: &mut ___D,
4337 _: (),
4338 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4339 ::fidl_next::munge! {
4340 let Self {
4341
4342 mut child,
4343
4344 } = slot_;
4345 }
4346
4347 let _field = child.as_mut();
4348
4349 ::fidl_next::Decode::decode(child.as_mut(), decoder_, ())?;
4350
4351 Ok(())
4352 }
4353 }
4354
4355 impl<'de> ::fidl_next::IntoNatural for RealmGetChildOutputDictionaryRequest<'de> {
4356 type Natural = crate::natural::RealmGetChildOutputDictionaryRequest;
4357 }
4358
4359 impl ::fidl_next::Unconstrained for RealmGetChildOutputDictionaryRequest<'static> {}
4360
4361 #[derive(Debug)]
4363 #[repr(C)]
4364 pub struct RealmGetChildOutputDictionaryResponse {
4365 pub dictionary: ::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef,
4366 }
4367
4368 static_assertions::const_assert_eq!(
4369 std::mem::size_of::<RealmGetChildOutputDictionaryResponse>(),
4370 4
4371 );
4372 static_assertions::const_assert_eq!(
4373 std::mem::align_of::<RealmGetChildOutputDictionaryResponse>(),
4374 4
4375 );
4376
4377 static_assertions::const_assert_eq!(
4378 std::mem::offset_of!(RealmGetChildOutputDictionaryResponse, dictionary),
4379 0
4380 );
4381
4382 unsafe impl ::fidl_next::Wire for RealmGetChildOutputDictionaryResponse {
4383 type Owned<'de> = RealmGetChildOutputDictionaryResponse;
4384
4385 #[inline]
4386 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4387 ::fidl_next::munge! {
4388 let Self {
4389
4390 dictionary,
4391
4392 } = &mut *out_;
4393 }
4394
4395 ::fidl_next::Wire::zero_padding(dictionary);
4396 }
4397 }
4398
4399 unsafe impl<___D> ::fidl_next::Decode<___D> for RealmGetChildOutputDictionaryResponse
4400 where
4401 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4402 ___D: ::fidl_next::fuchsia::HandleDecoder,
4403 {
4404 fn decode(
4405 slot_: ::fidl_next::Slot<'_, Self>,
4406 decoder_: &mut ___D,
4407 _: (),
4408 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4409 ::fidl_next::munge! {
4410 let Self {
4411
4412 mut dictionary,
4413
4414 } = slot_;
4415 }
4416
4417 let _field = dictionary.as_mut();
4418
4419 ::fidl_next::Decode::decode(dictionary.as_mut(), decoder_, ())?;
4420
4421 Ok(())
4422 }
4423 }
4424
4425 impl ::fidl_next::IntoNatural for RealmGetChildOutputDictionaryResponse {
4426 type Natural = crate::natural::RealmGetChildOutputDictionaryResponse;
4427 }
4428
4429 impl ::fidl_next::Unconstrained for RealmGetChildOutputDictionaryResponse {}
4430
4431 #[derive(Debug)]
4433 #[repr(C)]
4434 pub struct RealmOpenControllerRequest<'de> {
4435 pub child: ::fidl_next_fuchsia_component_decl::wire::ChildRef<'de>,
4436
4437 pub controller:
4438 ::fidl_next::ServerEnd<crate::Controller, ::fidl_next::fuchsia::WireChannel>,
4439 }
4440
4441 static_assertions::const_assert_eq!(std::mem::size_of::<RealmOpenControllerRequest<'_>>(), 40);
4442 static_assertions::const_assert_eq!(std::mem::align_of::<RealmOpenControllerRequest<'_>>(), 8);
4443
4444 static_assertions::const_assert_eq!(
4445 std::mem::offset_of!(RealmOpenControllerRequest<'_>, child),
4446 0
4447 );
4448
4449 static_assertions::const_assert_eq!(
4450 std::mem::offset_of!(RealmOpenControllerRequest<'_>, controller),
4451 32
4452 );
4453
4454 unsafe impl ::fidl_next::Wire for RealmOpenControllerRequest<'static> {
4455 type Owned<'de> = RealmOpenControllerRequest<'de>;
4456
4457 #[inline]
4458 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4459 ::fidl_next::munge! {
4460 let Self {
4461
4462 child,
4463 controller,
4464
4465 } = &mut *out_;
4466 }
4467
4468 ::fidl_next::Wire::zero_padding(child);
4469
4470 ::fidl_next::Wire::zero_padding(controller);
4471
4472 unsafe {
4473 out_.as_mut_ptr().cast::<u8>().add(36).write_bytes(0, 4);
4474 }
4475 }
4476 }
4477
4478 unsafe impl<___D> ::fidl_next::Decode<___D> for RealmOpenControllerRequest<'static>
4479 where
4480 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4481 ___D: ::fidl_next::Decoder,
4482 ___D: ::fidl_next::fuchsia::HandleDecoder,
4483 {
4484 fn decode(
4485 slot_: ::fidl_next::Slot<'_, Self>,
4486 decoder_: &mut ___D,
4487 _: (),
4488 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4489 if slot_.as_bytes()[36..40] != [0u8; 4] {
4490 return Err(::fidl_next::DecodeError::InvalidPadding);
4491 }
4492
4493 ::fidl_next::munge! {
4494 let Self {
4495
4496 mut child,
4497 mut controller,
4498
4499 } = slot_;
4500 }
4501
4502 let _field = child.as_mut();
4503
4504 ::fidl_next::Decode::decode(child.as_mut(), decoder_, ())?;
4505
4506 let _field = controller.as_mut();
4507
4508 ::fidl_next::Decode::decode(controller.as_mut(), decoder_, ())?;
4509
4510 Ok(())
4511 }
4512 }
4513
4514 impl<'de> ::fidl_next::IntoNatural for RealmOpenControllerRequest<'de> {
4515 type Natural = crate::natural::RealmOpenControllerRequest;
4516 }
4517
4518 impl ::fidl_next::Unconstrained for RealmOpenControllerRequest<'static> {}
4519
4520 #[derive(Debug)]
4522 #[repr(C)]
4523 pub struct RealmOpenExposedDirRequest<'de> {
4524 pub child: ::fidl_next_fuchsia_component_decl::wire::ChildRef<'de>,
4525
4526 pub exposed_dir: ::fidl_next::ServerEnd<
4527 ::fidl_next_fuchsia_io::Directory,
4528 ::fidl_next::fuchsia::WireChannel,
4529 >,
4530 }
4531
4532 static_assertions::const_assert_eq!(std::mem::size_of::<RealmOpenExposedDirRequest<'_>>(), 40);
4533 static_assertions::const_assert_eq!(std::mem::align_of::<RealmOpenExposedDirRequest<'_>>(), 8);
4534
4535 static_assertions::const_assert_eq!(
4536 std::mem::offset_of!(RealmOpenExposedDirRequest<'_>, child),
4537 0
4538 );
4539
4540 static_assertions::const_assert_eq!(
4541 std::mem::offset_of!(RealmOpenExposedDirRequest<'_>, exposed_dir),
4542 32
4543 );
4544
4545 unsafe impl ::fidl_next::Wire for RealmOpenExposedDirRequest<'static> {
4546 type Owned<'de> = RealmOpenExposedDirRequest<'de>;
4547
4548 #[inline]
4549 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4550 ::fidl_next::munge! {
4551 let Self {
4552
4553 child,
4554 exposed_dir,
4555
4556 } = &mut *out_;
4557 }
4558
4559 ::fidl_next::Wire::zero_padding(child);
4560
4561 ::fidl_next::Wire::zero_padding(exposed_dir);
4562
4563 unsafe {
4564 out_.as_mut_ptr().cast::<u8>().add(36).write_bytes(0, 4);
4565 }
4566 }
4567 }
4568
4569 unsafe impl<___D> ::fidl_next::Decode<___D> for RealmOpenExposedDirRequest<'static>
4570 where
4571 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4572 ___D: ::fidl_next::Decoder,
4573 ___D: ::fidl_next::fuchsia::HandleDecoder,
4574 {
4575 fn decode(
4576 slot_: ::fidl_next::Slot<'_, Self>,
4577 decoder_: &mut ___D,
4578 _: (),
4579 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4580 if slot_.as_bytes()[36..40] != [0u8; 4] {
4581 return Err(::fidl_next::DecodeError::InvalidPadding);
4582 }
4583
4584 ::fidl_next::munge! {
4585 let Self {
4586
4587 mut child,
4588 mut exposed_dir,
4589
4590 } = slot_;
4591 }
4592
4593 let _field = child.as_mut();
4594
4595 ::fidl_next::Decode::decode(child.as_mut(), decoder_, ())?;
4596
4597 let _field = exposed_dir.as_mut();
4598
4599 ::fidl_next::Decode::decode(exposed_dir.as_mut(), decoder_, ())?;
4600
4601 Ok(())
4602 }
4603 }
4604
4605 impl<'de> ::fidl_next::IntoNatural for RealmOpenExposedDirRequest<'de> {
4606 type Natural = crate::natural::RealmOpenExposedDirRequest;
4607 }
4608
4609 impl ::fidl_next::Unconstrained for RealmOpenExposedDirRequest<'static> {}
4610
4611 #[derive(Debug)]
4613 #[repr(C)]
4614 pub struct RealmCreateChildRequest<'de> {
4615 pub collection: ::fidl_next_fuchsia_component_decl::wire::CollectionRef<'de>,
4616
4617 pub decl: ::fidl_next_fuchsia_component_decl::wire::Child<'de>,
4618
4619 pub args: crate::wire::CreateChildArgs<'de>,
4620 }
4621
4622 static_assertions::const_assert_eq!(std::mem::size_of::<RealmCreateChildRequest<'_>>(), 48);
4623 static_assertions::const_assert_eq!(std::mem::align_of::<RealmCreateChildRequest<'_>>(), 8);
4624
4625 static_assertions::const_assert_eq!(
4626 std::mem::offset_of!(RealmCreateChildRequest<'_>, collection),
4627 0
4628 );
4629
4630 static_assertions::const_assert_eq!(
4631 std::mem::offset_of!(RealmCreateChildRequest<'_>, decl),
4632 16
4633 );
4634
4635 static_assertions::const_assert_eq!(
4636 std::mem::offset_of!(RealmCreateChildRequest<'_>, args),
4637 32
4638 );
4639
4640 unsafe impl ::fidl_next::Wire for RealmCreateChildRequest<'static> {
4641 type Owned<'de> = RealmCreateChildRequest<'de>;
4642
4643 #[inline]
4644 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4645 ::fidl_next::munge! {
4646 let Self {
4647
4648 collection,
4649 decl,
4650 args,
4651
4652 } = &mut *out_;
4653 }
4654
4655 ::fidl_next::Wire::zero_padding(collection);
4656
4657 ::fidl_next::Wire::zero_padding(decl);
4658
4659 ::fidl_next::Wire::zero_padding(args);
4660 }
4661 }
4662
4663 unsafe impl<___D> ::fidl_next::Decode<___D> for RealmCreateChildRequest<'static>
4664 where
4665 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4666 ___D: ::fidl_next::Decoder,
4667 ___D: ::fidl_next::fuchsia::HandleDecoder,
4668 {
4669 fn decode(
4670 slot_: ::fidl_next::Slot<'_, Self>,
4671 decoder_: &mut ___D,
4672 _: (),
4673 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4674 ::fidl_next::munge! {
4675 let Self {
4676
4677 mut collection,
4678 mut decl,
4679 mut args,
4680
4681 } = slot_;
4682 }
4683
4684 let _field = collection.as_mut();
4685
4686 ::fidl_next::Decode::decode(collection.as_mut(), decoder_, ())?;
4687
4688 let _field = decl.as_mut();
4689
4690 ::fidl_next::Decode::decode(decl.as_mut(), decoder_, ())?;
4691
4692 let _field = args.as_mut();
4693
4694 ::fidl_next::Decode::decode(args.as_mut(), decoder_, ())?;
4695
4696 Ok(())
4697 }
4698 }
4699
4700 impl<'de> ::fidl_next::IntoNatural for RealmCreateChildRequest<'de> {
4701 type Natural = crate::natural::RealmCreateChildRequest;
4702 }
4703
4704 impl ::fidl_next::Unconstrained for RealmCreateChildRequest<'static> {}
4705
4706 #[derive(Debug)]
4708 #[repr(C)]
4709 pub struct RealmGetResolvedInfoResponse<'de> {
4710 pub resolved_info: ::fidl_next_fuchsia_component_resolution::wire::Component<'de>,
4711 }
4712
4713 static_assertions::const_assert_eq!(
4714 std::mem::size_of::<RealmGetResolvedInfoResponse<'_>>(),
4715 16
4716 );
4717 static_assertions::const_assert_eq!(
4718 std::mem::align_of::<RealmGetResolvedInfoResponse<'_>>(),
4719 8
4720 );
4721
4722 static_assertions::const_assert_eq!(
4723 std::mem::offset_of!(RealmGetResolvedInfoResponse<'_>, resolved_info),
4724 0
4725 );
4726
4727 unsafe impl ::fidl_next::Wire for RealmGetResolvedInfoResponse<'static> {
4728 type Owned<'de> = RealmGetResolvedInfoResponse<'de>;
4729
4730 #[inline]
4731 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4732 ::fidl_next::munge! {
4733 let Self {
4734
4735 resolved_info,
4736
4737 } = &mut *out_;
4738 }
4739
4740 ::fidl_next::Wire::zero_padding(resolved_info);
4741 }
4742 }
4743
4744 unsafe impl<___D> ::fidl_next::Decode<___D> for RealmGetResolvedInfoResponse<'static>
4745 where
4746 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4747 ___D: ::fidl_next::Decoder,
4748 ___D: ::fidl_next::fuchsia::HandleDecoder,
4749 {
4750 fn decode(
4751 slot_: ::fidl_next::Slot<'_, Self>,
4752 decoder_: &mut ___D,
4753 _: (),
4754 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4755 ::fidl_next::munge! {
4756 let Self {
4757
4758 mut resolved_info,
4759
4760 } = slot_;
4761 }
4762
4763 let _field = resolved_info.as_mut();
4764
4765 ::fidl_next::Decode::decode(resolved_info.as_mut(), decoder_, ())?;
4766
4767 Ok(())
4768 }
4769 }
4770
4771 impl<'de> ::fidl_next::IntoNatural for RealmGetResolvedInfoResponse<'de> {
4772 type Natural = crate::natural::RealmGetResolvedInfoResponse;
4773 }
4774
4775 impl ::fidl_next::Unconstrained for RealmGetResolvedInfoResponse<'static> {}
4776
4777 #[derive(Debug)]
4779 #[repr(C)]
4780 pub struct StorageAdminListStorageInRealmRequest<'de> {
4781 pub relative_moniker: ::fidl_next::WireString<'de>,
4782
4783 pub iterator:
4784 ::fidl_next::ServerEnd<crate::StorageIterator, ::fidl_next::fuchsia::WireChannel>,
4785 }
4786
4787 static_assertions::const_assert_eq!(
4788 std::mem::size_of::<StorageAdminListStorageInRealmRequest<'_>>(),
4789 24
4790 );
4791 static_assertions::const_assert_eq!(
4792 std::mem::align_of::<StorageAdminListStorageInRealmRequest<'_>>(),
4793 8
4794 );
4795
4796 static_assertions::const_assert_eq!(
4797 std::mem::offset_of!(StorageAdminListStorageInRealmRequest<'_>, relative_moniker),
4798 0
4799 );
4800
4801 static_assertions::const_assert_eq!(
4802 std::mem::offset_of!(StorageAdminListStorageInRealmRequest<'_>, iterator),
4803 16
4804 );
4805
4806 unsafe impl ::fidl_next::Wire for StorageAdminListStorageInRealmRequest<'static> {
4807 type Owned<'de> = StorageAdminListStorageInRealmRequest<'de>;
4808
4809 #[inline]
4810 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4811 ::fidl_next::munge! {
4812 let Self {
4813
4814 relative_moniker,
4815 iterator,
4816
4817 } = &mut *out_;
4818 }
4819
4820 ::fidl_next::Wire::zero_padding(relative_moniker);
4821
4822 ::fidl_next::Wire::zero_padding(iterator);
4823
4824 unsafe {
4825 out_.as_mut_ptr().cast::<u8>().add(20).write_bytes(0, 4);
4826 }
4827 }
4828 }
4829
4830 unsafe impl<___D> ::fidl_next::Decode<___D> for StorageAdminListStorageInRealmRequest<'static>
4831 where
4832 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4833 ___D: ::fidl_next::Decoder,
4834 ___D: ::fidl_next::fuchsia::HandleDecoder,
4835 {
4836 fn decode(
4837 slot_: ::fidl_next::Slot<'_, Self>,
4838 decoder_: &mut ___D,
4839 _: (),
4840 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4841 if slot_.as_bytes()[20..24] != [0u8; 4] {
4842 return Err(::fidl_next::DecodeError::InvalidPadding);
4843 }
4844
4845 ::fidl_next::munge! {
4846 let Self {
4847
4848 mut relative_moniker,
4849 mut iterator,
4850
4851 } = slot_;
4852 }
4853
4854 let _field = relative_moniker.as_mut();
4855 ::fidl_next::Constrained::validate(_field, 4096)?;
4856 ::fidl_next::Decode::decode(relative_moniker.as_mut(), decoder_, 4096)?;
4857
4858 let relative_moniker = unsafe { relative_moniker.deref_unchecked() };
4859
4860 if relative_moniker.len() > 4096 {
4861 return Err(::fidl_next::DecodeError::VectorTooLong {
4862 size: relative_moniker.len() as u64,
4863 limit: 4096,
4864 });
4865 }
4866
4867 let _field = iterator.as_mut();
4868
4869 ::fidl_next::Decode::decode(iterator.as_mut(), decoder_, ())?;
4870
4871 Ok(())
4872 }
4873 }
4874
4875 impl<'de> ::fidl_next::IntoNatural for StorageAdminListStorageInRealmRequest<'de> {
4876 type Natural = crate::natural::StorageAdminListStorageInRealmRequest;
4877 }
4878
4879 impl ::fidl_next::Unconstrained for StorageAdminListStorageInRealmRequest<'static> {}
4880
4881 #[derive(Debug)]
4883 #[repr(C)]
4884 pub struct StorageAdminOpenStorageRequest<'de> {
4885 pub relative_moniker: ::fidl_next::WireString<'de>,
4886
4887 pub object:
4888 ::fidl_next::ServerEnd<::fidl_next_fuchsia_io::Node, ::fidl_next::fuchsia::WireChannel>,
4889 }
4890
4891 static_assertions::const_assert_eq!(
4892 std::mem::size_of::<StorageAdminOpenStorageRequest<'_>>(),
4893 24
4894 );
4895 static_assertions::const_assert_eq!(
4896 std::mem::align_of::<StorageAdminOpenStorageRequest<'_>>(),
4897 8
4898 );
4899
4900 static_assertions::const_assert_eq!(
4901 std::mem::offset_of!(StorageAdminOpenStorageRequest<'_>, relative_moniker),
4902 0
4903 );
4904
4905 static_assertions::const_assert_eq!(
4906 std::mem::offset_of!(StorageAdminOpenStorageRequest<'_>, object),
4907 16
4908 );
4909
4910 unsafe impl ::fidl_next::Wire for StorageAdminOpenStorageRequest<'static> {
4911 type Owned<'de> = StorageAdminOpenStorageRequest<'de>;
4912
4913 #[inline]
4914 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
4915 ::fidl_next::munge! {
4916 let Self {
4917
4918 relative_moniker,
4919 object,
4920
4921 } = &mut *out_;
4922 }
4923
4924 ::fidl_next::Wire::zero_padding(relative_moniker);
4925
4926 ::fidl_next::Wire::zero_padding(object);
4927
4928 unsafe {
4929 out_.as_mut_ptr().cast::<u8>().add(20).write_bytes(0, 4);
4930 }
4931 }
4932 }
4933
4934 unsafe impl<___D> ::fidl_next::Decode<___D> for StorageAdminOpenStorageRequest<'static>
4935 where
4936 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
4937 ___D: ::fidl_next::Decoder,
4938 ___D: ::fidl_next::fuchsia::HandleDecoder,
4939 {
4940 fn decode(
4941 slot_: ::fidl_next::Slot<'_, Self>,
4942 decoder_: &mut ___D,
4943 _: (),
4944 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
4945 if slot_.as_bytes()[20..24] != [0u8; 4] {
4946 return Err(::fidl_next::DecodeError::InvalidPadding);
4947 }
4948
4949 ::fidl_next::munge! {
4950 let Self {
4951
4952 mut relative_moniker,
4953 mut object,
4954
4955 } = slot_;
4956 }
4957
4958 let _field = relative_moniker.as_mut();
4959 ::fidl_next::Constrained::validate(_field, 4096)?;
4960 ::fidl_next::Decode::decode(relative_moniker.as_mut(), decoder_, 4096)?;
4961
4962 let relative_moniker = unsafe { relative_moniker.deref_unchecked() };
4963
4964 if relative_moniker.len() > 4096 {
4965 return Err(::fidl_next::DecodeError::VectorTooLong {
4966 size: relative_moniker.len() as u64,
4967 limit: 4096,
4968 });
4969 }
4970
4971 let _field = object.as_mut();
4972
4973 ::fidl_next::Decode::decode(object.as_mut(), decoder_, ())?;
4974
4975 Ok(())
4976 }
4977 }
4978
4979 impl<'de> ::fidl_next::IntoNatural for StorageAdminOpenStorageRequest<'de> {
4980 type Natural = crate::natural::StorageAdminOpenStorageRequest;
4981 }
4982
4983 impl ::fidl_next::Unconstrained for StorageAdminOpenStorageRequest<'static> {}
4984
4985 #[derive(Debug)]
4987 #[repr(C)]
4988 pub struct StorageAdminOpenComponentStorageByIdRequest<'de> {
4989 pub id: ::fidl_next::WireString<'de>,
4990
4991 pub object:
4992 ::fidl_next::ServerEnd<::fidl_next_fuchsia_io::Node, ::fidl_next::fuchsia::WireChannel>,
4993 }
4994
4995 static_assertions::const_assert_eq!(
4996 std::mem::size_of::<StorageAdminOpenComponentStorageByIdRequest<'_>>(),
4997 24
4998 );
4999 static_assertions::const_assert_eq!(
5000 std::mem::align_of::<StorageAdminOpenComponentStorageByIdRequest<'_>>(),
5001 8
5002 );
5003
5004 static_assertions::const_assert_eq!(
5005 std::mem::offset_of!(StorageAdminOpenComponentStorageByIdRequest<'_>, id),
5006 0
5007 );
5008
5009 static_assertions::const_assert_eq!(
5010 std::mem::offset_of!(StorageAdminOpenComponentStorageByIdRequest<'_>, object),
5011 16
5012 );
5013
5014 unsafe impl ::fidl_next::Wire for StorageAdminOpenComponentStorageByIdRequest<'static> {
5015 type Owned<'de> = StorageAdminOpenComponentStorageByIdRequest<'de>;
5016
5017 #[inline]
5018 fn zero_padding(out_: &mut ::core::mem::MaybeUninit<Self>) {
5019 ::fidl_next::munge! {
5020 let Self {
5021
5022 id,
5023 object,
5024
5025 } = &mut *out_;
5026 }
5027
5028 ::fidl_next::Wire::zero_padding(id);
5029
5030 ::fidl_next::Wire::zero_padding(object);
5031
5032 unsafe {
5033 out_.as_mut_ptr().cast::<u8>().add(20).write_bytes(0, 4);
5034 }
5035 }
5036 }
5037
5038 unsafe impl<___D> ::fidl_next::Decode<___D> for StorageAdminOpenComponentStorageByIdRequest<'static>
5039 where
5040 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
5041 ___D: ::fidl_next::Decoder,
5042 ___D: ::fidl_next::fuchsia::HandleDecoder,
5043 {
5044 fn decode(
5045 slot_: ::fidl_next::Slot<'_, Self>,
5046 decoder_: &mut ___D,
5047 _: (),
5048 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
5049 if slot_.as_bytes()[20..24] != [0u8; 4] {
5050 return Err(::fidl_next::DecodeError::InvalidPadding);
5051 }
5052
5053 ::fidl_next::munge! {
5054 let Self {
5055
5056 mut id,
5057 mut object,
5058
5059 } = slot_;
5060 }
5061
5062 let _field = id.as_mut();
5063 ::fidl_next::Constrained::validate(_field, 64)?;
5064 ::fidl_next::Decode::decode(id.as_mut(), decoder_, 64)?;
5065
5066 let id = unsafe { id.deref_unchecked() };
5067
5068 if id.len() > 64 {
5069 return Err(::fidl_next::DecodeError::VectorTooLong {
5070 size: id.len() as u64,
5071 limit: 64,
5072 });
5073 }
5074
5075 let _field = object.as_mut();
5076
5077 ::fidl_next::Decode::decode(object.as_mut(), decoder_, ())?;
5078
5079 Ok(())
5080 }
5081 }
5082
5083 impl<'de> ::fidl_next::IntoNatural for StorageAdminOpenComponentStorageByIdRequest<'de> {
5084 type Natural = crate::natural::StorageAdminOpenComponentStorageByIdRequest;
5085 }
5086
5087 impl ::fidl_next::Unconstrained for StorageAdminOpenComponentStorageByIdRequest<'static> {}
5088}
5089
5090pub mod wire_optional {
5091
5092 pub use fidl_next_common_fuchsia_component::wire_optional::*;
5093
5094 #[repr(transparent)]
5095 pub struct EventPayload<'de> {
5096 pub(crate) raw: ::fidl_next::RawWireUnion,
5097 pub(crate) _phantom: ::core::marker::PhantomData<&'de mut [::fidl_next::Chunk]>,
5098 }
5099
5100 unsafe impl ::fidl_next::Wire for EventPayload<'static> {
5101 type Owned<'de> = EventPayload<'de>;
5102
5103 #[inline]
5104 fn zero_padding(out: &mut ::core::mem::MaybeUninit<Self>) {
5105 ::fidl_next::munge!(let Self { raw, _phantom: _ } = out);
5106 ::fidl_next::RawWireUnion::zero_padding(raw);
5107 }
5108 }
5109
5110 impl<'de> EventPayload<'de> {
5111 pub fn is_some(&self) -> bool {
5112 self.raw.is_some()
5113 }
5114
5115 pub fn is_none(&self) -> bool {
5116 self.raw.is_none()
5117 }
5118
5119 pub fn as_ref(&self) -> ::core::option::Option<&crate::wire::EventPayload<'de>> {
5120 if self.is_some() { Some(unsafe { &*(self as *const Self).cast() }) } else { None }
5121 }
5122
5123 pub fn into_option(self) -> ::core::option::Option<crate::wire::EventPayload<'de>> {
5124 if self.is_some() {
5125 Some(crate::wire::EventPayload {
5126 raw: self.raw,
5127 _phantom: ::core::marker::PhantomData,
5128 })
5129 } else {
5130 None
5131 }
5132 }
5133 }
5134
5135 unsafe impl<___D> ::fidl_next::Decode<___D> for EventPayload<'static>
5136 where
5137 ___D: ::fidl_next::decoder::InternalHandleDecoder + ?Sized,
5138 ___D: ::fidl_next::Decoder,
5139 ___D: ::fidl_next::fuchsia::HandleDecoder,
5140 {
5141 fn decode(
5142 mut slot: ::fidl_next::Slot<'_, Self>,
5143 decoder: &mut ___D,
5144 _: (),
5145 ) -> ::core::result::Result<(), ::fidl_next::DecodeError> {
5146 ::fidl_next::munge!(let Self { mut raw, _phantom: _ } = slot.as_mut());
5147 match ::fidl_next::RawWireUnion::encoded_ordinal(raw.as_mut()) {
5148 1 => ::fidl_next::RawWireUnion::decode_as::<
5149 ___D,
5150 crate::wire::CapabilityRequestedPayload<'static>,
5151 >(raw, decoder, ())?,
5152
5153 2 => ::fidl_next::RawWireUnion::decode_as::<
5154 ___D,
5155 crate::wire::PurgedPayload<'static>,
5156 >(raw, decoder, ())?,
5157
5158 4 => ::fidl_next::RawWireUnion::decode_as::<
5159 ___D,
5160 crate::wire::DiscoveredPayload<'static>,
5161 >(raw, decoder, ())?,
5162
5163 5 => ::fidl_next::RawWireUnion::decode_as::<
5164 ___D,
5165 crate::wire::DestroyedPayload<'static>,
5166 >(raw, decoder, ())?,
5167
5168 6 => ::fidl_next::RawWireUnion::decode_as::<
5169 ___D,
5170 crate::wire::ResolvedPayload<'static>,
5171 >(raw, decoder, ())?,
5172
5173 7 => ::fidl_next::RawWireUnion::decode_as::<
5174 ___D,
5175 crate::wire::StartedPayload<'static>,
5176 >(raw, decoder, ())?,
5177
5178 8 => ::fidl_next::RawWireUnion::decode_as::<
5179 ___D,
5180 crate::wire::StoppedPayload<'static>,
5181 >(raw, decoder, ())?,
5182
5183 9 => ::fidl_next::RawWireUnion::decode_as::<
5184 ___D,
5185 crate::wire::DebugStartedPayload<'static>,
5186 >(raw, decoder, ())?,
5187
5188 10 => ::fidl_next::RawWireUnion::decode_as::<
5189 ___D,
5190 crate::wire::UnresolvedPayload<'static>,
5191 >(raw, decoder, ())?,
5192
5193 0 => ::fidl_next::RawWireUnion::decode_absent(raw)?,
5194 _ => ::fidl_next::RawWireUnion::decode_unknown(raw, decoder)?,
5195 }
5196
5197 Ok(())
5198 }
5199 }
5200
5201 impl<'de> ::core::fmt::Debug for EventPayload<'de> {
5202 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
5203 self.as_ref().fmt(f)
5204 }
5205 }
5206
5207 impl<'de> ::fidl_next::IntoNatural for EventPayload<'de> {
5208 type Natural = ::core::option::Option<crate::natural::EventPayload>;
5209 }
5210
5211 impl ::fidl_next::Unconstrained for EventPayload<'static> {}
5212}
5213
5214pub mod generic {
5215
5216 pub use fidl_next_common_fuchsia_component::generic::*;
5217
5218 pub struct ControllerIsStartedResponse<T0> {
5219 pub is_started: T0,
5220 }
5221
5222 unsafe impl<___E, T0> ::fidl_next::Encode<crate::wire::ControllerIsStartedResponse, ___E>
5223 for ControllerIsStartedResponse<T0>
5224 where
5225 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5226 ___E: ::fidl_next::fuchsia::HandleEncoder,
5227 T0: ::fidl_next::Encode<bool, ___E>,
5228 {
5229 #[inline]
5230 fn encode(
5231 self,
5232 encoder_: &mut ___E,
5233 out_: &mut ::core::mem::MaybeUninit<crate::wire::ControllerIsStartedResponse>,
5234 _: (),
5235 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5236 ::fidl_next::munge! {
5237 let crate::wire::ControllerIsStartedResponse {
5238
5239 is_started,
5240
5241 } = out_;
5242 }
5243
5244 ::fidl_next::Encode::encode(self.is_started, encoder_, is_started, ())?;
5245
5246 Ok(())
5247 }
5248 }
5249
5250 pub struct ControllerGetExposedDictionaryResponse<T0> {
5251 pub dictionary: T0,
5252 }
5253
5254 unsafe impl<___E, T0>
5255 ::fidl_next::Encode<crate::wire::ControllerGetExposedDictionaryResponse, ___E>
5256 for ControllerGetExposedDictionaryResponse<T0>
5257 where
5258 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5259 ___E: ::fidl_next::fuchsia::HandleEncoder,
5260 T0: ::fidl_next::Encode<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef, ___E>,
5261 {
5262 #[inline]
5263 fn encode(
5264 self,
5265 encoder_: &mut ___E,
5266 out_: &mut ::core::mem::MaybeUninit<
5267 crate::wire::ControllerGetExposedDictionaryResponse,
5268 >,
5269 _: (),
5270 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5271 ::fidl_next::munge! {
5272 let crate::wire::ControllerGetExposedDictionaryResponse {
5273
5274 dictionary,
5275
5276 } = out_;
5277 }
5278
5279 ::fidl_next::Encode::encode(self.dictionary, encoder_, dictionary, ())?;
5280
5281 Ok(())
5282 }
5283 }
5284
5285 pub struct ControllerStartRequest<T0, T1> {
5286 pub args: T0,
5287
5288 pub execution_controller: T1,
5289 }
5290
5291 unsafe impl<___E, T0, T1>
5292 ::fidl_next::Encode<crate::wire::ControllerStartRequest<'static>, ___E>
5293 for ControllerStartRequest<T0, T1>
5294 where
5295 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5296 ___E: ::fidl_next::Encoder,
5297 ___E: ::fidl_next::fuchsia::HandleEncoder,
5298 T0: ::fidl_next::Encode<crate::wire::StartChildArgs<'static>, ___E>,
5299 T1: ::fidl_next::Encode<
5300 ::fidl_next::ServerEnd<
5301 crate::ExecutionController,
5302 ::fidl_next::fuchsia::WireChannel,
5303 >,
5304 ___E,
5305 >,
5306 {
5307 #[inline]
5308 fn encode(
5309 self,
5310 encoder_: &mut ___E,
5311 out_: &mut ::core::mem::MaybeUninit<crate::wire::ControllerStartRequest<'static>>,
5312 _: (),
5313 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5314 ::fidl_next::munge! {
5315 let crate::wire::ControllerStartRequest {
5316
5317 args,
5318 execution_controller,
5319
5320 } = out_;
5321 }
5322
5323 ::fidl_next::Encode::encode(self.args, encoder_, args, ())?;
5324
5325 ::fidl_next::Encode::encode(
5326 self.execution_controller,
5327 encoder_,
5328 execution_controller,
5329 (),
5330 )?;
5331
5332 Ok(())
5333 }
5334 }
5335
5336 pub struct EventStreamGetNextResponse<T0> {
5337 pub events: T0,
5338 }
5339
5340 unsafe impl<___E, T0>
5341 ::fidl_next::Encode<crate::wire::EventStreamGetNextResponse<'static>, ___E>
5342 for EventStreamGetNextResponse<T0>
5343 where
5344 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5345 ___E: ::fidl_next::Encoder,
5346 ___E: ::fidl_next::fuchsia::HandleEncoder,
5347 T0: ::fidl_next::Encode<::fidl_next::WireVector<'static, crate::wire::Event<'static>>, ___E>,
5348 {
5349 #[inline]
5350 fn encode(
5351 self,
5352 encoder_: &mut ___E,
5353 out_: &mut ::core::mem::MaybeUninit<crate::wire::EventStreamGetNextResponse<'static>>,
5354 _: (),
5355 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5356 ::fidl_next::munge! {
5357 let crate::wire::EventStreamGetNextResponse {
5358
5359 events,
5360
5361 } = out_;
5362 }
5363
5364 ::fidl_next::Encode::encode(self.events, encoder_, events, (4294967295, ()))?;
5365
5366 Ok(())
5367 }
5368 }
5369
5370 pub struct IntrospectorGetMonikerRequest<T0> {
5371 pub component_instance: T0,
5372 }
5373
5374 unsafe impl<___E, T0> ::fidl_next::Encode<crate::wire::IntrospectorGetMonikerRequest, ___E>
5375 for IntrospectorGetMonikerRequest<T0>
5376 where
5377 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5378 ___E: ::fidl_next::fuchsia::HandleEncoder,
5379 T0: ::fidl_next::Encode<::fidl_next::fuchsia::WireEvent, ___E>,
5380 {
5381 #[inline]
5382 fn encode(
5383 self,
5384 encoder_: &mut ___E,
5385 out_: &mut ::core::mem::MaybeUninit<crate::wire::IntrospectorGetMonikerRequest>,
5386 _: (),
5387 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5388 ::fidl_next::munge! {
5389 let crate::wire::IntrospectorGetMonikerRequest {
5390
5391 component_instance,
5392
5393 } = out_;
5394 }
5395
5396 ::fidl_next::Encode::encode(self.component_instance, encoder_, component_instance, ())?;
5397
5398 Ok(())
5399 }
5400 }
5401
5402 pub struct NamespaceInputEntry<T0, T1> {
5403 pub path: T0,
5404
5405 pub dictionary: T1,
5406 }
5407
5408 unsafe impl<___E, T0, T1> ::fidl_next::Encode<crate::wire::NamespaceInputEntry<'static>, ___E>
5409 for NamespaceInputEntry<T0, T1>
5410 where
5411 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5412 ___E: ::fidl_next::Encoder,
5413 ___E: ::fidl_next::fuchsia::HandleEncoder,
5414 T0: ::fidl_next::Encode<::fidl_next::WireString<'static>, ___E>,
5415 T1: ::fidl_next::Encode<
5416 ::fidl_next::ClientEnd<
5417 ::fidl_next_fuchsia_component_sandbox::Dictionary,
5418 ::fidl_next::fuchsia::WireChannel,
5419 >,
5420 ___E,
5421 >,
5422 {
5423 #[inline]
5424 fn encode(
5425 self,
5426 encoder_: &mut ___E,
5427 out_: &mut ::core::mem::MaybeUninit<crate::wire::NamespaceInputEntry<'static>>,
5428 _: (),
5429 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5430 ::fidl_next::munge! {
5431 let crate::wire::NamespaceInputEntry {
5432
5433 path,
5434 dictionary,
5435
5436 } = out_;
5437 }
5438
5439 ::fidl_next::Encode::encode(self.path, encoder_, path, 4095)?;
5440
5441 ::fidl_next::Encode::encode(self.dictionary, encoder_, dictionary, ())?;
5442
5443 Ok(())
5444 }
5445 }
5446
5447 pub struct NamespaceCreateRequest<T0> {
5448 pub entries: T0,
5449 }
5450
5451 unsafe impl<___E, T0> ::fidl_next::Encode<crate::wire::NamespaceCreateRequest<'static>, ___E>
5452 for NamespaceCreateRequest<T0>
5453 where
5454 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5455 ___E: ::fidl_next::Encoder,
5456 ___E: ::fidl_next::fuchsia::HandleEncoder,
5457 T0: ::fidl_next::Encode<
5458 ::fidl_next::WireVector<'static, crate::wire::NamespaceInputEntry<'static>>,
5459 ___E,
5460 >,
5461 {
5462 #[inline]
5463 fn encode(
5464 self,
5465 encoder_: &mut ___E,
5466 out_: &mut ::core::mem::MaybeUninit<crate::wire::NamespaceCreateRequest<'static>>,
5467 _: (),
5468 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5469 ::fidl_next::munge! {
5470 let crate::wire::NamespaceCreateRequest {
5471
5472 entries,
5473
5474 } = out_;
5475 }
5476
5477 ::fidl_next::Encode::encode(self.entries, encoder_, entries, (4294967295, ()))?;
5478
5479 Ok(())
5480 }
5481 }
5482
5483 pub struct NamespaceCreateResponse<T0> {
5484 pub entries: T0,
5485 }
5486
5487 unsafe impl<___E, T0> ::fidl_next::Encode<crate::wire::NamespaceCreateResponse<'static>, ___E>
5488 for NamespaceCreateResponse<T0>
5489 where
5490 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5491 ___E: ::fidl_next::Encoder,
5492 ___E: ::fidl_next::fuchsia::HandleEncoder,
5493 T0: ::fidl_next::Encode<
5494 ::fidl_next::WireVector<'static, crate::wire::NamespaceEntry<'static>>,
5495 ___E,
5496 >,
5497 {
5498 #[inline]
5499 fn encode(
5500 self,
5501 encoder_: &mut ___E,
5502 out_: &mut ::core::mem::MaybeUninit<crate::wire::NamespaceCreateResponse<'static>>,
5503 _: (),
5504 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5505 ::fidl_next::munge! {
5506 let crate::wire::NamespaceCreateResponse {
5507
5508 entries,
5509
5510 } = out_;
5511 }
5512
5513 ::fidl_next::Encode::encode(self.entries, encoder_, entries, (4294967295, ()))?;
5514
5515 Ok(())
5516 }
5517 }
5518
5519 pub struct RealmListChildrenRequest<T0, T1> {
5520 pub collection: T0,
5521
5522 pub iter: T1,
5523 }
5524
5525 unsafe impl<___E, T0, T1>
5526 ::fidl_next::Encode<crate::wire::RealmListChildrenRequest<'static>, ___E>
5527 for RealmListChildrenRequest<T0, T1>
5528 where
5529 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5530 ___E: ::fidl_next::Encoder,
5531 ___E: ::fidl_next::fuchsia::HandleEncoder,
5532 T0: ::fidl_next::Encode<
5533 ::fidl_next_fuchsia_component_decl::wire::CollectionRef<'static>,
5534 ___E,
5535 >,
5536 T1: ::fidl_next::Encode<
5537 ::fidl_next::ServerEnd<crate::ChildIterator, ::fidl_next::fuchsia::WireChannel>,
5538 ___E,
5539 >,
5540 {
5541 #[inline]
5542 fn encode(
5543 self,
5544 encoder_: &mut ___E,
5545 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmListChildrenRequest<'static>>,
5546 _: (),
5547 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5548 ::fidl_next::munge! {
5549 let crate::wire::RealmListChildrenRequest {
5550
5551 collection,
5552 iter,
5553
5554 } = out_;
5555 }
5556
5557 ::fidl_next::Encode::encode(self.collection, encoder_, collection, ())?;
5558
5559 ::fidl_next::Encode::encode(self.iter, encoder_, iter, ())?;
5560
5561 Ok(())
5562 }
5563 }
5564
5565 pub struct RealmGetChildOutputDictionaryRequest<T0> {
5566 pub child: T0,
5567 }
5568
5569 unsafe impl<___E, T0>
5570 ::fidl_next::Encode<crate::wire::RealmGetChildOutputDictionaryRequest<'static>, ___E>
5571 for RealmGetChildOutputDictionaryRequest<T0>
5572 where
5573 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5574 ___E: ::fidl_next::Encoder,
5575 ___E: ::fidl_next::fuchsia::HandleEncoder,
5576 T0: ::fidl_next::Encode<::fidl_next_fuchsia_component_decl::wire::ChildRef<'static>, ___E>,
5577 {
5578 #[inline]
5579 fn encode(
5580 self,
5581 encoder_: &mut ___E,
5582 out_: &mut ::core::mem::MaybeUninit<
5583 crate::wire::RealmGetChildOutputDictionaryRequest<'static>,
5584 >,
5585 _: (),
5586 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5587 ::fidl_next::munge! {
5588 let crate::wire::RealmGetChildOutputDictionaryRequest {
5589
5590 child,
5591
5592 } = out_;
5593 }
5594
5595 ::fidl_next::Encode::encode(self.child, encoder_, child, ())?;
5596
5597 Ok(())
5598 }
5599 }
5600
5601 pub struct RealmGetChildOutputDictionaryResponse<T0> {
5602 pub dictionary: T0,
5603 }
5604
5605 unsafe impl<___E, T0>
5606 ::fidl_next::Encode<crate::wire::RealmGetChildOutputDictionaryResponse, ___E>
5607 for RealmGetChildOutputDictionaryResponse<T0>
5608 where
5609 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5610 ___E: ::fidl_next::fuchsia::HandleEncoder,
5611 T0: ::fidl_next::Encode<::fidl_next_fuchsia_component_sandbox::wire::DictionaryRef, ___E>,
5612 {
5613 #[inline]
5614 fn encode(
5615 self,
5616 encoder_: &mut ___E,
5617 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmGetChildOutputDictionaryResponse>,
5618 _: (),
5619 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5620 ::fidl_next::munge! {
5621 let crate::wire::RealmGetChildOutputDictionaryResponse {
5622
5623 dictionary,
5624
5625 } = out_;
5626 }
5627
5628 ::fidl_next::Encode::encode(self.dictionary, encoder_, dictionary, ())?;
5629
5630 Ok(())
5631 }
5632 }
5633
5634 pub struct RealmOpenControllerRequest<T0, T1> {
5635 pub child: T0,
5636
5637 pub controller: T1,
5638 }
5639
5640 unsafe impl<___E, T0, T1>
5641 ::fidl_next::Encode<crate::wire::RealmOpenControllerRequest<'static>, ___E>
5642 for RealmOpenControllerRequest<T0, T1>
5643 where
5644 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5645 ___E: ::fidl_next::Encoder,
5646 ___E: ::fidl_next::fuchsia::HandleEncoder,
5647 T0: ::fidl_next::Encode<::fidl_next_fuchsia_component_decl::wire::ChildRef<'static>, ___E>,
5648 T1: ::fidl_next::Encode<
5649 ::fidl_next::ServerEnd<crate::Controller, ::fidl_next::fuchsia::WireChannel>,
5650 ___E,
5651 >,
5652 {
5653 #[inline]
5654 fn encode(
5655 self,
5656 encoder_: &mut ___E,
5657 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmOpenControllerRequest<'static>>,
5658 _: (),
5659 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5660 ::fidl_next::munge! {
5661 let crate::wire::RealmOpenControllerRequest {
5662
5663 child,
5664 controller,
5665
5666 } = out_;
5667 }
5668
5669 ::fidl_next::Encode::encode(self.child, encoder_, child, ())?;
5670
5671 ::fidl_next::Encode::encode(self.controller, encoder_, controller, ())?;
5672
5673 Ok(())
5674 }
5675 }
5676
5677 pub struct RealmOpenExposedDirRequest<T0, T1> {
5678 pub child: T0,
5679
5680 pub exposed_dir: T1,
5681 }
5682
5683 unsafe impl<___E, T0, T1>
5684 ::fidl_next::Encode<crate::wire::RealmOpenExposedDirRequest<'static>, ___E>
5685 for RealmOpenExposedDirRequest<T0, T1>
5686 where
5687 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5688 ___E: ::fidl_next::Encoder,
5689 ___E: ::fidl_next::fuchsia::HandleEncoder,
5690 T0: ::fidl_next::Encode<::fidl_next_fuchsia_component_decl::wire::ChildRef<'static>, ___E>,
5691 T1: ::fidl_next::Encode<
5692 ::fidl_next::ServerEnd<
5693 ::fidl_next_fuchsia_io::Directory,
5694 ::fidl_next::fuchsia::WireChannel,
5695 >,
5696 ___E,
5697 >,
5698 {
5699 #[inline]
5700 fn encode(
5701 self,
5702 encoder_: &mut ___E,
5703 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmOpenExposedDirRequest<'static>>,
5704 _: (),
5705 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5706 ::fidl_next::munge! {
5707 let crate::wire::RealmOpenExposedDirRequest {
5708
5709 child,
5710 exposed_dir,
5711
5712 } = out_;
5713 }
5714
5715 ::fidl_next::Encode::encode(self.child, encoder_, child, ())?;
5716
5717 ::fidl_next::Encode::encode(self.exposed_dir, encoder_, exposed_dir, ())?;
5718
5719 Ok(())
5720 }
5721 }
5722
5723 pub struct RealmCreateChildRequest<T0, T1, T2> {
5724 pub collection: T0,
5725
5726 pub decl: T1,
5727
5728 pub args: T2,
5729 }
5730
5731 unsafe impl<___E, T0, T1, T2>
5732 ::fidl_next::Encode<crate::wire::RealmCreateChildRequest<'static>, ___E>
5733 for RealmCreateChildRequest<T0, T1, T2>
5734 where
5735 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5736 ___E: ::fidl_next::Encoder,
5737 ___E: ::fidl_next::fuchsia::HandleEncoder,
5738 T0: ::fidl_next::Encode<
5739 ::fidl_next_fuchsia_component_decl::wire::CollectionRef<'static>,
5740 ___E,
5741 >,
5742 T1: ::fidl_next::Encode<::fidl_next_fuchsia_component_decl::wire::Child<'static>, ___E>,
5743 T2: ::fidl_next::Encode<crate::wire::CreateChildArgs<'static>, ___E>,
5744 {
5745 #[inline]
5746 fn encode(
5747 self,
5748 encoder_: &mut ___E,
5749 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmCreateChildRequest<'static>>,
5750 _: (),
5751 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5752 ::fidl_next::munge! {
5753 let crate::wire::RealmCreateChildRequest {
5754
5755 collection,
5756 decl,
5757 args,
5758
5759 } = out_;
5760 }
5761
5762 ::fidl_next::Encode::encode(self.collection, encoder_, collection, ())?;
5763
5764 ::fidl_next::Encode::encode(self.decl, encoder_, decl, ())?;
5765
5766 ::fidl_next::Encode::encode(self.args, encoder_, args, ())?;
5767
5768 Ok(())
5769 }
5770 }
5771
5772 pub struct RealmGetResolvedInfoResponse<T0> {
5773 pub resolved_info: T0,
5774 }
5775
5776 unsafe impl<___E, T0>
5777 ::fidl_next::Encode<crate::wire::RealmGetResolvedInfoResponse<'static>, ___E>
5778 for RealmGetResolvedInfoResponse<T0>
5779 where
5780 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5781 ___E: ::fidl_next::Encoder,
5782 ___E: ::fidl_next::fuchsia::HandleEncoder,
5783 T0: ::fidl_next::Encode<
5784 ::fidl_next_fuchsia_component_resolution::wire::Component<'static>,
5785 ___E,
5786 >,
5787 {
5788 #[inline]
5789 fn encode(
5790 self,
5791 encoder_: &mut ___E,
5792 out_: &mut ::core::mem::MaybeUninit<crate::wire::RealmGetResolvedInfoResponse<'static>>,
5793 _: (),
5794 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5795 ::fidl_next::munge! {
5796 let crate::wire::RealmGetResolvedInfoResponse {
5797
5798 resolved_info,
5799
5800 } = out_;
5801 }
5802
5803 ::fidl_next::Encode::encode(self.resolved_info, encoder_, resolved_info, ())?;
5804
5805 Ok(())
5806 }
5807 }
5808
5809 pub struct StorageAdminListStorageInRealmRequest<T0, T1> {
5810 pub relative_moniker: T0,
5811
5812 pub iterator: T1,
5813 }
5814
5815 unsafe impl<___E, T0, T1>
5816 ::fidl_next::Encode<crate::wire::StorageAdminListStorageInRealmRequest<'static>, ___E>
5817 for StorageAdminListStorageInRealmRequest<T0, T1>
5818 where
5819 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5820 ___E: ::fidl_next::Encoder,
5821 ___E: ::fidl_next::fuchsia::HandleEncoder,
5822 T0: ::fidl_next::Encode<::fidl_next::WireString<'static>, ___E>,
5823 T1: ::fidl_next::Encode<
5824 ::fidl_next::ServerEnd<crate::StorageIterator, ::fidl_next::fuchsia::WireChannel>,
5825 ___E,
5826 >,
5827 {
5828 #[inline]
5829 fn encode(
5830 self,
5831 encoder_: &mut ___E,
5832 out_: &mut ::core::mem::MaybeUninit<
5833 crate::wire::StorageAdminListStorageInRealmRequest<'static>,
5834 >,
5835 _: (),
5836 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5837 ::fidl_next::munge! {
5838 let crate::wire::StorageAdminListStorageInRealmRequest {
5839
5840 relative_moniker,
5841 iterator,
5842
5843 } = out_;
5844 }
5845
5846 ::fidl_next::Encode::encode(self.relative_moniker, encoder_, relative_moniker, 4096)?;
5847
5848 ::fidl_next::Encode::encode(self.iterator, encoder_, iterator, ())?;
5849
5850 Ok(())
5851 }
5852 }
5853
5854 pub struct StorageAdminOpenStorageRequest<T0, T1> {
5855 pub relative_moniker: T0,
5856
5857 pub object: T1,
5858 }
5859
5860 unsafe impl<___E, T0, T1>
5861 ::fidl_next::Encode<crate::wire::StorageAdminOpenStorageRequest<'static>, ___E>
5862 for StorageAdminOpenStorageRequest<T0, T1>
5863 where
5864 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5865 ___E: ::fidl_next::Encoder,
5866 ___E: ::fidl_next::fuchsia::HandleEncoder,
5867 T0: ::fidl_next::Encode<::fidl_next::WireString<'static>, ___E>,
5868 T1: ::fidl_next::Encode<
5869 ::fidl_next::ServerEnd<
5870 ::fidl_next_fuchsia_io::Node,
5871 ::fidl_next::fuchsia::WireChannel,
5872 >,
5873 ___E,
5874 >,
5875 {
5876 #[inline]
5877 fn encode(
5878 self,
5879 encoder_: &mut ___E,
5880 out_: &mut ::core::mem::MaybeUninit<
5881 crate::wire::StorageAdminOpenStorageRequest<'static>,
5882 >,
5883 _: (),
5884 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5885 ::fidl_next::munge! {
5886 let crate::wire::StorageAdminOpenStorageRequest {
5887
5888 relative_moniker,
5889 object,
5890
5891 } = out_;
5892 }
5893
5894 ::fidl_next::Encode::encode(self.relative_moniker, encoder_, relative_moniker, 4096)?;
5895
5896 ::fidl_next::Encode::encode(self.object, encoder_, object, ())?;
5897
5898 Ok(())
5899 }
5900 }
5901
5902 pub struct StorageAdminOpenComponentStorageByIdRequest<T0, T1> {
5903 pub id: T0,
5904
5905 pub object: T1,
5906 }
5907
5908 unsafe impl<___E, T0, T1>
5909 ::fidl_next::Encode<crate::wire::StorageAdminOpenComponentStorageByIdRequest<'static>, ___E>
5910 for StorageAdminOpenComponentStorageByIdRequest<T0, T1>
5911 where
5912 ___E: ::fidl_next::encoder::InternalHandleEncoder + ?Sized,
5913 ___E: ::fidl_next::Encoder,
5914 ___E: ::fidl_next::fuchsia::HandleEncoder,
5915 T0: ::fidl_next::Encode<::fidl_next::WireString<'static>, ___E>,
5916 T1: ::fidl_next::Encode<
5917 ::fidl_next::ServerEnd<
5918 ::fidl_next_fuchsia_io::Node,
5919 ::fidl_next::fuchsia::WireChannel,
5920 >,
5921 ___E,
5922 >,
5923 {
5924 #[inline]
5925 fn encode(
5926 self,
5927 encoder_: &mut ___E,
5928 out_: &mut ::core::mem::MaybeUninit<
5929 crate::wire::StorageAdminOpenComponentStorageByIdRequest<'static>,
5930 >,
5931 _: (),
5932 ) -> ::core::result::Result<(), ::fidl_next::EncodeError> {
5933 ::fidl_next::munge! {
5934 let crate::wire::StorageAdminOpenComponentStorageByIdRequest {
5935
5936 id,
5937 object,
5938
5939 } = out_;
5940 }
5941
5942 ::fidl_next::Encode::encode(self.id, encoder_, id, 64)?;
5943
5944 ::fidl_next::Encode::encode(self.object, encoder_, object, ())?;
5945
5946 Ok(())
5947 }
5948 }
5949}
5950
5951pub use self::natural::*;
5952
5953#[doc = " A protocol used to operate on a component.\n\n One may get access to a `Controller` when creating a component with the\n `Realm.CreateChild` method. You may also obtain a `Controller` for an\n existing child component with the `Realm.OpenController` method.\n"]
5955#[derive(PartialEq, Debug)]
5956pub struct Controller;
5957
5958#[cfg(target_os = "fuchsia")]
5959impl ::fidl_next::HasTransport for Controller {
5960 type Transport = ::fidl_next::fuchsia::zx::Channel;
5961}
5962
5963pub mod controller {
5964 pub mod prelude {
5965 pub use crate::{Controller, ControllerClientHandler, ControllerServerHandler, controller};
5966
5967 pub use crate::natural::ControllerStartRequest;
5968
5969 pub use crate::natural::ControllerDestroyResponse;
5970
5971 pub use crate::natural::ControllerGetExposedDictionaryResponse;
5972
5973 pub use crate::natural::ControllerIsStartedResponse;
5974
5975 pub use crate::natural::ControllerStartResponse;
5976
5977 pub use crate::natural::Error;
5978 }
5979
5980 pub struct Start;
5981
5982 impl ::fidl_next::Method for Start {
5983 const ORDINAL: u64 = 7532130149195770565;
5984 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
5985 ::fidl_next::protocol::Flexibility::Flexible;
5986
5987 type Protocol = crate::Controller;
5988
5989 type Request = crate::wire::ControllerStartRequest<'static>;
5990 }
5991
5992 impl ::fidl_next::TwoWayMethod for Start {
5993 type Response = ::fidl_next::WireFlexibleResult<
5994 'static,
5995 crate::wire::ControllerStartResponse,
5996 crate::wire::Error,
5997 >;
5998 }
5999
6000 impl<___R> ::fidl_next::Respond<___R> for Start {
6001 type Output = ::fidl_next::FlexibleResult<___R, ::fidl_next::util::Never>;
6002
6003 fn respond(response: ___R) -> Self::Output {
6004 ::fidl_next::FlexibleResult::Ok(response)
6005 }
6006 }
6007
6008 impl<___R> ::fidl_next::RespondErr<___R> for Start {
6009 type Output = ::fidl_next::FlexibleResult<::fidl_next::util::Never, ___R>;
6010
6011 fn respond_err(response: ___R) -> Self::Output {
6012 ::fidl_next::FlexibleResult::Err(response)
6013 }
6014 }
6015
6016 pub struct IsStarted;
6017
6018 impl ::fidl_next::Method for IsStarted {
6019 const ORDINAL: u64 = 2402079833990398915;
6020 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
6021 ::fidl_next::protocol::Flexibility::Flexible;
6022
6023 type Protocol = crate::Controller;
6024
6025 type Request = ();
6026 }
6027
6028 impl ::fidl_next::TwoWayMethod for IsStarted {
6029 type Response = ::fidl_next::WireFlexibleResult<
6030 'static,
6031 crate::wire::ControllerIsStartedResponse,
6032 crate::wire::Error,
6033 >;
6034 }
6035
6036 impl<___R> ::fidl_next::Respond<___R> for IsStarted {
6037 type Output = ::fidl_next::FlexibleResult<
6038 crate::generic::ControllerIsStartedResponse<___R>,
6039 ::fidl_next::util::Never,
6040 >;
6041
6042 fn respond(response: ___R) -> Self::Output {
6043 ::fidl_next::FlexibleResult::Ok(crate::generic::ControllerIsStartedResponse {
6044 is_started: response,
6045 })
6046 }
6047 }
6048
6049 impl<___R> ::fidl_next::RespondErr<___R> for IsStarted {
6050 type Output = ::fidl_next::FlexibleResult<::fidl_next::util::Never, ___R>;
6051
6052 fn respond_err(response: ___R) -> Self::Output {
6053 ::fidl_next::FlexibleResult::Err(response)
6054 }
6055 }
6056
6057 pub struct GetExposedDictionary;
6058
6059 impl ::fidl_next::Method for GetExposedDictionary {
6060 const ORDINAL: u64 = 9099583788120940443;
6061 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
6062 ::fidl_next::protocol::Flexibility::Flexible;
6063
6064 type Protocol = crate::Controller;
6065
6066 type Request = ();
6067 }
6068
6069 impl ::fidl_next::TwoWayMethod for GetExposedDictionary {
6070 type Response = ::fidl_next::WireFlexibleResult<
6071 'static,
6072 crate::wire::ControllerGetExposedDictionaryResponse,
6073 crate::wire::Error,
6074 >;
6075 }
6076
6077 impl<___R> ::fidl_next::Respond<___R> for GetExposedDictionary {
6078 type Output = ::fidl_next::FlexibleResult<
6079 crate::generic::ControllerGetExposedDictionaryResponse<___R>,
6080 ::fidl_next::util::Never,
6081 >;
6082
6083 fn respond(response: ___R) -> Self::Output {
6084 ::fidl_next::FlexibleResult::Ok(
6085 crate::generic::ControllerGetExposedDictionaryResponse { dictionary: response },
6086 )
6087 }
6088 }
6089
6090 impl<___R> ::fidl_next::RespondErr<___R> for GetExposedDictionary {
6091 type Output = ::fidl_next::FlexibleResult<::fidl_next::util::Never, ___R>;
6092
6093 fn respond_err(response: ___R) -> Self::Output {
6094 ::fidl_next::FlexibleResult::Err(response)
6095 }
6096 }
6097
6098 pub struct Destroy;
6099
6100 impl ::fidl_next::Method for Destroy {
6101 const ORDINAL: u64 = 8381937394141370177;
6102 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
6103 ::fidl_next::protocol::Flexibility::Flexible;
6104
6105 type Protocol = crate::Controller;
6106
6107 type Request = ();
6108 }
6109
6110 impl ::fidl_next::TwoWayMethod for Destroy {
6111 type Response = ::fidl_next::WireFlexibleResult<
6112 'static,
6113 crate::wire::ControllerDestroyResponse,
6114 crate::wire::Error,
6115 >;
6116 }
6117
6118 impl<___R> ::fidl_next::Respond<___R> for Destroy {
6119 type Output = ::fidl_next::FlexibleResult<___R, ::fidl_next::util::Never>;
6120
6121 fn respond(response: ___R) -> Self::Output {
6122 ::fidl_next::FlexibleResult::Ok(response)
6123 }
6124 }
6125
6126 impl<___R> ::fidl_next::RespondErr<___R> for Destroy {
6127 type Output = ::fidl_next::FlexibleResult<::fidl_next::util::Never, ___R>;
6128
6129 fn respond_err(response: ___R) -> Self::Output {
6130 ::fidl_next::FlexibleResult::Err(response)
6131 }
6132 }
6133
6134 mod ___detail {
6135 unsafe impl<___T> ::fidl_next::HasConnectionHandles<___T> for crate::Controller
6136 where
6137 ___T: ::fidl_next::Transport,
6138 {
6139 type Client = ControllerClient<___T>;
6140 type Server = ControllerServer<___T>;
6141 }
6142
6143 #[repr(transparent)]
6145 pub struct ControllerClient<___T: ::fidl_next::Transport> {
6146 #[allow(dead_code)]
6147 client: ::fidl_next::protocol::Client<___T>,
6148 }
6149
6150 impl<___T> ControllerClient<___T>
6151 where
6152 ___T: ::fidl_next::Transport,
6153 {
6154 #[doc = " Start the component, optionally providing additional handles to be given\n to the component. Returns INSTANCE_ALREADY_RUNNING if the instance is\n currently running.\n"]
6155 pub fn start(
6156 &self,
6157
6158 args: impl ::fidl_next::Encode<
6159 crate::wire::StartChildArgs<'static>,
6160 <___T as ::fidl_next::Transport>::SendBuffer,
6161 >,
6162
6163 execution_controller: impl ::fidl_next::Encode<
6164 ::fidl_next::ServerEnd<
6165 crate::ExecutionController,
6166 ::fidl_next::fuchsia::WireChannel,
6167 >,
6168 <___T as ::fidl_next::Transport>::SendBuffer,
6169 >,
6170 ) -> ::fidl_next::TwoWayFuture<'_, super::Start, ___T>
6171 where
6172 <___T as ::fidl_next::Transport>::SendBuffer:
6173 ::fidl_next::encoder::InternalHandleEncoder,
6174 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
6175 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
6176 {
6177 self.start_with(crate::generic::ControllerStartRequest {
6178 args,
6179
6180 execution_controller,
6181 })
6182 }
6183
6184 #[doc = " Start the component, optionally providing additional handles to be given\n to the component. Returns INSTANCE_ALREADY_RUNNING if the instance is\n currently running.\n"]
6185 pub fn start_with<___R>(
6186 &self,
6187 request: ___R,
6188 ) -> ::fidl_next::TwoWayFuture<'_, super::Start, ___T>
6189 where
6190 ___R: ::fidl_next::Encode<
6191 crate::wire::ControllerStartRequest<'static>,
6192 <___T as ::fidl_next::Transport>::SendBuffer,
6193 >,
6194 {
6195 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
6196 7532130149195770565,
6197 <super::Start as ::fidl_next::Method>::FLEXIBILITY,
6198 request,
6199 ))
6200 }
6201
6202 #[doc = " Returns true if this instance is currently running.\n"]
6203 pub fn is_started(&self) -> ::fidl_next::TwoWayFuture<'_, super::IsStarted, ___T> {
6204 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
6205 2402079833990398915,
6206 <super::IsStarted as ::fidl_next::Method>::FLEXIBILITY,
6207 (),
6208 ))
6209 }
6210
6211 #[doc = " Returns the dictionary containing the component\'s exposed capabilities.\n"]
6212 pub fn get_exposed_dictionary(
6213 &self,
6214 ) -> ::fidl_next::TwoWayFuture<'_, super::GetExposedDictionary, ___T> {
6215 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
6216 9099583788120940443,
6217 <super::GetExposedDictionary as ::fidl_next::Method>::FLEXIBILITY,
6218 (),
6219 ))
6220 }
6221
6222 #[doc = " Destroys this component. When this method returns, the component is\n either destroyed or in the case of an error no destruction happened.\n\n Errors:\n\n - `ACCESS_DENIED`: Destruction of this component is not allowed.\n Currently, this can happen if the component is a static child of its\n parent.\n - `INTERNAL`: Something prevented destruction from succeeding -- component\n manager\'s logs will contain more detail.\n"]
6223 pub fn destroy(&self) -> ::fidl_next::TwoWayFuture<'_, super::Destroy, ___T> {
6224 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
6225 8381937394141370177,
6226 <super::Destroy as ::fidl_next::Method>::FLEXIBILITY,
6227 (),
6228 ))
6229 }
6230 }
6231
6232 #[repr(transparent)]
6234 pub struct ControllerServer<___T: ::fidl_next::Transport> {
6235 server: ::fidl_next::protocol::Server<___T>,
6236 }
6237
6238 impl<___T> ControllerServer<___T> where ___T: ::fidl_next::Transport {}
6239 }
6240}
6241
6242pub trait ControllerClientHandler<
6246 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
6247 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
6248>
6249{
6250 fn on_unknown_interaction(
6251 &mut self,
6252 ordinal: u64,
6253 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send {
6254 ::core::future::ready(())
6255 }
6256}
6257
6258impl<___T> ControllerClientHandler<___T> for ::fidl_next::IgnoreEvents
6259where
6260 ___T: ::fidl_next::Transport,
6261{
6262 async fn on_unknown_interaction(&mut self, _: u64) {}
6263}
6264
6265impl<___H, ___T> ::fidl_next::DispatchClientMessage<___H, ___T> for Controller
6266where
6267 ___H: ControllerClientHandler<___T> + ::core::marker::Send,
6268 ___T: ::fidl_next::Transport,
6269{
6270 async fn on_event(
6271 handler: &mut ___H,
6272 ordinal: u64,
6273 flexibility: ::fidl_next::protocol::Flexibility,
6274 buffer: ___T::RecvBuffer,
6275 ) -> ::core::result::Result<(), ::fidl_next::ProtocolError<___T::Error>> {
6276 match ordinal {
6277 ordinal => {
6278 handler.on_unknown_interaction(ordinal).await;
6279 if ::core::matches!(flexibility, ::fidl_next::protocol::Flexibility::Strict) {
6280 Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
6281 } else {
6282 Ok(())
6283 }
6284 }
6285 }
6286 }
6287}
6288
6289pub trait ControllerServerHandler<
6293 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
6294 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
6295>
6296{
6297 #[doc = " Start the component, optionally providing additional handles to be given\n to the component. Returns INSTANCE_ALREADY_RUNNING if the instance is\n currently running.\n"]
6298 fn start(
6299 &mut self,
6300
6301 request: ::fidl_next::Request<controller::Start, ___T>,
6302
6303 responder: ::fidl_next::Responder<controller::Start, ___T>,
6304 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
6305
6306 #[doc = " Returns true if this instance is currently running.\n"]
6307 fn is_started(
6308 &mut self,
6309
6310 responder: ::fidl_next::Responder<controller::IsStarted, ___T>,
6311 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
6312
6313 #[doc = " Returns the dictionary containing the component\'s exposed capabilities.\n"]
6314 fn get_exposed_dictionary(
6315 &mut self,
6316
6317 responder: ::fidl_next::Responder<controller::GetExposedDictionary, ___T>,
6318 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
6319
6320 #[doc = " Destroys this component. When this method returns, the component is\n either destroyed or in the case of an error no destruction happened.\n\n Errors:\n\n - `ACCESS_DENIED`: Destruction of this component is not allowed.\n Currently, this can happen if the component is a static child of its\n parent.\n - `INTERNAL`: Something prevented destruction from succeeding -- component\n manager\'s logs will contain more detail.\n"]
6321 fn destroy(
6322 &mut self,
6323
6324 responder: ::fidl_next::Responder<controller::Destroy, ___T>,
6325 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
6326
6327 fn on_unknown_interaction(
6328 &mut self,
6329 ordinal: u64,
6330 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send {
6331 ::core::future::ready(())
6332 }
6333}
6334
6335impl<___H, ___T> ::fidl_next::DispatchServerMessage<___H, ___T> for Controller
6336where
6337 ___H: ControllerServerHandler<___T> + ::core::marker::Send,
6338 ___T: ::fidl_next::Transport,
6339 <controller::Start as ::fidl_next::Method>::Request:
6340 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
6341{
6342 async fn on_one_way(
6343 handler: &mut ___H,
6344 ordinal: u64,
6345 flexibility: ::fidl_next::protocol::Flexibility,
6346 buffer: ___T::RecvBuffer,
6347 ) -> ::core::result::Result<
6348 (),
6349 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
6350 > {
6351 match ordinal {
6352 ordinal => {
6353 handler.on_unknown_interaction(ordinal).await;
6354 if ::core::matches!(flexibility, ::fidl_next::protocol::Flexibility::Strict) {
6355 Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
6356 } else {
6357 Ok(())
6358 }
6359 }
6360 }
6361 }
6362
6363 async fn on_two_way(
6364 handler: &mut ___H,
6365 ordinal: u64,
6366 flexibility: ::fidl_next::protocol::Flexibility,
6367 buffer: ___T::RecvBuffer,
6368 responder: ::fidl_next::protocol::Responder<___T>,
6369 ) -> ::core::result::Result<
6370 (),
6371 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
6372 > {
6373 match ordinal {
6374 7532130149195770565 => {
6375 let responder = ::fidl_next::Responder::from_untyped(responder);
6376
6377 match ::fidl_next::DecoderExt::decode(buffer) {
6378 Ok(decoded) => {
6379 handler.start(::fidl_next::Request::from_decoded(decoded), responder).await;
6380 Ok(())
6381 }
6382 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
6383 ordinal: 7532130149195770565,
6384 error,
6385 }),
6386 }
6387 }
6388
6389 2402079833990398915 => {
6390 let responder = ::fidl_next::Responder::from_untyped(responder);
6391
6392 handler.is_started(responder).await;
6393 Ok(())
6394 }
6395
6396 9099583788120940443 => {
6397 let responder = ::fidl_next::Responder::from_untyped(responder);
6398
6399 handler.get_exposed_dictionary(responder).await;
6400 Ok(())
6401 }
6402
6403 8381937394141370177 => {
6404 let responder = ::fidl_next::Responder::from_untyped(responder);
6405
6406 handler.destroy(responder).await;
6407 Ok(())
6408 }
6409
6410 ordinal => {
6411 handler.on_unknown_interaction(ordinal).await;
6412 if ::core::matches!(flexibility, ::fidl_next::protocol::Flexibility::Strict) {
6413 Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
6414 } else {
6415 responder
6416 .respond(
6417 ordinal,
6418 flexibility,
6419 ::fidl_next::Flexible::<()>::FrameworkErr(
6420 ::fidl_next::FrameworkError::UnknownMethod,
6421 ),
6422 )
6423 .expect("encoding a framework error should never fail")
6424 .await?;
6425 Ok(())
6426 }
6427 }
6428 }
6429 }
6430}
6431
6432#[doc = " Listener for events on the component hierarchy.\n Can\'t be used outside of the platform.\n"]
6434#[derive(PartialEq, Debug)]
6435pub struct EventStream;
6436
6437impl ::fidl_next::Discoverable for EventStream {
6438 const PROTOCOL_NAME: &'static str = "fuchsia.component.EventStream";
6439}
6440
6441#[cfg(target_os = "fuchsia")]
6442impl ::fidl_next::HasTransport for EventStream {
6443 type Transport = ::fidl_next::fuchsia::zx::Channel;
6444}
6445
6446pub mod event_stream {
6447 pub mod prelude {
6448 pub use crate::{
6449 EventStream, EventStreamClientHandler, EventStreamServerHandler, event_stream,
6450 };
6451
6452 pub use crate::natural::EventStreamGetNextResponse;
6453 }
6454
6455 pub struct GetNext;
6456
6457 impl ::fidl_next::Method for GetNext {
6458 const ORDINAL: u64 = 4549982840421936006;
6459 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
6460 ::fidl_next::protocol::Flexibility::Strict;
6461
6462 type Protocol = crate::EventStream;
6463
6464 type Request = ();
6465 }
6466
6467 impl ::fidl_next::TwoWayMethod for GetNext {
6468 type Response = crate::wire::EventStreamGetNextResponse<'static>;
6469 }
6470
6471 impl<___R> ::fidl_next::Respond<___R> for GetNext {
6472 type Output = crate::generic::EventStreamGetNextResponse<___R>;
6473
6474 fn respond(response: ___R) -> Self::Output {
6475 crate::generic::EventStreamGetNextResponse { events: response }
6476 }
6477 }
6478
6479 pub struct WaitForReady;
6480
6481 impl ::fidl_next::Method for WaitForReady {
6482 const ORDINAL: u64 = 3545212058508387970;
6483 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
6484 ::fidl_next::protocol::Flexibility::Strict;
6485
6486 type Protocol = crate::EventStream;
6487
6488 type Request = ();
6489 }
6490
6491 impl ::fidl_next::TwoWayMethod for WaitForReady {
6492 type Response = ();
6493 }
6494
6495 impl<___R> ::fidl_next::Respond<___R> for WaitForReady {
6496 type Output = ___R;
6497
6498 fn respond(response: ___R) -> Self::Output {
6499 response
6500 }
6501 }
6502
6503 mod ___detail {
6504 unsafe impl<___T> ::fidl_next::HasConnectionHandles<___T> for crate::EventStream
6505 where
6506 ___T: ::fidl_next::Transport,
6507 {
6508 type Client = EventStreamClient<___T>;
6509 type Server = EventStreamServer<___T>;
6510 }
6511
6512 #[repr(transparent)]
6514 pub struct EventStreamClient<___T: ::fidl_next::Transport> {
6515 #[allow(dead_code)]
6516 client: ::fidl_next::protocol::Client<___T>,
6517 }
6518
6519 impl<___T> EventStreamClient<___T>
6520 where
6521 ___T: ::fidl_next::Transport,
6522 {
6523 pub fn get_next(&self) -> ::fidl_next::TwoWayFuture<'_, super::GetNext, ___T> {
6524 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
6525 4549982840421936006,
6526 <super::GetNext as ::fidl_next::Method>::FLEXIBILITY,
6527 (),
6528 ))
6529 }
6530
6531 #[doc = " Returns immediately. Used to indicate that the FIDL connection\n completed. This is needed for non-static streams to verify\n that subscribe has completed before components are started.\n"]
6532 pub fn wait_for_ready(
6533 &self,
6534 ) -> ::fidl_next::TwoWayFuture<'_, super::WaitForReady, ___T> {
6535 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
6536 3545212058508387970,
6537 <super::WaitForReady as ::fidl_next::Method>::FLEXIBILITY,
6538 (),
6539 ))
6540 }
6541 }
6542
6543 #[repr(transparent)]
6545 pub struct EventStreamServer<___T: ::fidl_next::Transport> {
6546 server: ::fidl_next::protocol::Server<___T>,
6547 }
6548
6549 impl<___T> EventStreamServer<___T> where ___T: ::fidl_next::Transport {}
6550 }
6551}
6552
6553pub trait EventStreamClientHandler<
6557 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
6558 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
6559>
6560{
6561}
6562
6563impl<___T> EventStreamClientHandler<___T> for ::fidl_next::IgnoreEvents where
6564 ___T: ::fidl_next::Transport
6565{
6566}
6567
6568impl<___H, ___T> ::fidl_next::DispatchClientMessage<___H, ___T> for EventStream
6569where
6570 ___H: EventStreamClientHandler<___T> + ::core::marker::Send,
6571 ___T: ::fidl_next::Transport,
6572{
6573 async fn on_event(
6574 handler: &mut ___H,
6575 ordinal: u64,
6576 flexibility: ::fidl_next::protocol::Flexibility,
6577 buffer: ___T::RecvBuffer,
6578 ) -> ::core::result::Result<(), ::fidl_next::ProtocolError<___T::Error>> {
6579 match ordinal {
6580 ordinal => Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal)),
6581 }
6582 }
6583}
6584
6585pub trait EventStreamServerHandler<
6589 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
6590 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
6591>
6592{
6593 fn get_next(
6594 &mut self,
6595
6596 responder: ::fidl_next::Responder<event_stream::GetNext, ___T>,
6597 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
6598
6599 #[doc = " Returns immediately. Used to indicate that the FIDL connection\n completed. This is needed for non-static streams to verify\n that subscribe has completed before components are started.\n"]
6600 fn wait_for_ready(
6601 &mut self,
6602
6603 responder: ::fidl_next::Responder<event_stream::WaitForReady, ___T>,
6604 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
6605}
6606
6607impl<___H, ___T> ::fidl_next::DispatchServerMessage<___H, ___T> for EventStream
6608where
6609 ___H: EventStreamServerHandler<___T> + ::core::marker::Send,
6610 ___T: ::fidl_next::Transport,
6611{
6612 async fn on_one_way(
6613 handler: &mut ___H,
6614 ordinal: u64,
6615 flexibility: ::fidl_next::protocol::Flexibility,
6616 buffer: ___T::RecvBuffer,
6617 ) -> ::core::result::Result<
6618 (),
6619 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
6620 > {
6621 match ordinal {
6622 ordinal => Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal)),
6623 }
6624 }
6625
6626 async fn on_two_way(
6627 handler: &mut ___H,
6628 ordinal: u64,
6629 flexibility: ::fidl_next::protocol::Flexibility,
6630 buffer: ___T::RecvBuffer,
6631 responder: ::fidl_next::protocol::Responder<___T>,
6632 ) -> ::core::result::Result<
6633 (),
6634 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
6635 > {
6636 match ordinal {
6637 4549982840421936006 => {
6638 let responder = ::fidl_next::Responder::from_untyped(responder);
6639
6640 handler.get_next(responder).await;
6641 Ok(())
6642 }
6643
6644 3545212058508387970 => {
6645 let responder = ::fidl_next::Responder::from_untyped(responder);
6646
6647 handler.wait_for_ready(responder).await;
6648 Ok(())
6649 }
6650
6651 ordinal => Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal)),
6652 }
6653 }
6654}
6655
6656#[doc = " A protocol used by a component instance to obtain information about\n components in its own realm.\n\n This protocol only supports getting the moniker at the moment but could\n expand to other privileged information such as the URL of a component.\n\n The component framework provides this capability to components that use\n `fuchsia.component.Introspector` from framework.\n"]
6658#[derive(PartialEq, Debug)]
6659pub struct Introspector;
6660
6661impl ::fidl_next::Discoverable for Introspector {
6662 const PROTOCOL_NAME: &'static str = "fuchsia.component.Introspector";
6663}
6664
6665#[cfg(target_os = "fuchsia")]
6666impl ::fidl_next::HasTransport for Introspector {
6667 type Transport = ::fidl_next::fuchsia::zx::Channel;
6668}
6669
6670pub mod introspector {
6671 pub mod prelude {
6672 pub use crate::{
6673 Introspector, IntrospectorClientHandler, IntrospectorServerHandler, introspector,
6674 };
6675
6676 pub use crate::natural::Error;
6677
6678 pub use crate::natural::IntrospectorGetMonikerRequest;
6679
6680 pub use crate::natural::IntrospectorGetMonikerResponse;
6681 }
6682
6683 pub struct GetMoniker;
6684
6685 impl ::fidl_next::Method for GetMoniker {
6686 const ORDINAL: u64 = 214344082539672664;
6687 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
6688 ::fidl_next::protocol::Flexibility::Flexible;
6689
6690 type Protocol = crate::Introspector;
6691
6692 type Request = crate::wire::IntrospectorGetMonikerRequest;
6693 }
6694
6695 impl ::fidl_next::TwoWayMethod for GetMoniker {
6696 type Response = ::fidl_next::WireFlexibleResult<
6697 'static,
6698 crate::wire::IntrospectorGetMonikerResponse<'static>,
6699 crate::wire::Error,
6700 >;
6701 }
6702
6703 impl<___R> ::fidl_next::Respond<___R> for GetMoniker {
6704 type Output = ::fidl_next::FlexibleResult<
6705 crate::generic::IntrospectorGetMonikerResponse<___R>,
6706 ::fidl_next::util::Never,
6707 >;
6708
6709 fn respond(response: ___R) -> Self::Output {
6710 ::fidl_next::FlexibleResult::Ok(crate::generic::IntrospectorGetMonikerResponse {
6711 moniker: response,
6712 })
6713 }
6714 }
6715
6716 impl<___R> ::fidl_next::RespondErr<___R> for GetMoniker {
6717 type Output = ::fidl_next::FlexibleResult<::fidl_next::util::Never, ___R>;
6718
6719 fn respond_err(response: ___R) -> Self::Output {
6720 ::fidl_next::FlexibleResult::Err(response)
6721 }
6722 }
6723
6724 mod ___detail {
6725 unsafe impl<___T> ::fidl_next::HasConnectionHandles<___T> for crate::Introspector
6726 where
6727 ___T: ::fidl_next::Transport,
6728 {
6729 type Client = IntrospectorClient<___T>;
6730 type Server = IntrospectorServer<___T>;
6731 }
6732
6733 #[repr(transparent)]
6735 pub struct IntrospectorClient<___T: ::fidl_next::Transport> {
6736 #[allow(dead_code)]
6737 client: ::fidl_next::protocol::Client<___T>,
6738 }
6739
6740 impl<___T> IntrospectorClient<___T>
6741 where
6742 ___T: ::fidl_next::Transport,
6743 {
6744 #[doc = " Obtains the moniker relative to this realm of the component\n corresponding to the provided token. Runners may obtain the token via\n `fuchsia.component.runner/ComponentStartInfo.component_instance`.\n\n Returns `Error.INSTANCE_NOT_FOUND` if the token is invalid, or\n does not correspond to a component under this realm.\n"]
6745 pub fn get_moniker(
6746 &self,
6747
6748 component_instance: impl ::fidl_next::Encode<
6749 ::fidl_next::fuchsia::WireEvent,
6750 <___T as ::fidl_next::Transport>::SendBuffer,
6751 >,
6752 ) -> ::fidl_next::TwoWayFuture<'_, super::GetMoniker, ___T>
6753 where
6754 <___T as ::fidl_next::Transport>::SendBuffer:
6755 ::fidl_next::encoder::InternalHandleEncoder,
6756 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
6757 {
6758 self.get_moniker_with(crate::generic::IntrospectorGetMonikerRequest {
6759 component_instance,
6760 })
6761 }
6762
6763 #[doc = " Obtains the moniker relative to this realm of the component\n corresponding to the provided token. Runners may obtain the token via\n `fuchsia.component.runner/ComponentStartInfo.component_instance`.\n\n Returns `Error.INSTANCE_NOT_FOUND` if the token is invalid, or\n does not correspond to a component under this realm.\n"]
6764 pub fn get_moniker_with<___R>(
6765 &self,
6766 request: ___R,
6767 ) -> ::fidl_next::TwoWayFuture<'_, super::GetMoniker, ___T>
6768 where
6769 ___R: ::fidl_next::Encode<
6770 crate::wire::IntrospectorGetMonikerRequest,
6771 <___T as ::fidl_next::Transport>::SendBuffer,
6772 >,
6773 {
6774 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
6775 214344082539672664,
6776 <super::GetMoniker as ::fidl_next::Method>::FLEXIBILITY,
6777 request,
6778 ))
6779 }
6780 }
6781
6782 #[repr(transparent)]
6784 pub struct IntrospectorServer<___T: ::fidl_next::Transport> {
6785 server: ::fidl_next::protocol::Server<___T>,
6786 }
6787
6788 impl<___T> IntrospectorServer<___T> where ___T: ::fidl_next::Transport {}
6789 }
6790}
6791
6792pub trait IntrospectorClientHandler<
6796 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
6797 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
6798>
6799{
6800 fn on_unknown_interaction(
6801 &mut self,
6802 ordinal: u64,
6803 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send {
6804 ::core::future::ready(())
6805 }
6806}
6807
6808impl<___T> IntrospectorClientHandler<___T> for ::fidl_next::IgnoreEvents
6809where
6810 ___T: ::fidl_next::Transport,
6811{
6812 async fn on_unknown_interaction(&mut self, _: u64) {}
6813}
6814
6815impl<___H, ___T> ::fidl_next::DispatchClientMessage<___H, ___T> for Introspector
6816where
6817 ___H: IntrospectorClientHandler<___T> + ::core::marker::Send,
6818 ___T: ::fidl_next::Transport,
6819{
6820 async fn on_event(
6821 handler: &mut ___H,
6822 ordinal: u64,
6823 flexibility: ::fidl_next::protocol::Flexibility,
6824 buffer: ___T::RecvBuffer,
6825 ) -> ::core::result::Result<(), ::fidl_next::ProtocolError<___T::Error>> {
6826 match ordinal {
6827 ordinal => {
6828 handler.on_unknown_interaction(ordinal).await;
6829 if ::core::matches!(flexibility, ::fidl_next::protocol::Flexibility::Strict) {
6830 Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
6831 } else {
6832 Ok(())
6833 }
6834 }
6835 }
6836 }
6837}
6838
6839pub trait IntrospectorServerHandler<
6843 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
6844 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
6845>
6846{
6847 #[doc = " Obtains the moniker relative to this realm of the component\n corresponding to the provided token. Runners may obtain the token via\n `fuchsia.component.runner/ComponentStartInfo.component_instance`.\n\n Returns `Error.INSTANCE_NOT_FOUND` if the token is invalid, or\n does not correspond to a component under this realm.\n"]
6848 fn get_moniker(
6849 &mut self,
6850
6851 request: ::fidl_next::Request<introspector::GetMoniker, ___T>,
6852
6853 responder: ::fidl_next::Responder<introspector::GetMoniker, ___T>,
6854 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
6855
6856 fn on_unknown_interaction(
6857 &mut self,
6858 ordinal: u64,
6859 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send {
6860 ::core::future::ready(())
6861 }
6862}
6863
6864impl<___H, ___T> ::fidl_next::DispatchServerMessage<___H, ___T> for Introspector
6865where
6866 ___H: IntrospectorServerHandler<___T> + ::core::marker::Send,
6867 ___T: ::fidl_next::Transport,
6868 <introspector::GetMoniker as ::fidl_next::Method>::Request:
6869 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
6870{
6871 async fn on_one_way(
6872 handler: &mut ___H,
6873 ordinal: u64,
6874 flexibility: ::fidl_next::protocol::Flexibility,
6875 buffer: ___T::RecvBuffer,
6876 ) -> ::core::result::Result<
6877 (),
6878 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
6879 > {
6880 match ordinal {
6881 ordinal => {
6882 handler.on_unknown_interaction(ordinal).await;
6883 if ::core::matches!(flexibility, ::fidl_next::protocol::Flexibility::Strict) {
6884 Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
6885 } else {
6886 Ok(())
6887 }
6888 }
6889 }
6890 }
6891
6892 async fn on_two_way(
6893 handler: &mut ___H,
6894 ordinal: u64,
6895 flexibility: ::fidl_next::protocol::Flexibility,
6896 buffer: ___T::RecvBuffer,
6897 responder: ::fidl_next::protocol::Responder<___T>,
6898 ) -> ::core::result::Result<
6899 (),
6900 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
6901 > {
6902 match ordinal {
6903 214344082539672664 => {
6904 let responder = ::fidl_next::Responder::from_untyped(responder);
6905
6906 match ::fidl_next::DecoderExt::decode(buffer) {
6907 Ok(decoded) => {
6908 handler
6909 .get_moniker(::fidl_next::Request::from_decoded(decoded), responder)
6910 .await;
6911 Ok(())
6912 }
6913 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
6914 ordinal: 214344082539672664,
6915 error,
6916 }),
6917 }
6918 }
6919
6920 ordinal => {
6921 handler.on_unknown_interaction(ordinal).await;
6922 if ::core::matches!(flexibility, ::fidl_next::protocol::Flexibility::Strict) {
6923 Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
6924 } else {
6925 responder
6926 .respond(
6927 ordinal,
6928 flexibility,
6929 ::fidl_next::Flexible::<()>::FrameworkErr(
6930 ::fidl_next::FrameworkError::UnknownMethod,
6931 ),
6932 )
6933 .expect("encoding a framework error should never fail")
6934 .await?;
6935 Ok(())
6936 }
6937 }
6938 }
6939 }
6940}
6941
6942#[doc = " Protocol for performing namespace operations.\n"]
6944#[derive(PartialEq, Debug)]
6945pub struct Namespace;
6946
6947impl ::fidl_next::Discoverable for Namespace {
6948 const PROTOCOL_NAME: &'static str = "fuchsia.component.Namespace";
6949}
6950
6951#[cfg(target_os = "fuchsia")]
6952impl ::fidl_next::HasTransport for Namespace {
6953 type Transport = ::fidl_next::fuchsia::zx::Channel;
6954}
6955
6956pub mod namespace {
6957 pub mod prelude {
6958 pub use crate::{Namespace, NamespaceClientHandler, NamespaceServerHandler, namespace};
6959
6960 pub use crate::natural::NamespaceCreateRequest;
6961
6962 pub use crate::natural::NamespaceError;
6963
6964 pub use crate::natural::NamespaceCreateResponse;
6965 }
6966
6967 pub struct Create;
6968
6969 impl ::fidl_next::Method for Create {
6970 const ORDINAL: u64 = 4839678630846501113;
6971 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
6972 ::fidl_next::protocol::Flexibility::Flexible;
6973
6974 type Protocol = crate::Namespace;
6975
6976 type Request = crate::wire::NamespaceCreateRequest<'static>;
6977 }
6978
6979 impl ::fidl_next::TwoWayMethod for Create {
6980 type Response = ::fidl_next::WireFlexibleResult<
6981 'static,
6982 crate::wire::NamespaceCreateResponse<'static>,
6983 crate::wire::NamespaceError,
6984 >;
6985 }
6986
6987 impl<___R> ::fidl_next::Respond<___R> for Create {
6988 type Output = ::fidl_next::FlexibleResult<
6989 crate::generic::NamespaceCreateResponse<___R>,
6990 ::fidl_next::util::Never,
6991 >;
6992
6993 fn respond(response: ___R) -> Self::Output {
6994 ::fidl_next::FlexibleResult::Ok(crate::generic::NamespaceCreateResponse {
6995 entries: response,
6996 })
6997 }
6998 }
6999
7000 impl<___R> ::fidl_next::RespondErr<___R> for Create {
7001 type Output = ::fidl_next::FlexibleResult<::fidl_next::util::Never, ___R>;
7002
7003 fn respond_err(response: ___R) -> Self::Output {
7004 ::fidl_next::FlexibleResult::Err(response)
7005 }
7006 }
7007
7008 mod ___detail {
7009 unsafe impl<___T> ::fidl_next::HasConnectionHandles<___T> for crate::Namespace
7010 where
7011 ___T: ::fidl_next::Transport,
7012 {
7013 type Client = NamespaceClient<___T>;
7014 type Server = NamespaceServer<___T>;
7015 }
7016
7017 #[repr(transparent)]
7019 pub struct NamespaceClient<___T: ::fidl_next::Transport> {
7020 #[allow(dead_code)]
7021 client: ::fidl_next::protocol::Client<___T>,
7022 }
7023
7024 impl<___T> NamespaceClient<___T>
7025 where
7026 ___T: ::fidl_next::Transport,
7027 {
7028 pub fn create(
7029 &self,
7030
7031 entries: impl ::fidl_next::Encode<
7032 ::fidl_next::WireVector<'static, crate::wire::NamespaceInputEntry<'static>>,
7033 <___T as ::fidl_next::Transport>::SendBuffer,
7034 >,
7035 ) -> ::fidl_next::TwoWayFuture<'_, super::Create, ___T>
7036 where
7037 <___T as ::fidl_next::Transport>::SendBuffer:
7038 ::fidl_next::encoder::InternalHandleEncoder,
7039 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
7040 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
7041 {
7042 self.create_with(crate::generic::NamespaceCreateRequest { entries })
7043 }
7044
7045 pub fn create_with<___R>(
7046 &self,
7047 request: ___R,
7048 ) -> ::fidl_next::TwoWayFuture<'_, super::Create, ___T>
7049 where
7050 ___R: ::fidl_next::Encode<
7051 crate::wire::NamespaceCreateRequest<'static>,
7052 <___T as ::fidl_next::Transport>::SendBuffer,
7053 >,
7054 {
7055 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
7056 4839678630846501113,
7057 <super::Create as ::fidl_next::Method>::FLEXIBILITY,
7058 request,
7059 ))
7060 }
7061 }
7062
7063 #[repr(transparent)]
7065 pub struct NamespaceServer<___T: ::fidl_next::Transport> {
7066 server: ::fidl_next::protocol::Server<___T>,
7067 }
7068
7069 impl<___T> NamespaceServer<___T> where ___T: ::fidl_next::Transport {}
7070 }
7071}
7072
7073pub trait NamespaceClientHandler<
7077 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
7078 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
7079>
7080{
7081 fn on_unknown_interaction(
7082 &mut self,
7083 ordinal: u64,
7084 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send {
7085 ::core::future::ready(())
7086 }
7087}
7088
7089impl<___T> NamespaceClientHandler<___T> for ::fidl_next::IgnoreEvents
7090where
7091 ___T: ::fidl_next::Transport,
7092{
7093 async fn on_unknown_interaction(&mut self, _: u64) {}
7094}
7095
7096impl<___H, ___T> ::fidl_next::DispatchClientMessage<___H, ___T> for Namespace
7097where
7098 ___H: NamespaceClientHandler<___T> + ::core::marker::Send,
7099 ___T: ::fidl_next::Transport,
7100{
7101 async fn on_event(
7102 handler: &mut ___H,
7103 ordinal: u64,
7104 flexibility: ::fidl_next::protocol::Flexibility,
7105 buffer: ___T::RecvBuffer,
7106 ) -> ::core::result::Result<(), ::fidl_next::ProtocolError<___T::Error>> {
7107 match ordinal {
7108 ordinal => {
7109 handler.on_unknown_interaction(ordinal).await;
7110 if ::core::matches!(flexibility, ::fidl_next::protocol::Flexibility::Strict) {
7111 Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
7112 } else {
7113 Ok(())
7114 }
7115 }
7116 }
7117 }
7118}
7119
7120pub trait NamespaceServerHandler<
7124 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
7125 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
7126>
7127{
7128 fn create(
7129 &mut self,
7130
7131 request: ::fidl_next::Request<namespace::Create, ___T>,
7132
7133 responder: ::fidl_next::Responder<namespace::Create, ___T>,
7134 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
7135
7136 fn on_unknown_interaction(
7137 &mut self,
7138 ordinal: u64,
7139 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send {
7140 ::core::future::ready(())
7141 }
7142}
7143
7144impl<___H, ___T> ::fidl_next::DispatchServerMessage<___H, ___T> for Namespace
7145where
7146 ___H: NamespaceServerHandler<___T> + ::core::marker::Send,
7147 ___T: ::fidl_next::Transport,
7148 <namespace::Create as ::fidl_next::Method>::Request:
7149 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
7150{
7151 async fn on_one_way(
7152 handler: &mut ___H,
7153 ordinal: u64,
7154 flexibility: ::fidl_next::protocol::Flexibility,
7155 buffer: ___T::RecvBuffer,
7156 ) -> ::core::result::Result<
7157 (),
7158 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
7159 > {
7160 match ordinal {
7161 ordinal => {
7162 handler.on_unknown_interaction(ordinal).await;
7163 if ::core::matches!(flexibility, ::fidl_next::protocol::Flexibility::Strict) {
7164 Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
7165 } else {
7166 Ok(())
7167 }
7168 }
7169 }
7170 }
7171
7172 async fn on_two_way(
7173 handler: &mut ___H,
7174 ordinal: u64,
7175 flexibility: ::fidl_next::protocol::Flexibility,
7176 buffer: ___T::RecvBuffer,
7177 responder: ::fidl_next::protocol::Responder<___T>,
7178 ) -> ::core::result::Result<
7179 (),
7180 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
7181 > {
7182 match ordinal {
7183 4839678630846501113 => {
7184 let responder = ::fidl_next::Responder::from_untyped(responder);
7185
7186 match ::fidl_next::DecoderExt::decode(buffer) {
7187 Ok(decoded) => {
7188 handler
7189 .create(::fidl_next::Request::from_decoded(decoded), responder)
7190 .await;
7191 Ok(())
7192 }
7193 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
7194 ordinal: 4839678630846501113,
7195 error,
7196 }),
7197 }
7198 }
7199
7200 ordinal => {
7201 handler.on_unknown_interaction(ordinal).await;
7202 if ::core::matches!(flexibility, ::fidl_next::protocol::Flexibility::Strict) {
7203 Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal))
7204 } else {
7205 responder
7206 .respond(
7207 ordinal,
7208 flexibility,
7209 ::fidl_next::Flexible::<()>::FrameworkErr(
7210 ::fidl_next::FrameworkError::UnknownMethod,
7211 ),
7212 )
7213 .expect("encoding a framework error should never fail")
7214 .await?;
7215 Ok(())
7216 }
7217 }
7218 }
7219 }
7220}
7221
7222#[doc = " A protocol used by a component instance to manage its own realm, such as for\n binding to its children.\n\n Requests to this protocol are processed in the order they are received.\n Clients that wish to send requests in parallel should open multiple\n connections.\n\n The component framework provides this service to components that use\n `fuchsia.component.Realm`.\n"]
7224#[derive(PartialEq, Debug)]
7225pub struct Realm;
7226
7227impl ::fidl_next::Discoverable for Realm {
7228 const PROTOCOL_NAME: &'static str = "fuchsia.component.Realm";
7229}
7230
7231#[cfg(target_os = "fuchsia")]
7232impl ::fidl_next::HasTransport for Realm {
7233 type Transport = ::fidl_next::fuchsia::zx::Channel;
7234}
7235
7236pub mod realm {
7237 pub mod prelude {
7238 pub use crate::{Realm, RealmClientHandler, RealmServerHandler, realm};
7239
7240 pub use crate::natural::Error;
7241
7242 pub use crate::natural::RealmCreateChildRequest;
7243
7244 pub use crate::natural::RealmDestroyChildRequest;
7245
7246 pub use crate::natural::RealmGetChildOutputDictionaryRequest;
7247
7248 pub use crate::natural::RealmListChildrenRequest;
7249
7250 pub use crate::natural::RealmOpenControllerRequest;
7251
7252 pub use crate::natural::RealmOpenExposedDirRequest;
7253
7254 pub use crate::natural::RealmCreateChildResponse;
7255
7256 pub use crate::natural::RealmDestroyChildResponse;
7257
7258 pub use crate::natural::RealmGetChildOutputDictionaryResponse;
7259
7260 pub use crate::natural::RealmGetResolvedInfoResponse;
7261
7262 pub use crate::natural::RealmListChildrenResponse;
7263
7264 pub use crate::natural::RealmOpenControllerResponse;
7265
7266 pub use crate::natural::RealmOpenExposedDirResponse;
7267 }
7268
7269 pub struct OpenController;
7270
7271 impl ::fidl_next::Method for OpenController {
7272 const ORDINAL: u64 = 8165227925828473216;
7273 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
7274 ::fidl_next::protocol::Flexibility::Strict;
7275
7276 type Protocol = crate::Realm;
7277
7278 type Request = crate::wire::RealmOpenControllerRequest<'static>;
7279 }
7280
7281 impl ::fidl_next::TwoWayMethod for OpenController {
7282 type Response = ::fidl_next::WireResult<
7283 'static,
7284 crate::wire::RealmOpenControllerResponse,
7285 crate::wire::Error,
7286 >;
7287 }
7288
7289 impl<___R> ::fidl_next::Respond<___R> for OpenController {
7290 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
7291
7292 fn respond(response: ___R) -> Self::Output {
7293 ::core::result::Result::Ok(response)
7294 }
7295 }
7296
7297 impl<___R> ::fidl_next::RespondErr<___R> for OpenController {
7298 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
7299
7300 fn respond_err(response: ___R) -> Self::Output {
7301 ::core::result::Result::Err(response)
7302 }
7303 }
7304
7305 pub struct OpenExposedDir;
7306
7307 impl ::fidl_next::Method for OpenExposedDir {
7308 const ORDINAL: u64 = 9194435320863127852;
7309 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
7310 ::fidl_next::protocol::Flexibility::Strict;
7311
7312 type Protocol = crate::Realm;
7313
7314 type Request = crate::wire::RealmOpenExposedDirRequest<'static>;
7315 }
7316
7317 impl ::fidl_next::TwoWayMethod for OpenExposedDir {
7318 type Response = ::fidl_next::WireResult<
7319 'static,
7320 crate::wire::RealmOpenExposedDirResponse,
7321 crate::wire::Error,
7322 >;
7323 }
7324
7325 impl<___R> ::fidl_next::Respond<___R> for OpenExposedDir {
7326 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
7327
7328 fn respond(response: ___R) -> Self::Output {
7329 ::core::result::Result::Ok(response)
7330 }
7331 }
7332
7333 impl<___R> ::fidl_next::RespondErr<___R> for OpenExposedDir {
7334 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
7335
7336 fn respond_err(response: ___R) -> Self::Output {
7337 ::core::result::Result::Err(response)
7338 }
7339 }
7340
7341 pub struct CreateChild;
7342
7343 impl ::fidl_next::Method for CreateChild {
7344 const ORDINAL: u64 = 4892190024503489888;
7345 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
7346 ::fidl_next::protocol::Flexibility::Strict;
7347
7348 type Protocol = crate::Realm;
7349
7350 type Request = crate::wire::RealmCreateChildRequest<'static>;
7351 }
7352
7353 impl ::fidl_next::TwoWayMethod for CreateChild {
7354 type Response = ::fidl_next::WireResult<
7355 'static,
7356 crate::wire::RealmCreateChildResponse,
7357 crate::wire::Error,
7358 >;
7359 }
7360
7361 impl<___R> ::fidl_next::Respond<___R> for CreateChild {
7362 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
7363
7364 fn respond(response: ___R) -> Self::Output {
7365 ::core::result::Result::Ok(response)
7366 }
7367 }
7368
7369 impl<___R> ::fidl_next::RespondErr<___R> for CreateChild {
7370 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
7371
7372 fn respond_err(response: ___R) -> Self::Output {
7373 ::core::result::Result::Err(response)
7374 }
7375 }
7376
7377 pub struct DestroyChild;
7378
7379 impl ::fidl_next::Method for DestroyChild {
7380 const ORDINAL: u64 = 8203529889988252194;
7381 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
7382 ::fidl_next::protocol::Flexibility::Strict;
7383
7384 type Protocol = crate::Realm;
7385
7386 type Request = crate::wire::RealmDestroyChildRequest<'static>;
7387 }
7388
7389 impl ::fidl_next::TwoWayMethod for DestroyChild {
7390 type Response = ::fidl_next::WireResult<
7391 'static,
7392 crate::wire::RealmDestroyChildResponse,
7393 crate::wire::Error,
7394 >;
7395 }
7396
7397 impl<___R> ::fidl_next::Respond<___R> for DestroyChild {
7398 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
7399
7400 fn respond(response: ___R) -> Self::Output {
7401 ::core::result::Result::Ok(response)
7402 }
7403 }
7404
7405 impl<___R> ::fidl_next::RespondErr<___R> for DestroyChild {
7406 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
7407
7408 fn respond_err(response: ___R) -> Self::Output {
7409 ::core::result::Result::Err(response)
7410 }
7411 }
7412
7413 pub struct ListChildren;
7414
7415 impl ::fidl_next::Method for ListChildren {
7416 const ORDINAL: u64 = 7532454435519185057;
7417 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
7418 ::fidl_next::protocol::Flexibility::Strict;
7419
7420 type Protocol = crate::Realm;
7421
7422 type Request = crate::wire::RealmListChildrenRequest<'static>;
7423 }
7424
7425 impl ::fidl_next::TwoWayMethod for ListChildren {
7426 type Response = ::fidl_next::WireResult<
7427 'static,
7428 crate::wire::RealmListChildrenResponse,
7429 crate::wire::Error,
7430 >;
7431 }
7432
7433 impl<___R> ::fidl_next::Respond<___R> for ListChildren {
7434 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
7435
7436 fn respond(response: ___R) -> Self::Output {
7437 ::core::result::Result::Ok(response)
7438 }
7439 }
7440
7441 impl<___R> ::fidl_next::RespondErr<___R> for ListChildren {
7442 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
7443
7444 fn respond_err(response: ___R) -> Self::Output {
7445 ::core::result::Result::Err(response)
7446 }
7447 }
7448
7449 pub struct GetResolvedInfo;
7450
7451 impl ::fidl_next::Method for GetResolvedInfo {
7452 const ORDINAL: u64 = 8308987710372188322;
7453 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
7454 ::fidl_next::protocol::Flexibility::Strict;
7455
7456 type Protocol = crate::Realm;
7457
7458 type Request = ();
7459 }
7460
7461 impl ::fidl_next::TwoWayMethod for GetResolvedInfo {
7462 type Response = ::fidl_next::WireResult<
7463 'static,
7464 crate::wire::RealmGetResolvedInfoResponse<'static>,
7465 crate::wire::Error,
7466 >;
7467 }
7468
7469 impl<___R> ::fidl_next::Respond<___R> for GetResolvedInfo {
7470 type Output = ::core::result::Result<
7471 crate::generic::RealmGetResolvedInfoResponse<___R>,
7472 ::fidl_next::util::Never,
7473 >;
7474
7475 fn respond(response: ___R) -> Self::Output {
7476 ::core::result::Result::Ok(crate::generic::RealmGetResolvedInfoResponse {
7477 resolved_info: response,
7478 })
7479 }
7480 }
7481
7482 impl<___R> ::fidl_next::RespondErr<___R> for GetResolvedInfo {
7483 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
7484
7485 fn respond_err(response: ___R) -> Self::Output {
7486 ::core::result::Result::Err(response)
7487 }
7488 }
7489
7490 pub struct GetChildOutputDictionary;
7491
7492 impl ::fidl_next::Method for GetChildOutputDictionary {
7493 const ORDINAL: u64 = 4781081784078915088;
7494 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
7495 ::fidl_next::protocol::Flexibility::Strict;
7496
7497 type Protocol = crate::Realm;
7498
7499 type Request = crate::wire::RealmGetChildOutputDictionaryRequest<'static>;
7500 }
7501
7502 impl ::fidl_next::TwoWayMethod for GetChildOutputDictionary {
7503 type Response = ::fidl_next::WireResult<
7504 'static,
7505 crate::wire::RealmGetChildOutputDictionaryResponse,
7506 crate::wire::Error,
7507 >;
7508 }
7509
7510 impl<___R> ::fidl_next::Respond<___R> for GetChildOutputDictionary {
7511 type Output = ::core::result::Result<
7512 crate::generic::RealmGetChildOutputDictionaryResponse<___R>,
7513 ::fidl_next::util::Never,
7514 >;
7515
7516 fn respond(response: ___R) -> Self::Output {
7517 ::core::result::Result::Ok(crate::generic::RealmGetChildOutputDictionaryResponse {
7518 dictionary: response,
7519 })
7520 }
7521 }
7522
7523 impl<___R> ::fidl_next::RespondErr<___R> for GetChildOutputDictionary {
7524 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
7525
7526 fn respond_err(response: ___R) -> Self::Output {
7527 ::core::result::Result::Err(response)
7528 }
7529 }
7530
7531 mod ___detail {
7532 unsafe impl<___T> ::fidl_next::HasConnectionHandles<___T> for crate::Realm
7533 where
7534 ___T: ::fidl_next::Transport,
7535 {
7536 type Client = RealmClient<___T>;
7537 type Server = RealmServer<___T>;
7538 }
7539
7540 #[repr(transparent)]
7542 pub struct RealmClient<___T: ::fidl_next::Transport> {
7543 #[allow(dead_code)]
7544 client: ::fidl_next::protocol::Client<___T>,
7545 }
7546
7547 impl<___T> RealmClient<___T>
7548 where
7549 ___T: ::fidl_next::Transport,
7550 {
7551 #[doc = " Operate on a child component. See documentation for [`Controller`].\n\n Errors:\n - `INVALID_ARGUMENTS`: `child` is not a valid child reference.\n - `INSTANCE_NOT_FOUND`: `child` does not exist.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7552 pub fn open_controller(
7553 &self,
7554
7555 child: impl ::fidl_next::Encode<
7556 ::fidl_next_fuchsia_component_decl::wire::ChildRef<'static>,
7557 <___T as ::fidl_next::Transport>::SendBuffer,
7558 >,
7559
7560 controller: impl ::fidl_next::Encode<
7561 ::fidl_next::ServerEnd<crate::Controller, ::fidl_next::fuchsia::WireChannel>,
7562 <___T as ::fidl_next::Transport>::SendBuffer,
7563 >,
7564 ) -> ::fidl_next::TwoWayFuture<'_, super::OpenController, ___T>
7565 where
7566 <___T as ::fidl_next::Transport>::SendBuffer:
7567 ::fidl_next::encoder::InternalHandleEncoder,
7568 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
7569 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
7570 {
7571 self.open_controller_with(crate::generic::RealmOpenControllerRequest {
7572 child,
7573
7574 controller,
7575 })
7576 }
7577
7578 #[doc = " Operate on a child component. See documentation for [`Controller`].\n\n Errors:\n - `INVALID_ARGUMENTS`: `child` is not a valid child reference.\n - `INSTANCE_NOT_FOUND`: `child` does not exist.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7579 pub fn open_controller_with<___R>(
7580 &self,
7581 request: ___R,
7582 ) -> ::fidl_next::TwoWayFuture<'_, super::OpenController, ___T>
7583 where
7584 ___R: ::fidl_next::Encode<
7585 crate::wire::RealmOpenControllerRequest<'static>,
7586 <___T as ::fidl_next::Transport>::SendBuffer,
7587 >,
7588 {
7589 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
7590 8165227925828473216,
7591 <super::OpenController as ::fidl_next::Method>::FLEXIBILITY,
7592 request,
7593 ))
7594 }
7595
7596 #[doc = " Opens the exposed directory of a child component instance. When this\n function successfully returns, `exposed_dir` is bound to a directory\n that contains the capabilities which the child exposed to its realm\n via `ComponentDecl.exposes` (specified via \"expose\" declarations in\n the component\'s manifest). The child component will not start as a\n result of this call. Instead, starting will occur iff the parent binds\n to one of the capabilities contained within `exposed_dir`.\n\n `exposed_dir` is open as long as `child` exists.\n\n Errors:\n - `INVALID_ARGUMENTS`: `child` is not a valid child reference.\n - `INSTANCE_NOT_FOUND`: `child` does not exist.\n - `INSTANCE_CANNOT_RESOLVE`: `child`\'s component declaration failed to resolve.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7597 pub fn open_exposed_dir(
7598 &self,
7599
7600 child: impl ::fidl_next::Encode<
7601 ::fidl_next_fuchsia_component_decl::wire::ChildRef<'static>,
7602 <___T as ::fidl_next::Transport>::SendBuffer,
7603 >,
7604
7605 exposed_dir: impl ::fidl_next::Encode<
7606 ::fidl_next::ServerEnd<
7607 ::fidl_next_fuchsia_io::Directory,
7608 ::fidl_next::fuchsia::WireChannel,
7609 >,
7610 <___T as ::fidl_next::Transport>::SendBuffer,
7611 >,
7612 ) -> ::fidl_next::TwoWayFuture<'_, super::OpenExposedDir, ___T>
7613 where
7614 <___T as ::fidl_next::Transport>::SendBuffer:
7615 ::fidl_next::encoder::InternalHandleEncoder,
7616 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
7617 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
7618 {
7619 self.open_exposed_dir_with(crate::generic::RealmOpenExposedDirRequest {
7620 child,
7621
7622 exposed_dir,
7623 })
7624 }
7625
7626 #[doc = " Opens the exposed directory of a child component instance. When this\n function successfully returns, `exposed_dir` is bound to a directory\n that contains the capabilities which the child exposed to its realm\n via `ComponentDecl.exposes` (specified via \"expose\" declarations in\n the component\'s manifest). The child component will not start as a\n result of this call. Instead, starting will occur iff the parent binds\n to one of the capabilities contained within `exposed_dir`.\n\n `exposed_dir` is open as long as `child` exists.\n\n Errors:\n - `INVALID_ARGUMENTS`: `child` is not a valid child reference.\n - `INSTANCE_NOT_FOUND`: `child` does not exist.\n - `INSTANCE_CANNOT_RESOLVE`: `child`\'s component declaration failed to resolve.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7627 pub fn open_exposed_dir_with<___R>(
7628 &self,
7629 request: ___R,
7630 ) -> ::fidl_next::TwoWayFuture<'_, super::OpenExposedDir, ___T>
7631 where
7632 ___R: ::fidl_next::Encode<
7633 crate::wire::RealmOpenExposedDirRequest<'static>,
7634 <___T as ::fidl_next::Transport>::SendBuffer,
7635 >,
7636 {
7637 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
7638 9194435320863127852,
7639 <super::OpenExposedDir as ::fidl_next::Method>::FLEXIBILITY,
7640 request,
7641 ))
7642 }
7643
7644 #[doc = " Creates a child component instance dynamically. When this function\n returns successfully, the instance exists, but it may not be running.\n\n The environment of the child instance is determined by the environment\n of the collection. `decl` must not set `environment`.\n\n If `decl.startup == EAGER`, or `collection.durability == SINGLE_RUN`,\n [CreateChild] will start the component and return once the component is\n started. Otherwise, [CreateChild] will return immediately after creating\n the component and will not start or resolve it.\n\n Errors:\n - `INVALID_ARGUMENTS`: `collection` is not a valid reference or `child`\n is not a valid declaration.\n - `COLLECTION_NOT_FOUND`: `collection` does not exist.\n - `INSTANCE_ALREADY_EXISTS`: `decl.name` already exists in `collection`.\n - `INSTANCE_CANNOT_RESOLVE`: `child`\'s component declaration failed to resolve\n in a `SingleRun` collection.\n - `NO_SPACE`: Could not allocate storage for the new instance.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7645 pub fn create_child(
7646 &self,
7647
7648 collection: impl ::fidl_next::Encode<
7649 ::fidl_next_fuchsia_component_decl::wire::CollectionRef<'static>,
7650 <___T as ::fidl_next::Transport>::SendBuffer,
7651 >,
7652
7653 decl: impl ::fidl_next::Encode<
7654 ::fidl_next_fuchsia_component_decl::wire::Child<'static>,
7655 <___T as ::fidl_next::Transport>::SendBuffer,
7656 >,
7657
7658 args: impl ::fidl_next::Encode<
7659 crate::wire::CreateChildArgs<'static>,
7660 <___T as ::fidl_next::Transport>::SendBuffer,
7661 >,
7662 ) -> ::fidl_next::TwoWayFuture<'_, super::CreateChild, ___T>
7663 where
7664 <___T as ::fidl_next::Transport>::SendBuffer:
7665 ::fidl_next::encoder::InternalHandleEncoder,
7666 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
7667 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
7668 {
7669 self.create_child_with(crate::generic::RealmCreateChildRequest {
7670 collection,
7671
7672 decl,
7673
7674 args,
7675 })
7676 }
7677
7678 #[doc = " Creates a child component instance dynamically. When this function\n returns successfully, the instance exists, but it may not be running.\n\n The environment of the child instance is determined by the environment\n of the collection. `decl` must not set `environment`.\n\n If `decl.startup == EAGER`, or `collection.durability == SINGLE_RUN`,\n [CreateChild] will start the component and return once the component is\n started. Otherwise, [CreateChild] will return immediately after creating\n the component and will not start or resolve it.\n\n Errors:\n - `INVALID_ARGUMENTS`: `collection` is not a valid reference or `child`\n is not a valid declaration.\n - `COLLECTION_NOT_FOUND`: `collection` does not exist.\n - `INSTANCE_ALREADY_EXISTS`: `decl.name` already exists in `collection`.\n - `INSTANCE_CANNOT_RESOLVE`: `child`\'s component declaration failed to resolve\n in a `SingleRun` collection.\n - `NO_SPACE`: Could not allocate storage for the new instance.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7679 pub fn create_child_with<___R>(
7680 &self,
7681 request: ___R,
7682 ) -> ::fidl_next::TwoWayFuture<'_, super::CreateChild, ___T>
7683 where
7684 ___R: ::fidl_next::Encode<
7685 crate::wire::RealmCreateChildRequest<'static>,
7686 <___T as ::fidl_next::Transport>::SendBuffer,
7687 >,
7688 {
7689 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
7690 4892190024503489888,
7691 <super::CreateChild as ::fidl_next::Method>::FLEXIBILITY,
7692 request,
7693 ))
7694 }
7695
7696 #[doc = " Destroys a dynamically-created component instance. When this function\n returns, the instance is destroyed and has stopped running. However,\n cleanup of the component\'s resources (such as its isolated storage) may\n happen in the background after this function returns.\n\n Errors:\n - `INVALID_ARGUMENTS`: `child` is not a valid reference or does not refer\n to a dynamic instance.\n - `INSTANCE_NOT_FOUND`: `child` does not exist.\n - `COLLECTION_NOT_FOUND`: `collection` does not exist.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7697 pub fn destroy_child(
7698 &self,
7699
7700 child: impl ::fidl_next::Encode<
7701 ::fidl_next_fuchsia_component_decl::wire::ChildRef<'static>,
7702 <___T as ::fidl_next::Transport>::SendBuffer,
7703 >,
7704 ) -> ::fidl_next::TwoWayFuture<'_, super::DestroyChild, ___T>
7705 where
7706 <___T as ::fidl_next::Transport>::SendBuffer:
7707 ::fidl_next::encoder::InternalHandleEncoder,
7708 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
7709 {
7710 self.destroy_child_with(crate::generic::RealmDestroyChildRequest { child })
7711 }
7712
7713 #[doc = " Destroys a dynamically-created component instance. When this function\n returns, the instance is destroyed and has stopped running. However,\n cleanup of the component\'s resources (such as its isolated storage) may\n happen in the background after this function returns.\n\n Errors:\n - `INVALID_ARGUMENTS`: `child` is not a valid reference or does not refer\n to a dynamic instance.\n - `INSTANCE_NOT_FOUND`: `child` does not exist.\n - `COLLECTION_NOT_FOUND`: `collection` does not exist.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7714 pub fn destroy_child_with<___R>(
7715 &self,
7716 request: ___R,
7717 ) -> ::fidl_next::TwoWayFuture<'_, super::DestroyChild, ___T>
7718 where
7719 ___R: ::fidl_next::Encode<
7720 crate::wire::RealmDestroyChildRequest<'static>,
7721 <___T as ::fidl_next::Transport>::SendBuffer,
7722 >,
7723 {
7724 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
7725 8203529889988252194,
7726 <super::DestroyChild as ::fidl_next::Method>::FLEXIBILITY,
7727 request,
7728 ))
7729 }
7730
7731 #[doc = " Returns an iterator that lists all instances in a collection.\n\n NOTE: The results are not guaranteed to be consistent. Instances may be\n created or destroyed while the iterator is live, but those changes\n won\'t be observed by the iterator after this method returns.\n\n Errors:\n - `INVALID_ARGUMENTS`: `collection` is not a valid reference or `iter`\n does not have `ZX_RIGHT_WAIT`.\n - `COLLECTION_NOT_FOUND`: `collection` does not exist.\n - `INSTANCE_DIED`: This realm no longer exists.\n - If `iter` does not have standard channel rights, this function may\n return `ACCESS_DENIED` or component manager may close `iter`.\n"]
7732 pub fn list_children(
7733 &self,
7734
7735 collection: impl ::fidl_next::Encode<
7736 ::fidl_next_fuchsia_component_decl::wire::CollectionRef<'static>,
7737 <___T as ::fidl_next::Transport>::SendBuffer,
7738 >,
7739
7740 iter: impl ::fidl_next::Encode<
7741 ::fidl_next::ServerEnd<crate::ChildIterator, ::fidl_next::fuchsia::WireChannel>,
7742 <___T as ::fidl_next::Transport>::SendBuffer,
7743 >,
7744 ) -> ::fidl_next::TwoWayFuture<'_, super::ListChildren, ___T>
7745 where
7746 <___T as ::fidl_next::Transport>::SendBuffer:
7747 ::fidl_next::encoder::InternalHandleEncoder,
7748 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
7749 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
7750 {
7751 self.list_children_with(crate::generic::RealmListChildrenRequest {
7752 collection,
7753
7754 iter,
7755 })
7756 }
7757
7758 #[doc = " Returns an iterator that lists all instances in a collection.\n\n NOTE: The results are not guaranteed to be consistent. Instances may be\n created or destroyed while the iterator is live, but those changes\n won\'t be observed by the iterator after this method returns.\n\n Errors:\n - `INVALID_ARGUMENTS`: `collection` is not a valid reference or `iter`\n does not have `ZX_RIGHT_WAIT`.\n - `COLLECTION_NOT_FOUND`: `collection` does not exist.\n - `INSTANCE_DIED`: This realm no longer exists.\n - If `iter` does not have standard channel rights, this function may\n return `ACCESS_DENIED` or component manager may close `iter`.\n"]
7759 pub fn list_children_with<___R>(
7760 &self,
7761 request: ___R,
7762 ) -> ::fidl_next::TwoWayFuture<'_, super::ListChildren, ___T>
7763 where
7764 ___R: ::fidl_next::Encode<
7765 crate::wire::RealmListChildrenRequest<'static>,
7766 <___T as ::fidl_next::Transport>::SendBuffer,
7767 >,
7768 {
7769 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
7770 7532454435519185057,
7771 <super::ListChildren as ::fidl_next::Method>::FLEXIBILITY,
7772 request,
7773 ))
7774 }
7775
7776 #[doc = " Returns the set of information that was given to the component framework\n by this component\'s resolver.\n"]
7777 pub fn get_resolved_info(
7778 &self,
7779 ) -> ::fidl_next::TwoWayFuture<'_, super::GetResolvedInfo, ___T> {
7780 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
7781 8308987710372188322,
7782 <super::GetResolvedInfo as ::fidl_next::Method>::FLEXIBILITY,
7783 (),
7784 ))
7785 }
7786
7787 pub fn get_child_output_dictionary(
7788 &self,
7789
7790 child: impl ::fidl_next::Encode<
7791 ::fidl_next_fuchsia_component_decl::wire::ChildRef<'static>,
7792 <___T as ::fidl_next::Transport>::SendBuffer,
7793 >,
7794 ) -> ::fidl_next::TwoWayFuture<'_, super::GetChildOutputDictionary, ___T>
7795 where
7796 <___T as ::fidl_next::Transport>::SendBuffer:
7797 ::fidl_next::encoder::InternalHandleEncoder,
7798 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
7799 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
7800 {
7801 self.get_child_output_dictionary_with(
7802 crate::generic::RealmGetChildOutputDictionaryRequest { child },
7803 )
7804 }
7805
7806 pub fn get_child_output_dictionary_with<___R>(
7807 &self,
7808 request: ___R,
7809 ) -> ::fidl_next::TwoWayFuture<'_, super::GetChildOutputDictionary, ___T>
7810 where
7811 ___R: ::fidl_next::Encode<
7812 crate::wire::RealmGetChildOutputDictionaryRequest<'static>,
7813 <___T as ::fidl_next::Transport>::SendBuffer,
7814 >,
7815 {
7816 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
7817 4781081784078915088,
7818 <super::GetChildOutputDictionary as ::fidl_next::Method>::FLEXIBILITY,
7819 request,
7820 ))
7821 }
7822 }
7823
7824 #[repr(transparent)]
7826 pub struct RealmServer<___T: ::fidl_next::Transport> {
7827 server: ::fidl_next::protocol::Server<___T>,
7828 }
7829
7830 impl<___T> RealmServer<___T> where ___T: ::fidl_next::Transport {}
7831 }
7832}
7833
7834pub trait RealmClientHandler<
7838 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
7839 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
7840>
7841{
7842}
7843
7844impl<___T> RealmClientHandler<___T> for ::fidl_next::IgnoreEvents where ___T: ::fidl_next::Transport {}
7845
7846impl<___H, ___T> ::fidl_next::DispatchClientMessage<___H, ___T> for Realm
7847where
7848 ___H: RealmClientHandler<___T> + ::core::marker::Send,
7849 ___T: ::fidl_next::Transport,
7850{
7851 async fn on_event(
7852 handler: &mut ___H,
7853 ordinal: u64,
7854 flexibility: ::fidl_next::protocol::Flexibility,
7855 buffer: ___T::RecvBuffer,
7856 ) -> ::core::result::Result<(), ::fidl_next::ProtocolError<___T::Error>> {
7857 match ordinal {
7858 ordinal => Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal)),
7859 }
7860 }
7861}
7862
7863pub trait RealmServerHandler<
7867 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
7868 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
7869>
7870{
7871 #[doc = " Operate on a child component. See documentation for [`Controller`].\n\n Errors:\n - `INVALID_ARGUMENTS`: `child` is not a valid child reference.\n - `INSTANCE_NOT_FOUND`: `child` does not exist.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7872 fn open_controller(
7873 &mut self,
7874
7875 request: ::fidl_next::Request<realm::OpenController, ___T>,
7876
7877 responder: ::fidl_next::Responder<realm::OpenController, ___T>,
7878 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
7879
7880 #[doc = " Opens the exposed directory of a child component instance. When this\n function successfully returns, `exposed_dir` is bound to a directory\n that contains the capabilities which the child exposed to its realm\n via `ComponentDecl.exposes` (specified via \"expose\" declarations in\n the component\'s manifest). The child component will not start as a\n result of this call. Instead, starting will occur iff the parent binds\n to one of the capabilities contained within `exposed_dir`.\n\n `exposed_dir` is open as long as `child` exists.\n\n Errors:\n - `INVALID_ARGUMENTS`: `child` is not a valid child reference.\n - `INSTANCE_NOT_FOUND`: `child` does not exist.\n - `INSTANCE_CANNOT_RESOLVE`: `child`\'s component declaration failed to resolve.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7881 fn open_exposed_dir(
7882 &mut self,
7883
7884 request: ::fidl_next::Request<realm::OpenExposedDir, ___T>,
7885
7886 responder: ::fidl_next::Responder<realm::OpenExposedDir, ___T>,
7887 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
7888
7889 #[doc = " Creates a child component instance dynamically. When this function\n returns successfully, the instance exists, but it may not be running.\n\n The environment of the child instance is determined by the environment\n of the collection. `decl` must not set `environment`.\n\n If `decl.startup == EAGER`, or `collection.durability == SINGLE_RUN`,\n [CreateChild] will start the component and return once the component is\n started. Otherwise, [CreateChild] will return immediately after creating\n the component and will not start or resolve it.\n\n Errors:\n - `INVALID_ARGUMENTS`: `collection` is not a valid reference or `child`\n is not a valid declaration.\n - `COLLECTION_NOT_FOUND`: `collection` does not exist.\n - `INSTANCE_ALREADY_EXISTS`: `decl.name` already exists in `collection`.\n - `INSTANCE_CANNOT_RESOLVE`: `child`\'s component declaration failed to resolve\n in a `SingleRun` collection.\n - `NO_SPACE`: Could not allocate storage for the new instance.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7890 fn create_child(
7891 &mut self,
7892
7893 request: ::fidl_next::Request<realm::CreateChild, ___T>,
7894
7895 responder: ::fidl_next::Responder<realm::CreateChild, ___T>,
7896 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
7897
7898 #[doc = " Destroys a dynamically-created component instance. When this function\n returns, the instance is destroyed and has stopped running. However,\n cleanup of the component\'s resources (such as its isolated storage) may\n happen in the background after this function returns.\n\n Errors:\n - `INVALID_ARGUMENTS`: `child` is not a valid reference or does not refer\n to a dynamic instance.\n - `INSTANCE_NOT_FOUND`: `child` does not exist.\n - `COLLECTION_NOT_FOUND`: `collection` does not exist.\n - `INSTANCE_DIED`: This realm no longer exists.\n"]
7899 fn destroy_child(
7900 &mut self,
7901
7902 request: ::fidl_next::Request<realm::DestroyChild, ___T>,
7903
7904 responder: ::fidl_next::Responder<realm::DestroyChild, ___T>,
7905 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
7906
7907 #[doc = " Returns an iterator that lists all instances in a collection.\n\n NOTE: The results are not guaranteed to be consistent. Instances may be\n created or destroyed while the iterator is live, but those changes\n won\'t be observed by the iterator after this method returns.\n\n Errors:\n - `INVALID_ARGUMENTS`: `collection` is not a valid reference or `iter`\n does not have `ZX_RIGHT_WAIT`.\n - `COLLECTION_NOT_FOUND`: `collection` does not exist.\n - `INSTANCE_DIED`: This realm no longer exists.\n - If `iter` does not have standard channel rights, this function may\n return `ACCESS_DENIED` or component manager may close `iter`.\n"]
7908 fn list_children(
7909 &mut self,
7910
7911 request: ::fidl_next::Request<realm::ListChildren, ___T>,
7912
7913 responder: ::fidl_next::Responder<realm::ListChildren, ___T>,
7914 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
7915
7916 #[doc = " Returns the set of information that was given to the component framework\n by this component\'s resolver.\n"]
7917 fn get_resolved_info(
7918 &mut self,
7919
7920 responder: ::fidl_next::Responder<realm::GetResolvedInfo, ___T>,
7921 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
7922
7923 fn get_child_output_dictionary(
7924 &mut self,
7925
7926 request: ::fidl_next::Request<realm::GetChildOutputDictionary, ___T>,
7927
7928 responder: ::fidl_next::Responder<realm::GetChildOutputDictionary, ___T>,
7929 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
7930}
7931
7932impl<___H, ___T> ::fidl_next::DispatchServerMessage<___H, ___T> for Realm
7933where
7934 ___H: RealmServerHandler<___T> + ::core::marker::Send,
7935 ___T: ::fidl_next::Transport,
7936 <realm::OpenController as ::fidl_next::Method>::Request:
7937 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
7938 <realm::OpenExposedDir as ::fidl_next::Method>::Request:
7939 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
7940 <realm::CreateChild as ::fidl_next::Method>::Request:
7941 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
7942 <realm::DestroyChild as ::fidl_next::Method>::Request:
7943 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
7944 <realm::ListChildren as ::fidl_next::Method>::Request:
7945 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
7946 <realm::GetChildOutputDictionary as ::fidl_next::Method>::Request:
7947 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
7948{
7949 async fn on_one_way(
7950 handler: &mut ___H,
7951 ordinal: u64,
7952 flexibility: ::fidl_next::protocol::Flexibility,
7953 buffer: ___T::RecvBuffer,
7954 ) -> ::core::result::Result<
7955 (),
7956 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
7957 > {
7958 match ordinal {
7959 ordinal => Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal)),
7960 }
7961 }
7962
7963 async fn on_two_way(
7964 handler: &mut ___H,
7965 ordinal: u64,
7966 flexibility: ::fidl_next::protocol::Flexibility,
7967 buffer: ___T::RecvBuffer,
7968 responder: ::fidl_next::protocol::Responder<___T>,
7969 ) -> ::core::result::Result<
7970 (),
7971 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
7972 > {
7973 match ordinal {
7974 8165227925828473216 => {
7975 let responder = ::fidl_next::Responder::from_untyped(responder);
7976
7977 match ::fidl_next::DecoderExt::decode(buffer) {
7978 Ok(decoded) => {
7979 handler
7980 .open_controller(::fidl_next::Request::from_decoded(decoded), responder)
7981 .await;
7982 Ok(())
7983 }
7984 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
7985 ordinal: 8165227925828473216,
7986 error,
7987 }),
7988 }
7989 }
7990
7991 9194435320863127852 => {
7992 let responder = ::fidl_next::Responder::from_untyped(responder);
7993
7994 match ::fidl_next::DecoderExt::decode(buffer) {
7995 Ok(decoded) => {
7996 handler
7997 .open_exposed_dir(
7998 ::fidl_next::Request::from_decoded(decoded),
7999 responder,
8000 )
8001 .await;
8002 Ok(())
8003 }
8004 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
8005 ordinal: 9194435320863127852,
8006 error,
8007 }),
8008 }
8009 }
8010
8011 4892190024503489888 => {
8012 let responder = ::fidl_next::Responder::from_untyped(responder);
8013
8014 match ::fidl_next::DecoderExt::decode(buffer) {
8015 Ok(decoded) => {
8016 handler
8017 .create_child(::fidl_next::Request::from_decoded(decoded), responder)
8018 .await;
8019 Ok(())
8020 }
8021 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
8022 ordinal: 4892190024503489888,
8023 error,
8024 }),
8025 }
8026 }
8027
8028 8203529889988252194 => {
8029 let responder = ::fidl_next::Responder::from_untyped(responder);
8030
8031 match ::fidl_next::DecoderExt::decode(buffer) {
8032 Ok(decoded) => {
8033 handler
8034 .destroy_child(::fidl_next::Request::from_decoded(decoded), responder)
8035 .await;
8036 Ok(())
8037 }
8038 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
8039 ordinal: 8203529889988252194,
8040 error,
8041 }),
8042 }
8043 }
8044
8045 7532454435519185057 => {
8046 let responder = ::fidl_next::Responder::from_untyped(responder);
8047
8048 match ::fidl_next::DecoderExt::decode(buffer) {
8049 Ok(decoded) => {
8050 handler
8051 .list_children(::fidl_next::Request::from_decoded(decoded), responder)
8052 .await;
8053 Ok(())
8054 }
8055 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
8056 ordinal: 7532454435519185057,
8057 error,
8058 }),
8059 }
8060 }
8061
8062 8308987710372188322 => {
8063 let responder = ::fidl_next::Responder::from_untyped(responder);
8064
8065 handler.get_resolved_info(responder).await;
8066 Ok(())
8067 }
8068
8069 4781081784078915088 => {
8070 let responder = ::fidl_next::Responder::from_untyped(responder);
8071
8072 match ::fidl_next::DecoderExt::decode(buffer) {
8073 Ok(decoded) => {
8074 handler
8075 .get_child_output_dictionary(
8076 ::fidl_next::Request::from_decoded(decoded),
8077 responder,
8078 )
8079 .await;
8080 Ok(())
8081 }
8082 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
8083 ordinal: 4781081784078915088,
8084 error,
8085 }),
8086 }
8087 }
8088
8089 ordinal => Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal)),
8090 }
8091 }
8092}
8093
8094#[derive(PartialEq, Debug)]
8096pub struct StorageAdmin;
8097
8098impl ::fidl_next::Discoverable for StorageAdmin {
8099 const PROTOCOL_NAME: &'static str = "fuchsia.component.StorageAdmin";
8100}
8101
8102#[cfg(target_os = "fuchsia")]
8103impl ::fidl_next::HasTransport for StorageAdmin {
8104 type Transport = ::fidl_next::fuchsia::zx::Channel;
8105}
8106
8107pub mod storage_admin {
8108 pub mod prelude {
8109 pub use crate::{
8110 StorageAdmin, StorageAdminClientHandler, StorageAdminServerHandler, storage_admin,
8111 };
8112
8113 pub use crate::natural::DeletionError;
8114
8115 pub use crate::natural::Error;
8116
8117 pub use crate::natural::StatusError;
8118
8119 pub use crate::natural::StorageAdminDeleteComponentStorageRequest;
8120
8121 pub use crate::natural::StorageAdminListStorageInRealmRequest;
8122
8123 pub use crate::natural::StorageAdminOpenComponentStorageByIdRequest;
8124
8125 pub use crate::natural::StorageAdminOpenStorageRequest;
8126
8127 pub use crate::natural::StorageAdminDeleteAllStorageContentsResponse;
8128
8129 pub use crate::natural::StorageAdminDeleteComponentStorageResponse;
8130
8131 pub use crate::natural::StorageAdminListStorageInRealmResponse;
8132
8133 pub use crate::natural::StorageAdminOpenComponentStorageByIdResponse;
8134
8135 pub use crate::natural::StorageAdminOpenStorageResponse;
8136
8137 pub use crate::natural::StorageStatus;
8138 }
8139
8140 pub struct OpenStorage;
8141
8142 impl ::fidl_next::Method for OpenStorage {
8143 const ORDINAL: u64 = 7848267339832116087;
8144 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
8145 ::fidl_next::protocol::Flexibility::Strict;
8146
8147 type Protocol = crate::StorageAdmin;
8148
8149 type Request = crate::wire::StorageAdminOpenStorageRequest<'static>;
8150 }
8151
8152 impl ::fidl_next::TwoWayMethod for OpenStorage {
8153 type Response = ::fidl_next::WireResult<
8154 'static,
8155 crate::wire::StorageAdminOpenStorageResponse,
8156 crate::wire::Error,
8157 >;
8158 }
8159
8160 impl<___R> ::fidl_next::Respond<___R> for OpenStorage {
8161 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
8162
8163 fn respond(response: ___R) -> Self::Output {
8164 ::core::result::Result::Ok(response)
8165 }
8166 }
8167
8168 impl<___R> ::fidl_next::RespondErr<___R> for OpenStorage {
8169 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
8170
8171 fn respond_err(response: ___R) -> Self::Output {
8172 ::core::result::Result::Err(response)
8173 }
8174 }
8175
8176 pub struct ListStorageInRealm;
8177
8178 impl ::fidl_next::Method for ListStorageInRealm {
8179 const ORDINAL: u64 = 8525152599685368827;
8180 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
8181 ::fidl_next::protocol::Flexibility::Strict;
8182
8183 type Protocol = crate::StorageAdmin;
8184
8185 type Request = crate::wire::StorageAdminListStorageInRealmRequest<'static>;
8186 }
8187
8188 impl ::fidl_next::TwoWayMethod for ListStorageInRealm {
8189 type Response = ::fidl_next::WireResult<
8190 'static,
8191 crate::wire::StorageAdminListStorageInRealmResponse,
8192 crate::wire::Error,
8193 >;
8194 }
8195
8196 impl<___R> ::fidl_next::Respond<___R> for ListStorageInRealm {
8197 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
8198
8199 fn respond(response: ___R) -> Self::Output {
8200 ::core::result::Result::Ok(response)
8201 }
8202 }
8203
8204 impl<___R> ::fidl_next::RespondErr<___R> for ListStorageInRealm {
8205 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
8206
8207 fn respond_err(response: ___R) -> Self::Output {
8208 ::core::result::Result::Err(response)
8209 }
8210 }
8211
8212 pub struct OpenComponentStorageById;
8213
8214 impl ::fidl_next::Method for OpenComponentStorageById {
8215 const ORDINAL: u64 = 5188727505160068593;
8216 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
8217 ::fidl_next::protocol::Flexibility::Strict;
8218
8219 type Protocol = crate::StorageAdmin;
8220
8221 type Request = crate::wire::StorageAdminOpenComponentStorageByIdRequest<'static>;
8222 }
8223
8224 impl ::fidl_next::TwoWayMethod for OpenComponentStorageById {
8225 type Response = ::fidl_next::WireResult<
8226 'static,
8227 crate::wire::StorageAdminOpenComponentStorageByIdResponse,
8228 crate::wire::Error,
8229 >;
8230 }
8231
8232 impl<___R> ::fidl_next::Respond<___R> for OpenComponentStorageById {
8233 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
8234
8235 fn respond(response: ___R) -> Self::Output {
8236 ::core::result::Result::Ok(response)
8237 }
8238 }
8239
8240 impl<___R> ::fidl_next::RespondErr<___R> for OpenComponentStorageById {
8241 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
8242
8243 fn respond_err(response: ___R) -> Self::Output {
8244 ::core::result::Result::Err(response)
8245 }
8246 }
8247
8248 pub struct DeleteComponentStorage;
8249
8250 impl ::fidl_next::Method for DeleteComponentStorage {
8251 const ORDINAL: u64 = 1618975681517712474;
8252 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
8253 ::fidl_next::protocol::Flexibility::Strict;
8254
8255 type Protocol = crate::StorageAdmin;
8256
8257 type Request = crate::wire::StorageAdminDeleteComponentStorageRequest<'static>;
8258 }
8259
8260 impl ::fidl_next::TwoWayMethod for DeleteComponentStorage {
8261 type Response = ::fidl_next::WireResult<
8262 'static,
8263 crate::wire::StorageAdminDeleteComponentStorageResponse,
8264 crate::wire::Error,
8265 >;
8266 }
8267
8268 impl<___R> ::fidl_next::Respond<___R> for DeleteComponentStorage {
8269 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
8270
8271 fn respond(response: ___R) -> Self::Output {
8272 ::core::result::Result::Ok(response)
8273 }
8274 }
8275
8276 impl<___R> ::fidl_next::RespondErr<___R> for DeleteComponentStorage {
8277 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
8278
8279 fn respond_err(response: ___R) -> Self::Output {
8280 ::core::result::Result::Err(response)
8281 }
8282 }
8283
8284 pub struct GetStatus;
8285
8286 impl ::fidl_next::Method for GetStatus {
8287 const ORDINAL: u64 = 8586643915409794760;
8288 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
8289 ::fidl_next::protocol::Flexibility::Strict;
8290
8291 type Protocol = crate::StorageAdmin;
8292
8293 type Request = ();
8294 }
8295
8296 impl ::fidl_next::TwoWayMethod for GetStatus {
8297 type Response = ::fidl_next::WireResult<
8298 'static,
8299 crate::wire::StorageStatus<'static>,
8300 crate::wire::StatusError,
8301 >;
8302 }
8303
8304 impl<___R> ::fidl_next::Respond<___R> for GetStatus {
8305 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
8306
8307 fn respond(response: ___R) -> Self::Output {
8308 ::core::result::Result::Ok(response)
8309 }
8310 }
8311
8312 impl<___R> ::fidl_next::RespondErr<___R> for GetStatus {
8313 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
8314
8315 fn respond_err(response: ___R) -> Self::Output {
8316 ::core::result::Result::Err(response)
8317 }
8318 }
8319
8320 pub struct DeleteAllStorageContents;
8321
8322 impl ::fidl_next::Method for DeleteAllStorageContents {
8323 const ORDINAL: u64 = 3380374508900862683;
8324 const FLEXIBILITY: ::fidl_next::protocol::Flexibility =
8325 ::fidl_next::protocol::Flexibility::Strict;
8326
8327 type Protocol = crate::StorageAdmin;
8328
8329 type Request = ();
8330 }
8331
8332 impl ::fidl_next::TwoWayMethod for DeleteAllStorageContents {
8333 type Response = ::fidl_next::WireResult<
8334 'static,
8335 crate::wire::StorageAdminDeleteAllStorageContentsResponse,
8336 crate::wire::DeletionError,
8337 >;
8338 }
8339
8340 impl<___R> ::fidl_next::Respond<___R> for DeleteAllStorageContents {
8341 type Output = ::core::result::Result<___R, ::fidl_next::util::Never>;
8342
8343 fn respond(response: ___R) -> Self::Output {
8344 ::core::result::Result::Ok(response)
8345 }
8346 }
8347
8348 impl<___R> ::fidl_next::RespondErr<___R> for DeleteAllStorageContents {
8349 type Output = ::core::result::Result<::fidl_next::util::Never, ___R>;
8350
8351 fn respond_err(response: ___R) -> Self::Output {
8352 ::core::result::Result::Err(response)
8353 }
8354 }
8355
8356 mod ___detail {
8357 unsafe impl<___T> ::fidl_next::HasConnectionHandles<___T> for crate::StorageAdmin
8358 where
8359 ___T: ::fidl_next::Transport,
8360 {
8361 type Client = StorageAdminClient<___T>;
8362 type Server = StorageAdminServer<___T>;
8363 }
8364
8365 #[repr(transparent)]
8367 pub struct StorageAdminClient<___T: ::fidl_next::Transport> {
8368 #[allow(dead_code)]
8369 client: ::fidl_next::protocol::Client<___T>,
8370 }
8371
8372 impl<___T> StorageAdminClient<___T>
8373 where
8374 ___T: ::fidl_next::Transport,
8375 {
8376 #[doc = " Opens the isolated directory for the given component. The provided\n moniker is relative to the component that declares the storage\n capability. Creates the backing sub-directory for this storage if it\n hasn\'t yet been created.\n"]
8377 pub fn open_storage(
8378 &self,
8379
8380 relative_moniker: impl ::fidl_next::Encode<
8381 ::fidl_next::WireString<'static>,
8382 <___T as ::fidl_next::Transport>::SendBuffer,
8383 >,
8384
8385 object: impl ::fidl_next::Encode<
8386 ::fidl_next::ServerEnd<
8387 ::fidl_next_fuchsia_io::Node,
8388 ::fidl_next::fuchsia::WireChannel,
8389 >,
8390 <___T as ::fidl_next::Transport>::SendBuffer,
8391 >,
8392 ) -> ::fidl_next::TwoWayFuture<'_, super::OpenStorage, ___T>
8393 where
8394 <___T as ::fidl_next::Transport>::SendBuffer:
8395 ::fidl_next::encoder::InternalHandleEncoder,
8396 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
8397 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
8398 {
8399 self.open_storage_with(crate::generic::StorageAdminOpenStorageRequest {
8400 relative_moniker,
8401
8402 object,
8403 })
8404 }
8405
8406 #[doc = " Opens the isolated directory for the given component. The provided\n moniker is relative to the component that declares the storage\n capability. Creates the backing sub-directory for this storage if it\n hasn\'t yet been created.\n"]
8407 pub fn open_storage_with<___R>(
8408 &self,
8409 request: ___R,
8410 ) -> ::fidl_next::TwoWayFuture<'_, super::OpenStorage, ___T>
8411 where
8412 ___R: ::fidl_next::Encode<
8413 crate::wire::StorageAdminOpenStorageRequest<'static>,
8414 <___T as ::fidl_next::Transport>::SendBuffer,
8415 >,
8416 {
8417 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
8418 7848267339832116087,
8419 <super::OpenStorage as ::fidl_next::Method>::FLEXIBILITY,
8420 request,
8421 ))
8422 }
8423
8424 #[doc = " Lists the descendant components under the specified realm that use the\n storage capability. The provided moniker is relative to the component\n that declares the storage capability.\n\n Returns INSTANCE_NOT_FOUND if the realm does not exist, and INVALID_ARGS\n if |relative_moniker| is malformed.\n"]
8425 pub fn list_storage_in_realm(
8426 &self,
8427
8428 relative_moniker: impl ::fidl_next::Encode<
8429 ::fidl_next::WireString<'static>,
8430 <___T as ::fidl_next::Transport>::SendBuffer,
8431 >,
8432
8433 iterator: impl ::fidl_next::Encode<
8434 ::fidl_next::ServerEnd<
8435 crate::StorageIterator,
8436 ::fidl_next::fuchsia::WireChannel,
8437 >,
8438 <___T as ::fidl_next::Transport>::SendBuffer,
8439 >,
8440 ) -> ::fidl_next::TwoWayFuture<'_, super::ListStorageInRealm, ___T>
8441 where
8442 <___T as ::fidl_next::Transport>::SendBuffer:
8443 ::fidl_next::encoder::InternalHandleEncoder,
8444 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
8445 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
8446 {
8447 self.list_storage_in_realm_with(
8448 crate::generic::StorageAdminListStorageInRealmRequest {
8449 relative_moniker,
8450
8451 iterator,
8452 },
8453 )
8454 }
8455
8456 #[doc = " Lists the descendant components under the specified realm that use the\n storage capability. The provided moniker is relative to the component\n that declares the storage capability.\n\n Returns INSTANCE_NOT_FOUND if the realm does not exist, and INVALID_ARGS\n if |relative_moniker| is malformed.\n"]
8457 pub fn list_storage_in_realm_with<___R>(
8458 &self,
8459 request: ___R,
8460 ) -> ::fidl_next::TwoWayFuture<'_, super::ListStorageInRealm, ___T>
8461 where
8462 ___R: ::fidl_next::Encode<
8463 crate::wire::StorageAdminListStorageInRealmRequest<'static>,
8464 <___T as ::fidl_next::Transport>::SendBuffer,
8465 >,
8466 {
8467 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
8468 8525152599685368827,
8469 <super::ListStorageInRealm as ::fidl_next::Method>::FLEXIBILITY,
8470 request,
8471 ))
8472 }
8473
8474 #[doc = " Opens the isolated directory for the given storage ID. Creates the\n backing sub-directory for this storage if it hasn\'t yet been created.\n"]
8475 pub fn open_component_storage_by_id(
8476 &self,
8477
8478 id: impl ::fidl_next::Encode<
8479 ::fidl_next::WireString<'static>,
8480 <___T as ::fidl_next::Transport>::SendBuffer,
8481 >,
8482
8483 object: impl ::fidl_next::Encode<
8484 ::fidl_next::ServerEnd<
8485 ::fidl_next_fuchsia_io::Node,
8486 ::fidl_next::fuchsia::WireChannel,
8487 >,
8488 <___T as ::fidl_next::Transport>::SendBuffer,
8489 >,
8490 ) -> ::fidl_next::TwoWayFuture<'_, super::OpenComponentStorageById, ___T>
8491 where
8492 <___T as ::fidl_next::Transport>::SendBuffer:
8493 ::fidl_next::encoder::InternalHandleEncoder,
8494 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
8495 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::fuchsia::HandleEncoder,
8496 {
8497 self.open_component_storage_by_id_with(
8498 crate::generic::StorageAdminOpenComponentStorageByIdRequest { id, object },
8499 )
8500 }
8501
8502 #[doc = " Opens the isolated directory for the given storage ID. Creates the\n backing sub-directory for this storage if it hasn\'t yet been created.\n"]
8503 pub fn open_component_storage_by_id_with<___R>(
8504 &self,
8505 request: ___R,
8506 ) -> ::fidl_next::TwoWayFuture<'_, super::OpenComponentStorageById, ___T>
8507 where
8508 ___R: ::fidl_next::Encode<
8509 crate::wire::StorageAdminOpenComponentStorageByIdRequest<'static>,
8510 <___T as ::fidl_next::Transport>::SendBuffer,
8511 >,
8512 {
8513 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
8514 5188727505160068593,
8515 <super::OpenComponentStorageById as ::fidl_next::Method>::FLEXIBILITY,
8516 request,
8517 ))
8518 }
8519
8520 #[doc = " Deletes the contents of the storage for this component. Preserves the\n component\'s subdirectory itself within the storage backing directory.\n The provided moniker is relative to the component that declares the\n storage capability.\n"]
8521 pub fn delete_component_storage(
8522 &self,
8523
8524 relative_moniker: impl ::fidl_next::Encode<
8525 ::fidl_next::WireString<'static>,
8526 <___T as ::fidl_next::Transport>::SendBuffer,
8527 >,
8528 ) -> ::fidl_next::TwoWayFuture<'_, super::DeleteComponentStorage, ___T>
8529 where
8530 <___T as ::fidl_next::Transport>::SendBuffer:
8531 ::fidl_next::encoder::InternalHandleEncoder,
8532 <___T as ::fidl_next::Transport>::SendBuffer: ::fidl_next::Encoder,
8533 {
8534 self.delete_component_storage_with(
8535 crate::generic::StorageAdminDeleteComponentStorageRequest { relative_moniker },
8536 )
8537 }
8538
8539 #[doc = " Deletes the contents of the storage for this component. Preserves the\n component\'s subdirectory itself within the storage backing directory.\n The provided moniker is relative to the component that declares the\n storage capability.\n"]
8540 pub fn delete_component_storage_with<___R>(
8541 &self,
8542 request: ___R,
8543 ) -> ::fidl_next::TwoWayFuture<'_, super::DeleteComponentStorage, ___T>
8544 where
8545 ___R: ::fidl_next::Encode<
8546 crate::wire::StorageAdminDeleteComponentStorageRequest<'static>,
8547 <___T as ::fidl_next::Transport>::SendBuffer,
8548 >,
8549 {
8550 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
8551 1618975681517712474,
8552 <super::DeleteComponentStorage as ::fidl_next::Method>::FLEXIBILITY,
8553 request,
8554 ))
8555 }
8556
8557 #[doc = " Get the current status of the storage.\n"]
8558 pub fn get_status(&self) -> ::fidl_next::TwoWayFuture<'_, super::GetStatus, ___T> {
8559 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
8560 8586643915409794760,
8561 <super::GetStatus as ::fidl_next::Method>::FLEXIBILITY,
8562 (),
8563 ))
8564 }
8565
8566 #[doc = " Deletes the contents of all the storage. Storage directories are\n retained so any components using storage will be able to continue using\n it to create new files and directories.\n\n Returns Error::INTERNAL only if no storage at all could be cleared.\n Returns successfully even if some errors happen during the deletion\n progress.\n"]
8567 pub fn delete_all_storage_contents(
8568 &self,
8569 ) -> ::fidl_next::TwoWayFuture<'_, super::DeleteAllStorageContents, ___T> {
8570 ::fidl_next::TwoWayFuture::from_untyped(self.client.send_two_way(
8571 3380374508900862683,
8572 <super::DeleteAllStorageContents as ::fidl_next::Method>::FLEXIBILITY,
8573 (),
8574 ))
8575 }
8576 }
8577
8578 #[repr(transparent)]
8580 pub struct StorageAdminServer<___T: ::fidl_next::Transport> {
8581 server: ::fidl_next::protocol::Server<___T>,
8582 }
8583
8584 impl<___T> StorageAdminServer<___T> where ___T: ::fidl_next::Transport {}
8585 }
8586}
8587
8588pub trait StorageAdminClientHandler<
8592 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
8593 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
8594>
8595{
8596}
8597
8598impl<___T> StorageAdminClientHandler<___T> for ::fidl_next::IgnoreEvents where
8599 ___T: ::fidl_next::Transport
8600{
8601}
8602
8603impl<___H, ___T> ::fidl_next::DispatchClientMessage<___H, ___T> for StorageAdmin
8604where
8605 ___H: StorageAdminClientHandler<___T> + ::core::marker::Send,
8606 ___T: ::fidl_next::Transport,
8607{
8608 async fn on_event(
8609 handler: &mut ___H,
8610 ordinal: u64,
8611 flexibility: ::fidl_next::protocol::Flexibility,
8612 buffer: ___T::RecvBuffer,
8613 ) -> ::core::result::Result<(), ::fidl_next::ProtocolError<___T::Error>> {
8614 match ordinal {
8615 ordinal => Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal)),
8616 }
8617 }
8618}
8619
8620pub trait StorageAdminServerHandler<
8624 #[cfg(target_os = "fuchsia")] ___T: ::fidl_next::Transport = ::fidl_next::fuchsia::zx::Channel,
8625 #[cfg(not(target_os = "fuchsia"))] ___T: ::fidl_next::Transport,
8626>
8627{
8628 #[doc = " Opens the isolated directory for the given component. The provided\n moniker is relative to the component that declares the storage\n capability. Creates the backing sub-directory for this storage if it\n hasn\'t yet been created.\n"]
8629 fn open_storage(
8630 &mut self,
8631
8632 request: ::fidl_next::Request<storage_admin::OpenStorage, ___T>,
8633
8634 responder: ::fidl_next::Responder<storage_admin::OpenStorage, ___T>,
8635 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
8636
8637 #[doc = " Lists the descendant components under the specified realm that use the\n storage capability. The provided moniker is relative to the component\n that declares the storage capability.\n\n Returns INSTANCE_NOT_FOUND if the realm does not exist, and INVALID_ARGS\n if |relative_moniker| is malformed.\n"]
8638 fn list_storage_in_realm(
8639 &mut self,
8640
8641 request: ::fidl_next::Request<storage_admin::ListStorageInRealm, ___T>,
8642
8643 responder: ::fidl_next::Responder<storage_admin::ListStorageInRealm, ___T>,
8644 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
8645
8646 #[doc = " Opens the isolated directory for the given storage ID. Creates the\n backing sub-directory for this storage if it hasn\'t yet been created.\n"]
8647 fn open_component_storage_by_id(
8648 &mut self,
8649
8650 request: ::fidl_next::Request<storage_admin::OpenComponentStorageById, ___T>,
8651
8652 responder: ::fidl_next::Responder<storage_admin::OpenComponentStorageById, ___T>,
8653 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
8654
8655 #[doc = " Deletes the contents of the storage for this component. Preserves the\n component\'s subdirectory itself within the storage backing directory.\n The provided moniker is relative to the component that declares the\n storage capability.\n"]
8656 fn delete_component_storage(
8657 &mut self,
8658
8659 request: ::fidl_next::Request<storage_admin::DeleteComponentStorage, ___T>,
8660
8661 responder: ::fidl_next::Responder<storage_admin::DeleteComponentStorage, ___T>,
8662 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
8663
8664 #[doc = " Get the current status of the storage.\n"]
8665 fn get_status(
8666 &mut self,
8667
8668 responder: ::fidl_next::Responder<storage_admin::GetStatus, ___T>,
8669 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
8670
8671 #[doc = " Deletes the contents of all the storage. Storage directories are\n retained so any components using storage will be able to continue using\n it to create new files and directories.\n\n Returns Error::INTERNAL only if no storage at all could be cleared.\n Returns successfully even if some errors happen during the deletion\n progress.\n"]
8672 fn delete_all_storage_contents(
8673 &mut self,
8674
8675 responder: ::fidl_next::Responder<storage_admin::DeleteAllStorageContents, ___T>,
8676 ) -> impl ::core::future::Future<Output = ()> + ::core::marker::Send;
8677}
8678
8679impl<___H, ___T> ::fidl_next::DispatchServerMessage<___H, ___T> for StorageAdmin
8680where
8681 ___H: StorageAdminServerHandler<___T> + ::core::marker::Send,
8682 ___T: ::fidl_next::Transport,
8683 <storage_admin::OpenStorage as ::fidl_next::Method>::Request:
8684 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
8685 <storage_admin::ListStorageInRealm as ::fidl_next::Method>::Request:
8686 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
8687 <storage_admin::OpenComponentStorageById as ::fidl_next::Method>::Request:
8688 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
8689 <storage_admin::DeleteComponentStorage as ::fidl_next::Method>::Request:
8690 ::fidl_next::Decode<<___T as ::fidl_next::Transport>::RecvBuffer>,
8691{
8692 async fn on_one_way(
8693 handler: &mut ___H,
8694 ordinal: u64,
8695 flexibility: ::fidl_next::protocol::Flexibility,
8696 buffer: ___T::RecvBuffer,
8697 ) -> ::core::result::Result<
8698 (),
8699 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
8700 > {
8701 match ordinal {
8702 ordinal => Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal)),
8703 }
8704 }
8705
8706 async fn on_two_way(
8707 handler: &mut ___H,
8708 ordinal: u64,
8709 flexibility: ::fidl_next::protocol::Flexibility,
8710 buffer: ___T::RecvBuffer,
8711 responder: ::fidl_next::protocol::Responder<___T>,
8712 ) -> ::core::result::Result<
8713 (),
8714 ::fidl_next::ProtocolError<<___T as ::fidl_next::Transport>::Error>,
8715 > {
8716 match ordinal {
8717 7848267339832116087 => {
8718 let responder = ::fidl_next::Responder::from_untyped(responder);
8719
8720 match ::fidl_next::DecoderExt::decode(buffer) {
8721 Ok(decoded) => {
8722 handler
8723 .open_storage(::fidl_next::Request::from_decoded(decoded), responder)
8724 .await;
8725 Ok(())
8726 }
8727 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
8728 ordinal: 7848267339832116087,
8729 error,
8730 }),
8731 }
8732 }
8733
8734 8525152599685368827 => {
8735 let responder = ::fidl_next::Responder::from_untyped(responder);
8736
8737 match ::fidl_next::DecoderExt::decode(buffer) {
8738 Ok(decoded) => {
8739 handler
8740 .list_storage_in_realm(
8741 ::fidl_next::Request::from_decoded(decoded),
8742 responder,
8743 )
8744 .await;
8745 Ok(())
8746 }
8747 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
8748 ordinal: 8525152599685368827,
8749 error,
8750 }),
8751 }
8752 }
8753
8754 5188727505160068593 => {
8755 let responder = ::fidl_next::Responder::from_untyped(responder);
8756
8757 match ::fidl_next::DecoderExt::decode(buffer) {
8758 Ok(decoded) => {
8759 handler
8760 .open_component_storage_by_id(
8761 ::fidl_next::Request::from_decoded(decoded),
8762 responder,
8763 )
8764 .await;
8765 Ok(())
8766 }
8767 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
8768 ordinal: 5188727505160068593,
8769 error,
8770 }),
8771 }
8772 }
8773
8774 1618975681517712474 => {
8775 let responder = ::fidl_next::Responder::from_untyped(responder);
8776
8777 match ::fidl_next::DecoderExt::decode(buffer) {
8778 Ok(decoded) => {
8779 handler
8780 .delete_component_storage(
8781 ::fidl_next::Request::from_decoded(decoded),
8782 responder,
8783 )
8784 .await;
8785 Ok(())
8786 }
8787 Err(error) => Err(::fidl_next::ProtocolError::InvalidMessage {
8788 ordinal: 1618975681517712474,
8789 error,
8790 }),
8791 }
8792 }
8793
8794 8586643915409794760 => {
8795 let responder = ::fidl_next::Responder::from_untyped(responder);
8796
8797 handler.get_status(responder).await;
8798 Ok(())
8799 }
8800
8801 3380374508900862683 => {
8802 let responder = ::fidl_next::Responder::from_untyped(responder);
8803
8804 handler.delete_all_storage_contents(responder).await;
8805 Ok(())
8806 }
8807
8808 ordinal => Err(::fidl_next::ProtocolError::UnknownOrdinal(ordinal)),
8809 }
8810 }
8811}
8812
8813pub use fidl_next_common_fuchsia_component::*;
8814
8815pub mod compat {
8817
8818 pub use fidl_next_common_fuchsia_component::compat::*;
8819
8820 impl ::fidl_next::CompatFrom<crate::CapabilityRequestedPayload>
8821 for ::fidl_fuchsia_component::CapabilityRequestedPayload
8822 {
8823 fn compat_from(value: crate::CapabilityRequestedPayload) -> Self {
8824 Self {
8825 name: ::fidl_next::CompatFrom::compat_from(value.name),
8826
8827 capability: ::fidl_next::CompatFrom::compat_from(value.capability),
8828
8829 __source_breaking: ::fidl::marker::SourceBreaking,
8830 }
8831 }
8832 }
8833
8834 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::CapabilityRequestedPayload>
8835 for crate::CapabilityRequestedPayload
8836 {
8837 fn compat_from(value: ::fidl_fuchsia_component::CapabilityRequestedPayload) -> Self {
8838 Self {
8839 name: ::fidl_next::CompatFrom::compat_from(value.name),
8840
8841 capability: ::fidl_next::CompatFrom::compat_from(value.capability),
8842 }
8843 }
8844 }
8845
8846 impl ::fidl_next::CompatFrom<crate::ControllerIsStartedResponse>
8847 for ::fidl_fuchsia_component::ControllerIsStartedResponse
8848 {
8849 #[inline]
8850 fn compat_from(value: crate::ControllerIsStartedResponse) -> Self {
8851 Self { is_started: ::fidl_next::CompatFrom::compat_from(value.is_started) }
8852 }
8853 }
8854
8855 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::ControllerIsStartedResponse>
8856 for crate::ControllerIsStartedResponse
8857 {
8858 #[inline]
8859 fn compat_from(value: ::fidl_fuchsia_component::ControllerIsStartedResponse) -> Self {
8860 Self { is_started: ::fidl_next::CompatFrom::compat_from(value.is_started) }
8861 }
8862 }
8863
8864 impl ::fidl_next::CompatFrom<crate::ControllerGetExposedDictionaryResponse>
8865 for ::fidl_fuchsia_component::ControllerGetExposedDictionaryResponse
8866 {
8867 #[inline]
8868 fn compat_from(value: crate::ControllerGetExposedDictionaryResponse) -> Self {
8869 Self { dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary) }
8870 }
8871 }
8872
8873 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::ControllerGetExposedDictionaryResponse>
8874 for crate::ControllerGetExposedDictionaryResponse
8875 {
8876 #[inline]
8877 fn compat_from(
8878 value: ::fidl_fuchsia_component::ControllerGetExposedDictionaryResponse,
8879 ) -> Self {
8880 Self { dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary) }
8881 }
8882 }
8883
8884 impl ::fidl_next::CompatFrom<crate::NamespaceEntry> for ::fidl_fuchsia_component::NamespaceEntry {
8885 fn compat_from(value: crate::NamespaceEntry) -> Self {
8886 Self {
8887 path: ::fidl_next::CompatFrom::compat_from(value.path),
8888
8889 directory: ::fidl_next::CompatFrom::compat_from(value.directory),
8890
8891 __source_breaking: ::fidl::marker::SourceBreaking,
8892 }
8893 }
8894 }
8895
8896 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::NamespaceEntry> for crate::NamespaceEntry {
8897 fn compat_from(value: ::fidl_fuchsia_component::NamespaceEntry) -> Self {
8898 Self {
8899 path: ::fidl_next::CompatFrom::compat_from(value.path),
8900
8901 directory: ::fidl_next::CompatFrom::compat_from(value.directory),
8902 }
8903 }
8904 }
8905
8906 impl ::fidl_next::CompatFrom<crate::StartChildArgs> for ::fidl_fuchsia_component::StartChildArgs {
8907 fn compat_from(value: crate::StartChildArgs) -> Self {
8908 Self {
8909 numbered_handles: ::fidl_next::CompatFrom::compat_from(value.numbered_handles),
8910
8911 namespace_entries: ::fidl_next::CompatFrom::compat_from(value.namespace_entries),
8912
8913 dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary),
8914
8915 __source_breaking: ::fidl::marker::SourceBreaking,
8916 }
8917 }
8918 }
8919
8920 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::StartChildArgs> for crate::StartChildArgs {
8921 fn compat_from(value: ::fidl_fuchsia_component::StartChildArgs) -> Self {
8922 Self {
8923 numbered_handles: ::fidl_next::CompatFrom::compat_from(value.numbered_handles),
8924
8925 namespace_entries: ::fidl_next::CompatFrom::compat_from(value.namespace_entries),
8926
8927 dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary),
8928 }
8929 }
8930 }
8931
8932 impl ::fidl_next::CompatFrom<crate::ControllerStartRequest>
8933 for ::fidl_fuchsia_component::ControllerStartRequest
8934 {
8935 #[inline]
8936 fn compat_from(value: crate::ControllerStartRequest) -> Self {
8937 Self {
8938 args: ::fidl_next::CompatFrom::compat_from(value.args),
8939
8940 execution_controller: ::fidl_next::CompatFrom::compat_from(
8941 value.execution_controller,
8942 ),
8943 }
8944 }
8945 }
8946
8947 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::ControllerStartRequest>
8948 for crate::ControllerStartRequest
8949 {
8950 #[inline]
8951 fn compat_from(value: ::fidl_fuchsia_component::ControllerStartRequest) -> Self {
8952 Self {
8953 args: ::fidl_next::CompatFrom::compat_from(value.args),
8954
8955 execution_controller: ::fidl_next::CompatFrom::compat_from(
8956 value.execution_controller,
8957 ),
8958 }
8959 }
8960 }
8961
8962 #[cfg(target_os = "fuchsia")]
8963 pub type ControllerProxy = ::fidl_next::Client<crate::Controller>;
8966
8967 impl ::fidl_next::CompatFrom<crate::Controller> for ::fidl_fuchsia_component::ControllerMarker {
8968 fn compat_from(_: crate::Controller) -> Self {
8969 Self
8970 }
8971 }
8972
8973 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::ControllerMarker> for crate::Controller {
8974 fn compat_from(_: ::fidl_fuchsia_component::ControllerMarker) -> Self {
8975 Self
8976 }
8977 }
8978
8979 #[cfg(target_os = "fuchsia")]
8980
8981 impl ::fidl_next::ClientCompatFrom<::fidl_fuchsia_component::ControllerProxy>
8982 for crate::Controller
8983 {
8984 fn client_compat_from(
8985 proxy: ::fidl_fuchsia_component::ControllerProxy,
8986 ) -> ::fidl_next::ClientDispatcher<Self, ::fidl_next::fuchsia::zx::Channel> {
8987 let channel = ::fidl::endpoints::Proxy::into_channel(proxy).unwrap().into_zx_channel();
8988 let client_end = ::fidl_next::ClientEnd::from_untyped(channel);
8989 ::fidl_next::ClientDispatcher::new(client_end)
8990 }
8991 }
8992
8993 impl ::fidl_next::CompatFrom<crate::CreateChildArgs> for ::fidl_fuchsia_component::CreateChildArgs {
8994 fn compat_from(value: crate::CreateChildArgs) -> Self {
8995 Self {
8996 numbered_handles: ::fidl_next::CompatFrom::compat_from(value.numbered_handles),
8997
8998 dynamic_offers: ::fidl_next::CompatFrom::compat_from(value.dynamic_offers),
8999
9000 controller: ::fidl_next::CompatFrom::compat_from(value.controller),
9001
9002 dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary),
9003
9004 __source_breaking: ::fidl::marker::SourceBreaking,
9005 }
9006 }
9007 }
9008
9009 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::CreateChildArgs> for crate::CreateChildArgs {
9010 fn compat_from(value: ::fidl_fuchsia_component::CreateChildArgs) -> Self {
9011 Self {
9012 numbered_handles: ::fidl_next::CompatFrom::compat_from(value.numbered_handles),
9013
9014 dynamic_offers: ::fidl_next::CompatFrom::compat_from(value.dynamic_offers),
9015
9016 controller: ::fidl_next::CompatFrom::compat_from(value.controller),
9017
9018 dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary),
9019 }
9020 }
9021 }
9022
9023 impl ::fidl_next::CompatFrom<crate::DebugStartedPayload>
9024 for ::fidl_fuchsia_component::DebugStartedPayload
9025 {
9026 fn compat_from(value: crate::DebugStartedPayload) -> Self {
9027 Self {
9028 runtime_dir: ::fidl_next::CompatFrom::compat_from(value.runtime_dir),
9029
9030 break_on_start: ::fidl_next::CompatFrom::compat_from(value.break_on_start),
9031
9032 __source_breaking: ::fidl::marker::SourceBreaking,
9033 }
9034 }
9035 }
9036
9037 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::DebugStartedPayload>
9038 for crate::DebugStartedPayload
9039 {
9040 fn compat_from(value: ::fidl_fuchsia_component::DebugStartedPayload) -> Self {
9041 Self {
9042 runtime_dir: ::fidl_next::CompatFrom::compat_from(value.runtime_dir),
9043
9044 break_on_start: ::fidl_next::CompatFrom::compat_from(value.break_on_start),
9045 }
9046 }
9047 }
9048
9049 impl ::fidl_next::CompatFrom<crate::EventPayload> for ::fidl_fuchsia_component::EventPayload {
9050 fn compat_from(value: crate::EventPayload) -> Self {
9051 match value {
9052 crate::EventPayload::CapabilityRequested(value) => {
9053 Self::CapabilityRequested(::fidl_next::CompatFrom::compat_from(value))
9054 }
9055
9056 crate::EventPayload::Purged(value) => {
9057 Self::Purged(::fidl_next::CompatFrom::compat_from(value))
9058 }
9059
9060 crate::EventPayload::Discovered(value) => {
9061 Self::Discovered(::fidl_next::CompatFrom::compat_from(value))
9062 }
9063
9064 crate::EventPayload::Destroyed(value) => {
9065 Self::Destroyed(::fidl_next::CompatFrom::compat_from(value))
9066 }
9067
9068 crate::EventPayload::Resolved(value) => {
9069 Self::Resolved(::fidl_next::CompatFrom::compat_from(value))
9070 }
9071
9072 crate::EventPayload::Started(value) => {
9073 Self::Started(::fidl_next::CompatFrom::compat_from(value))
9074 }
9075
9076 crate::EventPayload::Stopped(value) => {
9077 Self::Stopped(::fidl_next::CompatFrom::compat_from(value))
9078 }
9079
9080 crate::EventPayload::DebugStarted(value) => {
9081 Self::DebugStarted(::fidl_next::CompatFrom::compat_from(value))
9082 }
9083
9084 crate::EventPayload::Unresolved(value) => {
9085 Self::Unresolved(::fidl_next::CompatFrom::compat_from(value))
9086 }
9087
9088 crate::EventPayload::UnknownOrdinal_(unknown_ordinal) => {
9089 Self::__SourceBreaking { unknown_ordinal }
9090 }
9091 }
9092 }
9093 }
9094
9095 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::EventPayload> for crate::EventPayload {
9096 fn compat_from(value: ::fidl_fuchsia_component::EventPayload) -> Self {
9097 match value {
9098 ::fidl_fuchsia_component::EventPayload::CapabilityRequested(value) => {
9099 Self::CapabilityRequested(::fidl_next::CompatFrom::compat_from(value))
9100 }
9101
9102 ::fidl_fuchsia_component::EventPayload::Purged(value) => {
9103 Self::Purged(::fidl_next::CompatFrom::compat_from(value))
9104 }
9105
9106 ::fidl_fuchsia_component::EventPayload::Discovered(value) => {
9107 Self::Discovered(::fidl_next::CompatFrom::compat_from(value))
9108 }
9109
9110 ::fidl_fuchsia_component::EventPayload::Destroyed(value) => {
9111 Self::Destroyed(::fidl_next::CompatFrom::compat_from(value))
9112 }
9113
9114 ::fidl_fuchsia_component::EventPayload::Resolved(value) => {
9115 Self::Resolved(::fidl_next::CompatFrom::compat_from(value))
9116 }
9117
9118 ::fidl_fuchsia_component::EventPayload::Started(value) => {
9119 Self::Started(::fidl_next::CompatFrom::compat_from(value))
9120 }
9121
9122 ::fidl_fuchsia_component::EventPayload::Stopped(value) => {
9123 Self::Stopped(::fidl_next::CompatFrom::compat_from(value))
9124 }
9125
9126 ::fidl_fuchsia_component::EventPayload::DebugStarted(value) => {
9127 Self::DebugStarted(::fidl_next::CompatFrom::compat_from(value))
9128 }
9129
9130 ::fidl_fuchsia_component::EventPayload::Unresolved(value) => {
9131 Self::Unresolved(::fidl_next::CompatFrom::compat_from(value))
9132 }
9133
9134 ::fidl_fuchsia_component::EventPayload::__SourceBreaking { unknown_ordinal } => {
9135 Self::UnknownOrdinal_(unknown_ordinal)
9136 }
9137 }
9138 }
9139 }
9140
9141 impl ::fidl_next::CompatFrom<crate::Event> for ::fidl_fuchsia_component::Event {
9142 fn compat_from(value: crate::Event) -> Self {
9143 Self {
9144 header: ::fidl_next::CompatFrom::compat_from(value.header),
9145
9146 payload: ::fidl_next::CompatFrom::compat_from(value.payload),
9147
9148 __source_breaking: ::fidl::marker::SourceBreaking,
9149 }
9150 }
9151 }
9152
9153 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::Event> for crate::Event {
9154 fn compat_from(value: ::fidl_fuchsia_component::Event) -> Self {
9155 Self {
9156 header: ::fidl_next::CompatFrom::compat_from(value.header),
9157
9158 payload: ::fidl_next::CompatFrom::compat_from(value.payload),
9159 }
9160 }
9161 }
9162
9163 impl ::fidl_next::CompatFrom<crate::EventStreamGetNextResponse>
9164 for ::fidl_fuchsia_component::EventStreamGetNextResponse
9165 {
9166 #[inline]
9167 fn compat_from(value: crate::EventStreamGetNextResponse) -> Self {
9168 Self { events: ::fidl_next::CompatFrom::compat_from(value.events) }
9169 }
9170 }
9171
9172 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::EventStreamGetNextResponse>
9173 for crate::EventStreamGetNextResponse
9174 {
9175 #[inline]
9176 fn compat_from(value: ::fidl_fuchsia_component::EventStreamGetNextResponse) -> Self {
9177 Self { events: ::fidl_next::CompatFrom::compat_from(value.events) }
9178 }
9179 }
9180
9181 #[cfg(target_os = "fuchsia")]
9182 pub type EventStreamProxy = ::fidl_next::Client<crate::EventStream>;
9185
9186 impl ::fidl_next::CompatFrom<crate::EventStream> for ::fidl_fuchsia_component::EventStreamMarker {
9187 fn compat_from(_: crate::EventStream) -> Self {
9188 Self
9189 }
9190 }
9191
9192 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::EventStreamMarker> for crate::EventStream {
9193 fn compat_from(_: ::fidl_fuchsia_component::EventStreamMarker) -> Self {
9194 Self
9195 }
9196 }
9197
9198 #[cfg(target_os = "fuchsia")]
9199
9200 impl ::fidl_next::ClientCompatFrom<::fidl_fuchsia_component::EventStreamProxy>
9201 for crate::EventStream
9202 {
9203 fn client_compat_from(
9204 proxy: ::fidl_fuchsia_component::EventStreamProxy,
9205 ) -> ::fidl_next::ClientDispatcher<Self, ::fidl_next::fuchsia::zx::Channel> {
9206 let channel = ::fidl::endpoints::Proxy::into_channel(proxy).unwrap().into_zx_channel();
9207 let client_end = ::fidl_next::ClientEnd::from_untyped(channel);
9208 ::fidl_next::ClientDispatcher::new(client_end)
9209 }
9210 }
9211
9212 impl ::fidl_next::CompatFrom<crate::IntrospectorGetMonikerRequest>
9213 for ::fidl_fuchsia_component::IntrospectorGetMonikerRequest
9214 {
9215 #[inline]
9216 fn compat_from(value: crate::IntrospectorGetMonikerRequest) -> Self {
9217 Self {
9218 component_instance: ::fidl_next::CompatFrom::compat_from(value.component_instance),
9219 }
9220 }
9221 }
9222
9223 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::IntrospectorGetMonikerRequest>
9224 for crate::IntrospectorGetMonikerRequest
9225 {
9226 #[inline]
9227 fn compat_from(value: ::fidl_fuchsia_component::IntrospectorGetMonikerRequest) -> Self {
9228 Self {
9229 component_instance: ::fidl_next::CompatFrom::compat_from(value.component_instance),
9230 }
9231 }
9232 }
9233
9234 #[cfg(target_os = "fuchsia")]
9235 pub type IntrospectorProxy = ::fidl_next::Client<crate::Introspector>;
9238
9239 impl ::fidl_next::CompatFrom<crate::Introspector> for ::fidl_fuchsia_component::IntrospectorMarker {
9240 fn compat_from(_: crate::Introspector) -> Self {
9241 Self
9242 }
9243 }
9244
9245 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::IntrospectorMarker> for crate::Introspector {
9246 fn compat_from(_: ::fidl_fuchsia_component::IntrospectorMarker) -> Self {
9247 Self
9248 }
9249 }
9250
9251 #[cfg(target_os = "fuchsia")]
9252
9253 impl ::fidl_next::ClientCompatFrom<::fidl_fuchsia_component::IntrospectorProxy>
9254 for crate::Introspector
9255 {
9256 fn client_compat_from(
9257 proxy: ::fidl_fuchsia_component::IntrospectorProxy,
9258 ) -> ::fidl_next::ClientDispatcher<Self, ::fidl_next::fuchsia::zx::Channel> {
9259 let channel = ::fidl::endpoints::Proxy::into_channel(proxy).unwrap().into_zx_channel();
9260 let client_end = ::fidl_next::ClientEnd::from_untyped(channel);
9261 ::fidl_next::ClientDispatcher::new(client_end)
9262 }
9263 }
9264
9265 impl ::fidl_next::CompatFrom<crate::NamespaceInputEntry>
9266 for ::fidl_fuchsia_component::NamespaceInputEntry
9267 {
9268 #[inline]
9269 fn compat_from(value: crate::NamespaceInputEntry) -> Self {
9270 Self {
9271 path: ::fidl_next::CompatFrom::compat_from(value.path),
9272
9273 dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary),
9274 }
9275 }
9276 }
9277
9278 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::NamespaceInputEntry>
9279 for crate::NamespaceInputEntry
9280 {
9281 #[inline]
9282 fn compat_from(value: ::fidl_fuchsia_component::NamespaceInputEntry) -> Self {
9283 Self {
9284 path: ::fidl_next::CompatFrom::compat_from(value.path),
9285
9286 dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary),
9287 }
9288 }
9289 }
9290
9291 impl ::fidl_next::CompatFrom<crate::NamespaceCreateRequest>
9292 for ::fidl_fuchsia_component::NamespaceCreateRequest
9293 {
9294 #[inline]
9295 fn compat_from(value: crate::NamespaceCreateRequest) -> Self {
9296 Self { entries: ::fidl_next::CompatFrom::compat_from(value.entries) }
9297 }
9298 }
9299
9300 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::NamespaceCreateRequest>
9301 for crate::NamespaceCreateRequest
9302 {
9303 #[inline]
9304 fn compat_from(value: ::fidl_fuchsia_component::NamespaceCreateRequest) -> Self {
9305 Self { entries: ::fidl_next::CompatFrom::compat_from(value.entries) }
9306 }
9307 }
9308
9309 impl ::fidl_next::CompatFrom<crate::NamespaceCreateResponse>
9310 for ::fidl_fuchsia_component::NamespaceCreateResponse
9311 {
9312 #[inline]
9313 fn compat_from(value: crate::NamespaceCreateResponse) -> Self {
9314 Self { entries: ::fidl_next::CompatFrom::compat_from(value.entries) }
9315 }
9316 }
9317
9318 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::NamespaceCreateResponse>
9319 for crate::NamespaceCreateResponse
9320 {
9321 #[inline]
9322 fn compat_from(value: ::fidl_fuchsia_component::NamespaceCreateResponse) -> Self {
9323 Self { entries: ::fidl_next::CompatFrom::compat_from(value.entries) }
9324 }
9325 }
9326
9327 #[cfg(target_os = "fuchsia")]
9328 pub type NamespaceProxy = ::fidl_next::Client<crate::Namespace>;
9331
9332 impl ::fidl_next::CompatFrom<crate::Namespace> for ::fidl_fuchsia_component::NamespaceMarker {
9333 fn compat_from(_: crate::Namespace) -> Self {
9334 Self
9335 }
9336 }
9337
9338 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::NamespaceMarker> for crate::Namespace {
9339 fn compat_from(_: ::fidl_fuchsia_component::NamespaceMarker) -> Self {
9340 Self
9341 }
9342 }
9343
9344 #[cfg(target_os = "fuchsia")]
9345
9346 impl ::fidl_next::ClientCompatFrom<::fidl_fuchsia_component::NamespaceProxy> for crate::Namespace {
9347 fn client_compat_from(
9348 proxy: ::fidl_fuchsia_component::NamespaceProxy,
9349 ) -> ::fidl_next::ClientDispatcher<Self, ::fidl_next::fuchsia::zx::Channel> {
9350 let channel = ::fidl::endpoints::Proxy::into_channel(proxy).unwrap().into_zx_channel();
9351 let client_end = ::fidl_next::ClientEnd::from_untyped(channel);
9352 ::fidl_next::ClientDispatcher::new(client_end)
9353 }
9354 }
9355
9356 impl ::fidl_next::CompatFrom<crate::RealmListChildrenRequest>
9357 for ::fidl_fuchsia_component::RealmListChildrenRequest
9358 {
9359 #[inline]
9360 fn compat_from(value: crate::RealmListChildrenRequest) -> Self {
9361 Self {
9362 collection: ::fidl_next::CompatFrom::compat_from(value.collection),
9363
9364 iter: ::fidl_next::CompatFrom::compat_from(value.iter),
9365 }
9366 }
9367 }
9368
9369 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::RealmListChildrenRequest>
9370 for crate::RealmListChildrenRequest
9371 {
9372 #[inline]
9373 fn compat_from(value: ::fidl_fuchsia_component::RealmListChildrenRequest) -> Self {
9374 Self {
9375 collection: ::fidl_next::CompatFrom::compat_from(value.collection),
9376
9377 iter: ::fidl_next::CompatFrom::compat_from(value.iter),
9378 }
9379 }
9380 }
9381
9382 impl ::fidl_next::CompatFrom<crate::RealmGetChildOutputDictionaryRequest>
9383 for ::fidl_fuchsia_component::RealmGetChildOutputDictionaryRequest
9384 {
9385 #[inline]
9386 fn compat_from(value: crate::RealmGetChildOutputDictionaryRequest) -> Self {
9387 Self { child: ::fidl_next::CompatFrom::compat_from(value.child) }
9388 }
9389 }
9390
9391 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::RealmGetChildOutputDictionaryRequest>
9392 for crate::RealmGetChildOutputDictionaryRequest
9393 {
9394 #[inline]
9395 fn compat_from(
9396 value: ::fidl_fuchsia_component::RealmGetChildOutputDictionaryRequest,
9397 ) -> Self {
9398 Self { child: ::fidl_next::CompatFrom::compat_from(value.child) }
9399 }
9400 }
9401
9402 impl ::fidl_next::CompatFrom<crate::RealmGetChildOutputDictionaryResponse>
9403 for ::fidl_fuchsia_component::RealmGetChildOutputDictionaryResponse
9404 {
9405 #[inline]
9406 fn compat_from(value: crate::RealmGetChildOutputDictionaryResponse) -> Self {
9407 Self { dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary) }
9408 }
9409 }
9410
9411 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::RealmGetChildOutputDictionaryResponse>
9412 for crate::RealmGetChildOutputDictionaryResponse
9413 {
9414 #[inline]
9415 fn compat_from(
9416 value: ::fidl_fuchsia_component::RealmGetChildOutputDictionaryResponse,
9417 ) -> Self {
9418 Self { dictionary: ::fidl_next::CompatFrom::compat_from(value.dictionary) }
9419 }
9420 }
9421
9422 impl ::fidl_next::CompatFrom<crate::RealmOpenControllerRequest>
9423 for ::fidl_fuchsia_component::RealmOpenControllerRequest
9424 {
9425 #[inline]
9426 fn compat_from(value: crate::RealmOpenControllerRequest) -> Self {
9427 Self {
9428 child: ::fidl_next::CompatFrom::compat_from(value.child),
9429
9430 controller: ::fidl_next::CompatFrom::compat_from(value.controller),
9431 }
9432 }
9433 }
9434
9435 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::RealmOpenControllerRequest>
9436 for crate::RealmOpenControllerRequest
9437 {
9438 #[inline]
9439 fn compat_from(value: ::fidl_fuchsia_component::RealmOpenControllerRequest) -> Self {
9440 Self {
9441 child: ::fidl_next::CompatFrom::compat_from(value.child),
9442
9443 controller: ::fidl_next::CompatFrom::compat_from(value.controller),
9444 }
9445 }
9446 }
9447
9448 impl ::fidl_next::CompatFrom<crate::RealmOpenExposedDirRequest>
9449 for ::fidl_fuchsia_component::RealmOpenExposedDirRequest
9450 {
9451 #[inline]
9452 fn compat_from(value: crate::RealmOpenExposedDirRequest) -> Self {
9453 Self {
9454 child: ::fidl_next::CompatFrom::compat_from(value.child),
9455
9456 exposed_dir: ::fidl_next::CompatFrom::compat_from(value.exposed_dir),
9457 }
9458 }
9459 }
9460
9461 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::RealmOpenExposedDirRequest>
9462 for crate::RealmOpenExposedDirRequest
9463 {
9464 #[inline]
9465 fn compat_from(value: ::fidl_fuchsia_component::RealmOpenExposedDirRequest) -> Self {
9466 Self {
9467 child: ::fidl_next::CompatFrom::compat_from(value.child),
9468
9469 exposed_dir: ::fidl_next::CompatFrom::compat_from(value.exposed_dir),
9470 }
9471 }
9472 }
9473
9474 impl ::fidl_next::CompatFrom<crate::RealmCreateChildRequest>
9475 for ::fidl_fuchsia_component::RealmCreateChildRequest
9476 {
9477 #[inline]
9478 fn compat_from(value: crate::RealmCreateChildRequest) -> Self {
9479 Self {
9480 collection: ::fidl_next::CompatFrom::compat_from(value.collection),
9481
9482 decl: ::fidl_next::CompatFrom::compat_from(value.decl),
9483
9484 args: ::fidl_next::CompatFrom::compat_from(value.args),
9485 }
9486 }
9487 }
9488
9489 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::RealmCreateChildRequest>
9490 for crate::RealmCreateChildRequest
9491 {
9492 #[inline]
9493 fn compat_from(value: ::fidl_fuchsia_component::RealmCreateChildRequest) -> Self {
9494 Self {
9495 collection: ::fidl_next::CompatFrom::compat_from(value.collection),
9496
9497 decl: ::fidl_next::CompatFrom::compat_from(value.decl),
9498
9499 args: ::fidl_next::CompatFrom::compat_from(value.args),
9500 }
9501 }
9502 }
9503
9504 impl ::fidl_next::CompatFrom<crate::RealmGetResolvedInfoResponse>
9505 for ::fidl_fuchsia_component::RealmGetResolvedInfoResponse
9506 {
9507 #[inline]
9508 fn compat_from(value: crate::RealmGetResolvedInfoResponse) -> Self {
9509 Self { resolved_info: ::fidl_next::CompatFrom::compat_from(value.resolved_info) }
9510 }
9511 }
9512
9513 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::RealmGetResolvedInfoResponse>
9514 for crate::RealmGetResolvedInfoResponse
9515 {
9516 #[inline]
9517 fn compat_from(value: ::fidl_fuchsia_component::RealmGetResolvedInfoResponse) -> Self {
9518 Self { resolved_info: ::fidl_next::CompatFrom::compat_from(value.resolved_info) }
9519 }
9520 }
9521
9522 #[cfg(target_os = "fuchsia")]
9523 pub type RealmProxy = ::fidl_next::Client<crate::Realm>;
9526
9527 impl ::fidl_next::CompatFrom<crate::Realm> for ::fidl_fuchsia_component::RealmMarker {
9528 fn compat_from(_: crate::Realm) -> Self {
9529 Self
9530 }
9531 }
9532
9533 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::RealmMarker> for crate::Realm {
9534 fn compat_from(_: ::fidl_fuchsia_component::RealmMarker) -> Self {
9535 Self
9536 }
9537 }
9538
9539 #[cfg(target_os = "fuchsia")]
9540
9541 impl ::fidl_next::ClientCompatFrom<::fidl_fuchsia_component::RealmProxy> for crate::Realm {
9542 fn client_compat_from(
9543 proxy: ::fidl_fuchsia_component::RealmProxy,
9544 ) -> ::fidl_next::ClientDispatcher<Self, ::fidl_next::fuchsia::zx::Channel> {
9545 let channel = ::fidl::endpoints::Proxy::into_channel(proxy).unwrap().into_zx_channel();
9546 let client_end = ::fidl_next::ClientEnd::from_untyped(channel);
9547 ::fidl_next::ClientDispatcher::new(client_end)
9548 }
9549 }
9550
9551 impl ::fidl_next::CompatFrom<crate::StorageAdminListStorageInRealmRequest>
9552 for ::fidl_fuchsia_component::StorageAdminListStorageInRealmRequest
9553 {
9554 #[inline]
9555 fn compat_from(value: crate::StorageAdminListStorageInRealmRequest) -> Self {
9556 Self {
9557 relative_moniker: ::fidl_next::CompatFrom::compat_from(value.relative_moniker),
9558
9559 iterator: ::fidl_next::CompatFrom::compat_from(value.iterator),
9560 }
9561 }
9562 }
9563
9564 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::StorageAdminListStorageInRealmRequest>
9565 for crate::StorageAdminListStorageInRealmRequest
9566 {
9567 #[inline]
9568 fn compat_from(
9569 value: ::fidl_fuchsia_component::StorageAdminListStorageInRealmRequest,
9570 ) -> Self {
9571 Self {
9572 relative_moniker: ::fidl_next::CompatFrom::compat_from(value.relative_moniker),
9573
9574 iterator: ::fidl_next::CompatFrom::compat_from(value.iterator),
9575 }
9576 }
9577 }
9578
9579 impl ::fidl_next::CompatFrom<crate::StorageAdminOpenStorageRequest>
9580 for ::fidl_fuchsia_component::StorageAdminOpenStorageRequest
9581 {
9582 #[inline]
9583 fn compat_from(value: crate::StorageAdminOpenStorageRequest) -> Self {
9584 Self {
9585 relative_moniker: ::fidl_next::CompatFrom::compat_from(value.relative_moniker),
9586
9587 object: ::fidl_next::CompatFrom::compat_from(value.object),
9588 }
9589 }
9590 }
9591
9592 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::StorageAdminOpenStorageRequest>
9593 for crate::StorageAdminOpenStorageRequest
9594 {
9595 #[inline]
9596 fn compat_from(value: ::fidl_fuchsia_component::StorageAdminOpenStorageRequest) -> Self {
9597 Self {
9598 relative_moniker: ::fidl_next::CompatFrom::compat_from(value.relative_moniker),
9599
9600 object: ::fidl_next::CompatFrom::compat_from(value.object),
9601 }
9602 }
9603 }
9604
9605 impl ::fidl_next::CompatFrom<crate::StorageAdminOpenComponentStorageByIdRequest>
9606 for ::fidl_fuchsia_component::StorageAdminOpenComponentStorageByIdRequest
9607 {
9608 #[inline]
9609 fn compat_from(value: crate::StorageAdminOpenComponentStorageByIdRequest) -> Self {
9610 Self {
9611 id: ::fidl_next::CompatFrom::compat_from(value.id),
9612
9613 object: ::fidl_next::CompatFrom::compat_from(value.object),
9614 }
9615 }
9616 }
9617
9618 impl
9619 ::fidl_next::CompatFrom<
9620 ::fidl_fuchsia_component::StorageAdminOpenComponentStorageByIdRequest,
9621 > for crate::StorageAdminOpenComponentStorageByIdRequest
9622 {
9623 #[inline]
9624 fn compat_from(
9625 value: ::fidl_fuchsia_component::StorageAdminOpenComponentStorageByIdRequest,
9626 ) -> Self {
9627 Self {
9628 id: ::fidl_next::CompatFrom::compat_from(value.id),
9629
9630 object: ::fidl_next::CompatFrom::compat_from(value.object),
9631 }
9632 }
9633 }
9634
9635 #[cfg(target_os = "fuchsia")]
9636 pub type StorageAdminProxy = ::fidl_next::Client<crate::StorageAdmin>;
9639
9640 impl ::fidl_next::CompatFrom<crate::StorageAdmin> for ::fidl_fuchsia_component::StorageAdminMarker {
9641 fn compat_from(_: crate::StorageAdmin) -> Self {
9642 Self
9643 }
9644 }
9645
9646 impl ::fidl_next::CompatFrom<::fidl_fuchsia_component::StorageAdminMarker> for crate::StorageAdmin {
9647 fn compat_from(_: ::fidl_fuchsia_component::StorageAdminMarker) -> Self {
9648 Self
9649 }
9650 }
9651
9652 #[cfg(target_os = "fuchsia")]
9653
9654 impl ::fidl_next::ClientCompatFrom<::fidl_fuchsia_component::StorageAdminProxy>
9655 for crate::StorageAdmin
9656 {
9657 fn client_compat_from(
9658 proxy: ::fidl_fuchsia_component::StorageAdminProxy,
9659 ) -> ::fidl_next::ClientDispatcher<Self, ::fidl_next::fuchsia::zx::Channel> {
9660 let channel = ::fidl::endpoints::Proxy::into_channel(proxy).unwrap().into_zx_channel();
9661 let client_end = ::fidl_next::ClientEnd::from_untyped(channel);
9662 ::fidl_next::ClientDispatcher::new(client_end)
9663 }
9664 }
9665}