mangadex_api/v5/upload/upload_session_id/
upload_session_file_id.rs

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
pub mod delete;

use self::delete::DeleteImageBuilder;

use crate::HttpClientRef;

use uuid::Uuid;

/// Statistics endpoint handler builder.
#[derive(Clone, Debug)]
pub struct UploadSessionFileEndpoint {
    http_client: HttpClientRef,
    upload_session_id: Uuid,
    upload_session_file_id: Uuid,
}

impl UploadSessionFileEndpoint {
    #[doc(hidden)]
    pub(crate) fn new(
        http_client: HttpClientRef,
        upload_session_id: Uuid,
        upload_session_file_id: Uuid,
    ) -> Self {
        Self {
            http_client,
            upload_session_id,
            upload_session_file_id,
        }
    }
    pub fn delete(&self) -> DeleteImageBuilder {
        DeleteImageBuilder::default()
            .session_id(self.upload_session_id)
            .session_file_id(self.upload_session_file_id)
            .http_client(self.http_client.clone())
    }
}