#[repr(C)]pub struct moq_string {
pub data: *const c_char,
pub len: usize,
}Expand description
A borrowed UTF-8 string slice, NOT NULL terminated.
Used in both directions. As an output (e.g. a JSON document libmoq hands back) the pointer borrows libmoq’s own storage and is only valid until the owning resource is freed; see the function that fills it for the exact lifetime. As an input (e.g. a moq_client_config list) the pointer borrows the caller’s storage and is only read during the call.
Fields§
§data: *const c_charPointer to len bytes of UTF-8, NOT NULL terminated.
len: usizeTrait Implementations§
Source§impl Clone for moq_string
impl Clone for moq_string
impl Copy for moq_string
Auto Trait Implementations§
impl !Send for moq_string
impl !Sync for moq_string
impl Freeze for moq_string
impl RefUnwindSafe for moq_string
impl Unpin for moq_string
impl UnsafeUnpin for moq_string
impl UnwindSafe for moq_string
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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