pub enum ApiTypeKind {
Record(Vec<ApiMember>),
Variant(Vec<ApiMember>),
Enum(Vec<ApiMember>),
Flags(Vec<ApiMember>),
Resource,
Alias(String),
}Expand description
The shape of a type definition.
Variants§
Record(Vec<ApiMember>)
A record: every field, in order, each with a type.
Variant(Vec<ApiMember>)
A variant: every case, in order; a case may carry a payload type.
Enum(Vec<ApiMember>)
An enum: every case, in order (no payloads).
Flags(Vec<ApiMember>)
A flags: every flag, in order.
Resource
A resource: a host- or guest-owned handle. Its methods are the
interface’s functions whose ApiFunction::kind names it.
Alias(String)
type name = <expr>: the aliased type in WIT syntax.
Implementations§
Trait Implementations§
Source§impl Clone for ApiTypeKind
impl Clone for ApiTypeKind
Source§fn clone(&self) -> ApiTypeKind
fn clone(&self) -> ApiTypeKind
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ApiTypeKind
impl Debug for ApiTypeKind
impl Eq for ApiTypeKind
Source§impl PartialEq for ApiTypeKind
impl PartialEq for ApiTypeKind
impl StructuralPartialEq for ApiTypeKind
Auto Trait Implementations§
impl Freeze for ApiTypeKind
impl RefUnwindSafe for ApiTypeKind
impl Send for ApiTypeKind
impl Sync for ApiTypeKind
impl Unpin for ApiTypeKind
impl UnsafeUnpin for ApiTypeKind
impl UnwindSafe for ApiTypeKind
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