#[non_exhaustive]pub enum ToolInvocationCommitOutcome {
Committed {
event: JournalEvent,
invocation: ToolInvocation,
},
Idempotent {
event: JournalEvent,
invocation: ToolInvocation,
},
}Expand description
Result of atomically committing a journal event and tool invocation revision.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Committed
A new event and immutable invocation revision committed atomically.
Fields
§
event: JournalEventNewly committed journal event.
§
invocation: ToolInvocationNewly committed invocation revision.
Idempotent
The exact event and invocation mutation had already committed.
Fields
§
event: JournalEventPreviously committed journal event.
§
invocation: ToolInvocationPreviously committed invocation revision.
Implementations§
Source§impl ToolInvocationCommitOutcome
impl ToolInvocationCommitOutcome
Sourcepub const fn event(&self) -> &JournalEvent
pub const fn event(&self) -> &JournalEvent
Returns the validated anchoring journal event.
Sourcepub const fn invocation(&self) -> &ToolInvocation
pub const fn invocation(&self) -> &ToolInvocation
Returns the validated immutable invocation revision.
Trait Implementations§
Source§impl Clone for ToolInvocationCommitOutcome
impl Clone for ToolInvocationCommitOutcome
Auto Trait Implementations§
impl !RefUnwindSafe for ToolInvocationCommitOutcome
impl !UnwindSafe for ToolInvocationCommitOutcome
impl Forget for ToolInvocationCommitOutcome
impl Freeze for ToolInvocationCommitOutcome
impl Move for ToolInvocationCommitOutcome
impl Send for ToolInvocationCommitOutcome
impl Sync for ToolInvocationCommitOutcome
impl Unpin for ToolInvocationCommitOutcome
impl UnsafeUnpin for ToolInvocationCommitOutcome
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more