Timer
查看 MarkdownThis page lists the Rust SDK names for Timers. The doc comment of each API gives its parameters, defaults, and errors. Read them in the Rust SDK API reference.
API names
| Task | Rust API | Dex behavior |
|---|---|---|
| Wait for a duration | Timer::by_duration in wait_for | Firing time |
| Give the Timer a stable ID | Condition::with_id on the Timer condition | AnyCombinationOf |
| Combine a Timer with other conditions | Wait::any_of, Wait::all_of, and Wait::any_combination_of | Waits |
| Check whether a Timer fired | Context::has_timer_fired and Context::has_any_timer_fired in execute | Condition results |
| Make a waiting Timer ready now | Client::skip_timer, with StepExecutionId and TimerId | Skip a Timer |