blob: 4ac2d7893b7c8a2a527f752b6812b68b4481e92d [file] [log] [blame]
// WARNING: This file is machine generated by fidlgen.
#![allow(
unused_parens, // one-element-tuple-case is not a tuple
unused_mut, // not all args require mutation, but many do
nonstandard_style, // auto-caps does its best, but is not always successful
)]
#![recursion_limit = "512"]
#[cfg(target_os = "fuchsia")]
#[allow(unused_imports)]
use fuchsia_zircon as zx;
#[allow(unused_imports)]
use {
bitflags::bitflags,
fidl::{
client::{decode_transaction_body_fut, QueryResponseFut},
encoding::{Decodable as _, Encodable as _},
fidl_empty_struct, fidl_flexible_bits, fidl_flexible_enum, fidl_strict_bits,
fidl_strict_enum, fidl_struct, fidl_struct_copy, fidl_table, fidl_xunion,
wrap_handle_metadata,
},
fuchsia_zircon_status as zx_status,
futures::future::{self, MaybeDone, TryFutureExt},
};
#[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
#[repr(u32)]
pub enum ObjType {
None = 0,
Channel = 4,
}
fidl_strict_enum! {
name: ObjType,
prim_ty: u32,
members: [
None { value: 0, },
Channel { value: 4, },
],
}
#[derive(Debug, PartialEq)]
pub struct ExampleOfUseOfAliases {
pub field_of_u32: u32,
pub field_of_vec_of_strings: Vec<String>,
pub field_of_vec_of_strings_at_most_nine: Vec<String>,
pub field_of_vec_of_strings_at_most_5: Vec<String>,
pub field_of_vec_of_ref_me_at_most_5: Vec<fidl_someotherlibrary::ReferenceMe>,
pub field_of_channel: fidl::Channel,
pub field_of_client_end: fidl::Channel,
pub field_of_nullable_client_end: Option<fidl::Channel>,
}
fidl_struct! {
name: ExampleOfUseOfAliases,
members: [
field_of_u32 {
ty: u32,
offset_v1: 0,
},
field_of_vec_of_strings {
ty: Vec<String>,
offset_v1: 8,
},
field_of_vec_of_strings_at_most_nine {
ty: Vec<String>,
offset_v1: 24,
},
field_of_vec_of_strings_at_most_5 {
ty: Vec<String>,
offset_v1: 40,
},
field_of_vec_of_ref_me_at_most_5 {
ty: Vec<fidl_someotherlibrary::ReferenceMe>,
offset_v1: 56,
},
field_of_channel {
ty: fidl::Channel,
offset_v1: 72,
handle_metadata: {
handle_subtype: fidl::ObjectType::CHANNEL,
handle_rights: fidl::Rights::from_bits_const(2147483648).unwrap(),
},
},
field_of_client_end {
ty: fidl::Channel,
offset_v1: 76,
handle_metadata: {
handle_subtype: fidl::ObjectType::CHANNEL,
handle_rights: fidl::Rights::from_bits_const(2147483648).unwrap(),
},
},
field_of_nullable_client_end {
ty: Option<fidl::Channel>,
offset_v1: 80,
handle_metadata: {
handle_subtype: fidl::ObjectType::CHANNEL,
handle_rights: fidl::Rights::from_bits_const(2147483648).unwrap(),
},
},
],
padding: [
{
ty: u64,
offset: 0,
mask: 0xffffffff00000000u64,
},
{
ty: u64,
offset: 80,
mask: 0xffffffff00000000u64,
},],
size_v1: 88,
align_v1: 8,
}