melvin_ob/http_handler/http_request/
restore_backup_put.rs

1use super::request_common::{HTTPRequestMethod, HTTPRequestType, NoBodyHTTPRequestType};
2use super::restore_backup;
3
4/// Request type for the /backup endpoint -> PUT.
5#[derive(Debug)]
6#[cfg(debug_assertions)]
7pub struct RestoreBackupRequest {}
8
9impl NoBodyHTTPRequestType for RestoreBackupRequest {}
10
11impl HTTPRequestType for RestoreBackupRequest {
12    /// Type of the expected response.
13    type Response = restore_backup::RestoreBackupResponse;
14    /// `str` object representing the specific endpoint.
15    fn endpoint(&self) -> &'static str { "/backup" }
16    /// The corresponding HTTP Request Method.
17    fn request_method(&self) -> HTTPRequestMethod { HTTPRequestMethod::Put }
18}