pub struct WorkflowViewState {
pub workflow_def: Option<WorkflowDef>,
pub context: Option<WorkflowContext>,
pub layout: DagLayout,
pub visible: bool,
pub selected_node: Option<String>,
pub view_mode: WorkflowViewMode,
pub spinner_frame: usize,
}Expand description
Workflow visualization state
Fields§
§workflow_def: Option<WorkflowDef>Current workflow definition (for DAG structure)
context: Option<WorkflowContext>Execution context (for status)
layout: DagLayoutVisual layout cache
visible: boolPanel visibility
selected_node: Option<String>Selected node (for inspection)
view_mode: WorkflowViewModeView mode
spinner_frame: usizeSpinner frame for running nodes
Implementations§
Source§impl WorkflowViewState
impl WorkflowViewState
Sourcepub fn set_workflow(&mut self, def: WorkflowDef)
pub fn set_workflow(&mut self, def: WorkflowDef)
Update from workflow definition
Sourcepub fn update_context(&mut self, context: WorkflowContext)
pub fn update_context(&mut self, context: WorkflowContext)
Update from execution context
Sourcepub fn load_recent_instances(
project_dir: Option<&PathBuf>,
) -> Vec<WorkflowContext>
pub fn load_recent_instances( project_dir: Option<&PathBuf>, ) -> Vec<WorkflowContext>
Load workflow instances from persistence Returns a list of recent workflow contexts (most recent first)
Sourcepub fn load_workflow_def(
project_dir: Option<&PathBuf>,
workflow_id: &str,
) -> Option<WorkflowDef>
pub fn load_workflow_def( project_dir: Option<&PathBuf>, workflow_id: &str, ) -> Option<WorkflowDef>
Load workflow definition from registry
Sourcepub fn load_most_recent(&mut self, project_dir: Option<&PathBuf>)
pub fn load_most_recent(&mut self, project_dir: Option<&PathBuf>)
Load and display the most recent workflow instance
Sourcepub fn get_node_status(&self, node_id: &str) -> NodeVisualStatus
pub fn get_node_status(&self, node_id: &str) -> NodeVisualStatus
Get node visual status
Sourcepub fn advance_spinner(&mut self)
pub fn advance_spinner(&mut self)
Advance spinner frame
Sourcepub fn spinner_char(&self) -> char
pub fn spinner_char(&self) -> char
Get spinner char for current frame
Trait Implementations§
Auto Trait Implementations§
impl Freeze for WorkflowViewState
impl RefUnwindSafe for WorkflowViewState
impl Send for WorkflowViewState
impl Sync for WorkflowViewState
impl Unpin for WorkflowViewState
impl UnsafeUnpin for WorkflowViewState
impl UnwindSafe for WorkflowViewState
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
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