pub struct Str;Expand description
This type is used to represent a borrowed &str in a state object.
Trait Implementations§
Source§impl KeyFieldValue for Str
impl KeyFieldValue for Str
Source§fn encode<'a>(
key: &<Str as ObjectFieldValue>::In<'a>,
writer: &mut ReverseSliceWriter<'_>,
) -> Result<(), EncodeError>
fn encode<'a>( key: &<Str as ObjectFieldValue>::In<'a>, writer: &mut ReverseSliceWriter<'_>, ) -> Result<(), EncodeError>
Encode the key segment as a non-terminal segment.
Source§fn encode_terminal<'a>(
key: &<Str as ObjectFieldValue>::In<'a>,
writer: &mut ReverseSliceWriter<'_>,
) -> Result<(), EncodeError>
fn encode_terminal<'a>( key: &<Str as ObjectFieldValue>::In<'a>, writer: &mut ReverseSliceWriter<'_>, ) -> Result<(), EncodeError>
Encode the key segment as the terminal segment.
Source§fn decode<'a>(
reader: &mut &'a [u8],
memory_manager: &'a MemoryManager,
) -> Result<<Str as ObjectFieldValue>::Out<'a>, DecodeError>
fn decode<'a>( reader: &mut &'a [u8], memory_manager: &'a MemoryManager, ) -> Result<<Str as ObjectFieldValue>::Out<'a>, DecodeError>
Decode the key segment as a non-terminal segment.
Source§fn decode_terminal<'a>(
reader: &mut &'a [u8],
memory_manager: &'a MemoryManager,
) -> Result<<Str as ObjectFieldValue>::Out<'a>, DecodeError>
fn decode_terminal<'a>( reader: &mut &'a [u8], memory_manager: &'a MemoryManager, ) -> Result<<Str as ObjectFieldValue>::Out<'a>, DecodeError>
Decode the key segment as the terminal segment.
Source§fn out_size<'a>(key: &<Str as ObjectFieldValue>::In<'a>) -> usize
fn out_size<'a>(key: &<Str as ObjectFieldValue>::In<'a>) -> usize
Get the size of the key segment as a non-terminal segment.
Source§fn out_size_terminal<'a>(key: &<Str as ObjectFieldValue>::In<'a>) -> usize
fn out_size_terminal<'a>(key: &<Str as ObjectFieldValue>::In<'a>) -> usize
Get the size of the key segment as the terminal segment.
Auto Trait Implementations§
impl Freeze for Str
impl RefUnwindSafe for Str
impl Send for Str
impl Sync for Str
impl Unpin for Str
impl UnwindSafe for Str
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
Source§impl<A> ObjectKey for Awhere
A: KeyFieldValue,
impl<A> ObjectKey for Awhere
A: KeyFieldValue,
Source§fn encode<'a>(
key: &<A as ObjectValue>::In<'a>,
writer: &mut ReverseSliceWriter<'_>,
) -> Result<(), EncodeError>
fn encode<'a>( key: &<A as ObjectValue>::In<'a>, writer: &mut ReverseSliceWriter<'_>, ) -> Result<(), EncodeError>
Encode the key.
Source§fn decode<'a>(
input: &'a [u8],
memory_manager: &'a MemoryManager,
) -> Result<<A as ObjectValue>::Out<'a>, DecodeError>
fn decode<'a>( input: &'a [u8], memory_manager: &'a MemoryManager, ) -> Result<<A as ObjectValue>::Out<'a>, DecodeError>
Decode the key.
Source§impl<A> ObjectValue for Awhere
A: ObjectFieldValue,
impl<A> ObjectValue for Awhere
A: ObjectFieldValue,
Source§const PSEUDO_TYPE: StructType<'static>
const PSEUDO_TYPE: StructType<'static>
The associated “pseudo-struct” type for the object value.
Source§type FieldTypes<'a> = (<<A as ObjectFieldValue>::In<'a> as SchemaValue<'a>>::Type,)
type FieldTypes<'a> = (<<A as ObjectFieldValue>::In<'a> as SchemaValue<'a>>::Type,)
The object value types as field types.
Source§type In<'a> = <A as ObjectFieldValue>::In<'a>
type In<'a> = <A as ObjectFieldValue>::In<'a>
The type that is used when inputting object values to functions.
Source§type Out<'a> = <A as ObjectFieldValue>::Out<'a>
type Out<'a> = <A as ObjectFieldValue>::Out<'a>
The type that is used in function return values.
Source§fn encode<'a>(
value: &<A as ObjectValue>::In<'a>,
encoder: &mut dyn Encoder,
) -> Result<(), EncodeError>
fn encode<'a>( value: &<A as ObjectValue>::In<'a>, encoder: &mut dyn Encoder, ) -> Result<(), EncodeError>
Encode each part of the value in reverse order.
Source§fn decode<'a>(
decoder: &mut dyn Decoder<'a>,
mem: &'a MemoryManager,
) -> Result<<A as ObjectValue>::Out<'a>, DecodeError>
fn decode<'a>( decoder: &mut dyn Decoder<'a>, mem: &'a MemoryManager, ) -> Result<<A as ObjectValue>::Out<'a>, DecodeError>
Decode the value from the decoder.