#[repr(u8)]pub enum BufferStrategyKind {
CallerAllocated = 0,
PluginAllocated = 1,
Arena = 2,
}Expand description
Buffer management strategy for an interface.
Selected per-trait via #[plugin_interface(buffer = ...)].
Determines the FFI function pointer signatures in the vtable.
Variants§
CallerAllocated = 0
Host allocates output buffer; plugin writes into it.
Returns -1 with needed size if buffer is too small.
PluginAllocated = 1
Plugin allocates output; host frees via PluginDescriptor::free_buffer.
Arena = 2
Host provides a pre-allocated arena; plugin writes into it. Data is valid only until the next call.
Trait Implementations§
Source§impl Clone for BufferStrategyKind
impl Clone for BufferStrategyKind
Source§fn clone(&self) -> BufferStrategyKind
fn clone(&self) -> BufferStrategyKind
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BufferStrategyKind
impl Debug for BufferStrategyKind
Source§impl Display for BufferStrategyKind
impl Display for BufferStrategyKind
Source§impl PartialEq for BufferStrategyKind
impl PartialEq for BufferStrategyKind
impl Copy for BufferStrategyKind
impl Eq for BufferStrategyKind
impl StructuralPartialEq for BufferStrategyKind
Auto Trait Implementations§
impl Freeze for BufferStrategyKind
impl RefUnwindSafe for BufferStrategyKind
impl Send for BufferStrategyKind
impl Sync for BufferStrategyKind
impl Unpin for BufferStrategyKind
impl UnsafeUnpin for BufferStrategyKind
impl UnwindSafe for BufferStrategyKind
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.