Skip to main content

generate_hub_tasks_rs

Function generate_hub_tasks_rs 

Source
pub fn generate_hub_tasks_rs(state: &ArchitectureState) -> String
Expand description

Generate src/tasks.rs stub for the hub binary crate.

This file is generated once — it is not overwritten if it already exists. Task handler signatures are derived from [[tasks]] in state.toml:

InputsOutputsAPIGenerated stub
N > 1≥ 1.transform_join()fn task_handler(JoinTrigger, &mut (), &Producer<O, R>)
1≥ 1.transform().map()fn task_transform(&Input) -> Option<Output>
0≥ 1.source()async fn task(RuntimeContext, Producer<O, R>)
≥ 10.tap()async fn task(RuntimeContext, Consumer<I, R>)