pub enum CopyReason {
HostToComponent,
ComponentToHost,
CrossComponent,
PoolReturn,
}Expand description
The reason a data copy occurred, for copy accounting and observability.
Per Doc 05, Section 9.1 (EventSink::record_copy). This is the
torvyn-types version; Doc 05 defines additional observability-specific
variants. This crate provides the shared subset.
§Examples
use torvyn_types::CopyReason;
let reason = CopyReason::HostToComponent;
assert_eq!(format!("{}", reason), "HostToComponent");Variants§
HostToComponent
Data must enter component linear memory for processing.
ComponentToHost
Data is extracted from component linear memory after processing.
CrossComponent
Data is transferred between components (involves a host intermediary).
PoolReturn
Buffer contents are copied when returning to the pool.
Trait Implementations§
Source§impl Clone for CopyReason
impl Clone for CopyReason
Source§fn clone(&self) -> CopyReason
fn clone(&self) -> CopyReason
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 CopyReason
impl Debug for CopyReason
Source§impl<'de> Deserialize<'de> for CopyReason
impl<'de> Deserialize<'de> for CopyReason
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for CopyReason
impl Display for CopyReason
Source§impl Hash for CopyReason
impl Hash for CopyReason
Source§impl PartialEq for CopyReason
impl PartialEq for CopyReason
Source§impl Serialize for CopyReason
impl Serialize for CopyReason
impl Copy for CopyReason
impl Eq for CopyReason
impl StructuralPartialEq for CopyReason
Auto Trait Implementations§
impl Freeze for CopyReason
impl RefUnwindSafe for CopyReason
impl Send for CopyReason
impl Sync for CopyReason
impl Unpin for CopyReason
impl UnwindSafe for CopyReason
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