eureka-mmanager 0.3.2

An Actix actor collection for downloading manga, chapters, covers from Mangadex
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use actix::prelude::*;

use crate::{download::state::DownloadManagerState, DirsOptions};

#[derive(Debug, Clone, Copy, Default)]
pub struct GetDirsOptionsMessage;

impl Message for GetDirsOptionsMessage {
    type Result = Addr<DirsOptions>;
}

impl Handler<GetDirsOptionsMessage> for DownloadManagerState {
    type Result = <GetDirsOptionsMessage as Message>::Result;
    fn handle(&mut self, _msg: GetDirsOptionsMessage, _ctx: &mut Self::Context) -> Self::Result {
        self.dir_option.clone()
    }
}