Struct zenoh_protocol::io::SharedMemoryBuf [−][src]
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]
fn clone(&self) -> Self
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Drop for SharedMemoryBuf
[src]
impl From<SharedMemoryBuf> for RBuf
[src]
fn from(smb: SharedMemoryBuf) -> RBuf
[src]
Auto Trait Implementations
impl RefUnwindSafe for SharedMemoryBuf
[src]
impl Send for SharedMemoryBuf
[src]
impl Sync for SharedMemoryBuf
[src]
impl Unpin for SharedMemoryBuf
[src]
impl UnwindSafe for SharedMemoryBuf
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,