pub struct NewEvent<B> {
pub event_id: Option<EventId>,
pub event_type: EventType,
pub schema_version: u32,
pub metadata: Metadata,
pub body: B,
}Expand description
One event to be appended, carrying a typed payload B.
Fields§
§event_id: Option<EventId>Caller-supplied event identity; if None, the engine generates one.
event_type: EventTypeThe event’s type tag.
schema_version: u32Schema version of the payload under event_type.
metadata: MetadataEngine metadata attached to the event (reserved keys are prefixed
salamander.).
body: BThe application payload.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<B> Freeze for NewEvent<B>where
B: Freeze,
impl<B> RefUnwindSafe for NewEvent<B>where
B: RefUnwindSafe,
impl<B> Send for NewEvent<B>where
B: Send,
impl<B> Sync for NewEvent<B>where
B: Sync,
impl<B> Unpin for NewEvent<B>where
B: Unpin,
impl<B> UnsafeUnpin for NewEvent<B>where
B: UnsafeUnpin,
impl<B> UnwindSafe for NewEvent<B>where
B: UnwindSafe,
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