pub struct NodeAttempt { /* private fields */ }Expand description
Fully restored physical node attempt, executing or terminal.
Implementations§
Source§impl NodeAttempt
impl NodeAttempt
Sourcepub const fn executing(start: NodeAttemptStart) -> Self
pub const fn executing(start: NodeAttemptStart) -> Self
Constructs an executing attempt from its durable start.
Sourcepub fn restore(
start: NodeAttemptStart,
completion: Option<NodeAttemptCompletion>,
) -> Result<Self, NodeAttemptError>
pub fn restore( start: NodeAttemptStart, completion: Option<NodeAttemptCompletion>, ) -> Result<Self, NodeAttemptError>
Restores an attempt and verifies the exact start/completion join.
§Errors
Returns NodeAttemptError::CompletionStartMismatch when completion
belongs to another physical attempt.
Sourcepub const fn start(&self) -> &NodeAttemptStart
pub const fn start(&self) -> &NodeAttemptStart
Returns the immutable durable start.
Sourcepub const fn completion(&self) -> Option<&NodeAttemptCompletion>
pub const fn completion(&self) -> Option<&NodeAttemptCompletion>
Returns the optional terminal completion.
Sourcepub const fn status(&self) -> NodeAttemptStatus
pub const fn status(&self) -> NodeAttemptStatus
Returns the current lifecycle state.
Trait Implementations§
Source§impl Clone for NodeAttempt
impl Clone for NodeAttempt
Source§impl Debug for NodeAttempt
impl Debug for NodeAttempt
Source§impl<'de> Deserialize<'de> for NodeAttempt
impl<'de> Deserialize<'de> for NodeAttempt
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 JsonSchema for NodeAttempt
impl JsonSchema for NodeAttempt
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for NodeAttempt
impl !UnwindSafe for NodeAttempt
impl Forget for NodeAttempt
impl Freeze for NodeAttempt
impl Move for NodeAttempt
impl Send for NodeAttempt
impl Sync for NodeAttempt
impl Unpin for NodeAttempt
impl UnsafeUnpin for NodeAttempt
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