pub struct Utf16;
Trait Implementations§
Source§impl ForeignType for Utf16
impl ForeignType for Utf16
Source§fn assignable_from(&self, type_: &Type) -> bool
fn assignable_from(&self, type_: &Type) -> bool
Is this type assignable from this other type?
i.e. let X: ThisType = OtherType;
Source§fn assignable_to(&self, type_: &Type) -> bool
fn assignable_to(&self, type_: &Type) -> bool
Is this type assignable to this other type?
i.e. let X: OtherType = ThisType;
Generally identical to
ForeignType::assignable_from
Source§fn type_ref(&self) -> TokenStream
fn type_ref(&self) -> TokenStream
Emits this type as a Rust type
Source§fn decoding_gen(
&self,
source: TokenStream,
output_ref: TokenStream,
arguments: Vec<TokenStream>,
is_async: bool,
) -> TokenStream
fn decoding_gen( &self, source: TokenStream, output_ref: TokenStream, arguments: Vec<TokenStream>, is_async: bool, ) -> TokenStream
output code should be a term expression that: Read more
Source§fn encoding_gen(
&self,
target: TokenStream,
field_ref: TokenStream,
_arguments: Vec<TokenStream>,
is_async: bool,
) -> TokenStream
fn encoding_gen( &self, target: TokenStream, field_ref: TokenStream, _arguments: Vec<TokenStream>, is_async: bool, ) -> TokenStream
output code should be a single statement that: Read more
Source§fn arguments(&self) -> Vec<TypeArgument>
fn arguments(&self) -> Vec<TypeArgument>
All arguments that can be passed to this type to describe characteristics (i.e. string length)
All optional arguments must come at the end of the list of arguments.
Source§fn can_receive_auto(&self) -> Option<ScalarType>
fn can_receive_auto(&self) -> Option<ScalarType>
If
Some
, this type can receive auto
defined lengths during encodingSource§fn assignable_from_partial(&self, type_: &PartialType) -> bool
fn assignable_from_partial(&self, type_: &PartialType) -> bool
An internal modified form of
ForeignType::assignable_from
to provide some flexibility in type checking.Source§fn assignable_to_partial(&self, type_: &PartialType) -> bool
fn assignable_to_partial(&self, type_: &PartialType) -> bool
An internal modified form of
ForeignType::assignable_to
to provide some flexibility in type checking.Auto Trait Implementations§
impl Freeze for Utf16
impl RefUnwindSafe for Utf16
impl Send for Utf16
impl Sync for Utf16
impl Unpin for Utf16
impl UnwindSafe for Utf16
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