pub struct StepInfo<S: EngineSpec> {
pub id: S::StepId,
pub component: S::Component,
pub description: Cow<'static, str>,
pub index: usize,
pub component_index: usize,
pub total_component_steps: usize,
}Expand description
Serializable information about a step.
Fields§
§id: S::StepIdAn identifier for this step.
component: S::ComponentThe component that this step is part of.
description: Cow<'static, str>The description for this step.
index: usizeThe index of the step within all steps to be executed.
component_index: usizeThe index of the step within the component.
total_component_steps: usizeThe total number of steps in this component.
Implementations§
Source§impl<S: EngineSpec> StepInfo<S>
impl<S: EngineSpec> StepInfo<S>
Sourcepub fn is_last_step_in_component(&self) -> bool
pub fn is_last_step_in_component(&self) -> bool
Returns true if this is the last step in this component.
Sourcepub fn from_generic(
value: StepInfo<GenericSpec>,
) -> Result<Self, ConvertGenericError>
pub fn from_generic( value: StepInfo<GenericSpec>, ) -> Result<Self, ConvertGenericError>
Converts a generic version into self.
This version can be used to convert a generic type into a more concrete form.
Sourcepub fn into_generic(self) -> StepInfo<GenericSpec>
pub fn into_generic(self) -> StepInfo<GenericSpec>
Converts self into its generic version.
This version can be used to share data across different kinds of engines.
If any of the data in self fails to serialize to a
serde_json::Value, it will be replaced with
serde_json::Value::Null. Since serde_json::Value represents
an arbitrary JSON value, such data would have failed to serialize
anyway.
Trait Implementations§
Source§impl<S: EngineSpec> Clone for StepInfo<S>
impl<S: EngineSpec> Clone for StepInfo<S>
Source§impl<S: EngineSpec> Debug for StepInfo<S>
impl<S: EngineSpec> Debug for StepInfo<S>
Source§impl<'de, S: EngineSpec> Deserialize<'de> for StepInfo<S>
impl<'de, S: EngineSpec> Deserialize<'de> for StepInfo<S>
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>,
Source§impl<S> JsonSchema for StepInfo<S>where
S: JsonSchemaEngineSpec + EngineSpec,
impl<S> JsonSchema for StepInfo<S>where
S: JsonSchemaEngineSpec + EngineSpec,
Source§fn schema_name() -> String
fn schema_name() -> String
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
$ref keyword. Read moreSource§impl<S: EngineSpec> PartialEq for StepInfo<S>
impl<S: EngineSpec> PartialEq for StepInfo<S>
Source§impl<S: EngineSpec> Serialize for StepInfo<S>
impl<S: EngineSpec> Serialize for StepInfo<S>
impl<S: EngineSpec> Eq for StepInfo<S>
Auto Trait Implementations§
impl<S> Freeze for StepInfo<S>
impl<S> RefUnwindSafe for StepInfo<S>
impl<S> Send for StepInfo<S>
impl<S> Sync for StepInfo<S>
impl<S> Unpin for StepInfo<S>
impl<S> UnsafeUnpin for StepInfo<S>
impl<S> UnwindSafe for StepInfo<S>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.