pub struct RustWriteVec { /* private fields */ }Expand description
A DiplomatWrite backed by a Vec, for convenient use in Rust.
Implementations§
Source§impl RustWriteVec
impl RustWriteVec
Sourcepub fn with_capacity(cap: usize) -> Self
pub fn with_capacity(cap: usize) -> Self
Creates a new RustWriteVec with the given initial buffer capacity.
Sourcepub fn borrow(&self) -> &DiplomatWrite
pub fn borrow(&self) -> &DiplomatWrite
Borrows the underlying DiplomatWrite.
Sourcepub unsafe fn borrow_mut(&mut self) -> &mut DiplomatWrite
pub unsafe fn borrow_mut(&mut self) -> &mut DiplomatWrite
Mutably borrows the underlying DiplomatWrite.
§Safety
The contents of the returned pointer MUST NOT be swapped with another instance
of DiplomatWrite that may have been created from a different source. This
requirement is satisfied if this is the only instance of DiplomatWrite
in scope.
For more information, see DiplomatWrite.
Trait Implementations§
Source§impl Borrow<DiplomatWrite> for RustWriteVec
impl Borrow<DiplomatWrite> for RustWriteVec
Source§fn borrow(&self) -> &DiplomatWrite
fn borrow(&self) -> &DiplomatWrite
Immutably borrows from an owned value. Read more
Auto Trait Implementations§
impl Freeze for RustWriteVec
impl RefUnwindSafe for RustWriteVec
impl !Send for RustWriteVec
impl !Sync for RustWriteVec
impl Unpin for RustWriteVec
impl UnwindSafe for RustWriteVec
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