Struct libpd_sys::ring_buffer
source · [−]#[repr(C)]pub struct ring_buffer {
pub size: c_int,
pub buf_ptr: *mut c_char,
pub write_idx: c_int,
pub read_idx: c_int,
}Expand description
simple lock-free ring buffer implementation for one writer thread and one consumer thread
Fields
size: c_intbuf_ptr: *mut c_charwrite_idx: c_intread_idx: c_intTrait Implementations
sourceimpl Clone for ring_buffer
impl Clone for ring_buffer
sourcefn clone(&self) -> ring_buffer
fn clone(&self) -> ring_buffer
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for ring_buffer
impl Debug for ring_buffer
impl Copy for ring_buffer
Auto Trait Implementations
impl RefUnwindSafe for ring_buffer
impl !Send for ring_buffer
impl !Sync for ring_buffer
impl Unpin for ring_buffer
impl UnwindSafe for ring_buffer
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more