pub struct StepNode {
pub id: usize,
pub label: String,
pub duration_us: u64,
pub outcome: StepOutcome,
}Expand description
A node in the async step graph.
§Examples
use async_reify::{StepNode, StepOutcome};
let node = StepNode {
id: 0,
label: "fetch_data".to_string(),
duration_us: 150,
outcome: StepOutcome::Completed,
};
assert_eq!(node.id, 0);Fields§
§id: usizeUnique step identifier.
label: StringHuman-readable label for this step.
duration_us: u64Duration of this step in microseconds.
outcome: StepOutcomeHow this step concluded.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for StepNode
impl<'de> Deserialize<'de> for StepNode
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<StepNode, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<StepNode, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for StepNode
impl Serialize for StepNode
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for StepNode
impl RefUnwindSafe for StepNode
impl Send for StepNode
impl Sync for StepNode
impl Unpin for StepNode
impl UnsafeUnpin for StepNode
impl UnwindSafe for StepNode
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