1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
//! Provides a way to manager asynchronous tasks.
//!
//! See [`examples/counter`](https://github.com/Umatriz/egui-task-manager/blob/master/examples/counter/src/main.rs)
//! for more information.
//!
//! ## [`TaskManager`]
//!
//! The [`TaskManager`] is a core type that you must save in your app's state. Call [`TaskManager::add_collection`]
//! to register a new collection. And then call [`TaskManager::push_task`] when you want to add a new task.
//!
//! ## [`TasksCollection`] and [`CollectionData`]
//!
//! [`TasksCollection`] can be implemented for a type and then this type might be used as a type parameter
//! for several methods.
//!
//! [`CollectionData`] is a "dynamic" version of a type that implements [`TasksCollection`] although
//! not totally. It holds collection's name and executor. And in addition to this holds currently
//! running tasks and channel that receives data that tasks yield.
//!
//! ## [`Task`] and [`Caller`]
//!
//! [`Task`] has name and [`Caller`]. [`Caller`] can be either [`Standard`](Caller::Standard) or
//! [`Progressing`](Caller::Progressing).
//!
//! [`Caller::standard`] expects a future.
//!
//! [`Caller::progressing`] expects a closure with an argument of type [`TaskProgressShared`].
//! This type provides functionality for progress tracking and functions such [`TaskProgressShared::set_total`]
//! and [`TaskProgressShared::update`]. Which allows you to track your progress.
//!
//! For more information about progress see [`TaskProgressShared`].
//!
//! ## [`TaskExecutor`]
//!
//! A trait that determines task's execution.
pub use *;
pub use *;
pub use *;
pub use *;
/// Provides several functions and a macro to setup the runtime.
///
/// Most of the time you just need to call the macro and it will do everything for you.
/// ```rust
/// egui_task_manager::setup!();
/// ```