[−][src]Module cratetorrent::engine
The engine is the top-level coordinator that runs and manages all entities
in the torrent engine. The user interacts with the engine via the
EngineHandle
which exposes a restricted public API. The underlying
communication method is tokio mpsc
channels.
The engine is spawned as a tokio task and runs in the background. As with spawning other tokio tasks, it must be done within the context of a tokio executor.
The engine is run until an unrecoverable error occurs, or until the user sends a shutdown command.
For usage examples, see the library documentation.
Structs
EngineHandle | A handle to the currently running torrent engine. |
TorrentParams | Information for creating a new torrent. |
Enums
Mode | The download mode. |
Functions
spawn | Spawns the engine as a tokio task. |