Struct zenoh_protocol::io::SharedMemoryBuf[][src]

pub struct SharedMemoryBuf { /* fields omitted */ }

Implementations

impl SharedMemoryBuf[src]

pub fn get_kind(&self) -> u8[src]

pub fn set_kind(&mut self, v: u8)[src]

pub fn owner(&self) -> String[src]

pub fn ref_count(&self) -> usize[src]

pub fn inc_ref_count(&self)[src]

pub fn dec_ref_count(&self)[src]

pub fn as_slice(&self) -> &[u8][src]

pub unsafe fn as_mut_slice(&mut self) -> &mut [u8][src]

Get a mutable slice.

Safety

This operation is marked unsafe since we cannot guarantee the single mutable reference across multiple processes. Thus if you use it, and you'll inevitable have to use it, you have to keep in mind that if you have multiple process retrieving a mutable slice you may get into concurrent writes. That said, if you have a serial pipeline and the buffer is flowing through the pipeline this will not create any issues.

In short, whilst this operation is marked as unsafe, you are safe if you can guarantee that your in applications only one process at the time will actually write.

Trait Implementations

impl Clone for SharedMemoryBuf[src]

impl Drop for SharedMemoryBuf[src]

impl From<SharedMemoryBuf> for RBuf[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,