Skip to main content

print_step

Function print_step 

Source
pub fn print_step(step: &str, success: bool, duration: Duration)
Expand description

Display a single initialization step with status and timing

Prints a formatted line showing a step name, success/failure status, and elapsed tim in milliseconds.

§Arguments

  • step - A string describing the initialization step being performed.
  • success - A boolean indicating whether the step succeeded (true) or failed (false).
  • duration_ms - The time taken to complete the step, in milliseconds.

§Example

let timer = create_timer();
print_step("Initializing database", true, elapsed_ms(timer));