pub enum Type {
Show 25 variants
UInt8,
Int8,
UInt16,
Int16,
UInt32,
Int32,
UInt64,
Int64,
Float32,
Float64,
Boolean,
String,
Bytes,
Timestamp,
Duration,
Object {
module_path: String,
name: String,
imp: ObjectImpl,
},
ForeignExecutor,
Record {
module_path: String,
name: String,
},
Enum {
module_path: String,
name: String,
},
CallbackInterface {
module_path: String,
name: String,
},
Optional {
inner_type: Box<Type>,
},
Sequence {
inner_type: Box<Type>,
},
Map {
key_type: Box<Type>,
value_type: Box<Type>,
},
External {
module_path: String,
name: String,
namespace: String,
kind: ExternalKind,
tagged: bool,
},
Custom {
module_path: String,
name: String,
builtin: Box<Type>,
},
}
Expand description
Represents all the different high-level types that can be used in a component interface. At this level we identify user-defined types by name, without knowing any details of their internal structure apart from what type of thing they are (record, enum, etc).
Variants§
UInt8
Int8
UInt16
Int16
UInt32
Int32
UInt64
Int64
Float32
Float64
Boolean
String
Bytes
Timestamp
Duration
Object
ForeignExecutor
Record
Enum
CallbackInterface
Optional
Sequence
Map
External
Custom
Implementations§
Source§impl Type
impl Type
pub fn iter_types(&self) -> TypeIterator<'_>
Trait Implementations§
Source§impl Ord for Type
impl Ord for Type
Source§impl PartialOrd for Type
impl PartialOrd for Type
impl Eq for Type
impl StructuralPartialEq for Type
Auto Trait Implementations§
impl Freeze for Type
impl RefUnwindSafe for Type
impl Send for Type
impl Sync for Type
impl Unpin for Type
impl UnwindSafe for Type
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