Enum IoStyle
#[repr(u32)]pub enum IoStyle {
Sync = 1,
Async = 2,
}
Variants§
Implementations§
§impl IoStyle
impl IoStyle
pub fn from_primitive(prim: u32) -> Option<IoStyle>
pub const fn into_primitive(self) -> u32
pub fn is_unknown(&self) -> bool
👎Deprecated: Strict enums should not use
is_unknown
Trait Implementations§
§impl<D> Decode<IoStyle, D> for IoStylewhere
D: ResourceDialect,
impl<D> Decode<IoStyle, D> for IoStylewhere
D: ResourceDialect,
§impl<D> Encode<IoStyle, D> for IoStylewhere
D: ResourceDialect,
impl<D> Encode<IoStyle, D> for IoStylewhere
D: ResourceDialect,
§impl Ord for IoStyle
impl Ord for IoStyle
§impl PartialOrd for IoStyle
impl PartialOrd for IoStyle
§impl TypeMarker for IoStyle
impl TypeMarker for IoStyle
§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Returns the minimum required alignment of the inline portion of the
encoded object. It must be a (nonzero) power of two.
§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
Returns the size of the inline portion of the encoded object, including
padding for alignment. Must be a multiple of
inline_align
.§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Returns true if the memory layout of
Self::Owned
matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned
to a single memcpy. Read more§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Returns true if the memory layout of
Self::Owned
matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned
to a single memcpy.§impl ValueTypeMarker for IoStyle
impl ValueTypeMarker for IoStyle
§type Borrowed<'a> = IoStyle
type Borrowed<'a> = IoStyle
The Rust type to use for encoding. This is a particular
Encode<Self>
type cheaply obtainable from &Self::Owned
. There are three cases: Read more§fn borrow(
value: &<IoStyle as TypeMarker>::Owned,
) -> <IoStyle as ValueTypeMarker>::Borrowed<'_>
fn borrow( value: &<IoStyle as TypeMarker>::Owned, ) -> <IoStyle as ValueTypeMarker>::Borrowed<'_>
Cheaply converts from
&Self::Owned
to Self::Borrowed
.impl Copy for IoStyle
impl Eq for IoStyle
impl StructuralPartialEq for IoStyle
Auto Trait Implementations§
impl Freeze for IoStyle
impl RefUnwindSafe for IoStyle
impl Send for IoStyle
impl Sync for IoStyle
impl Unpin for IoStyle
impl UnwindSafe for IoStyle
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more