aws_sdk_fsx/operation/delete_backup/
_delete_backup_input.rs1#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct DeleteBackupInput {
7 pub backup_id: ::std::option::Option<::std::string::String>,
9 pub client_request_token: ::std::option::Option<::std::string::String>,
11}
12impl DeleteBackupInput {
13 pub fn backup_id(&self) -> ::std::option::Option<&str> {
15 self.backup_id.as_deref()
16 }
17 pub fn client_request_token(&self) -> ::std::option::Option<&str> {
19 self.client_request_token.as_deref()
20 }
21}
22impl DeleteBackupInput {
23 pub fn builder() -> crate::operation::delete_backup::builders::DeleteBackupInputBuilder {
25 crate::operation::delete_backup::builders::DeleteBackupInputBuilder::default()
26 }
27}
28
29#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
31#[non_exhaustive]
32pub struct DeleteBackupInputBuilder {
33 pub(crate) backup_id: ::std::option::Option<::std::string::String>,
34 pub(crate) client_request_token: ::std::option::Option<::std::string::String>,
35}
36impl DeleteBackupInputBuilder {
37 pub fn backup_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
40 self.backup_id = ::std::option::Option::Some(input.into());
41 self
42 }
43 pub fn set_backup_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
45 self.backup_id = input;
46 self
47 }
48 pub fn get_backup_id(&self) -> &::std::option::Option<::std::string::String> {
50 &self.backup_id
51 }
52 pub fn client_request_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
54 self.client_request_token = ::std::option::Option::Some(input.into());
55 self
56 }
57 pub fn set_client_request_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
59 self.client_request_token = input;
60 self
61 }
62 pub fn get_client_request_token(&self) -> &::std::option::Option<::std::string::String> {
64 &self.client_request_token
65 }
66 pub fn build(
68 self,
69 ) -> ::std::result::Result<crate::operation::delete_backup::DeleteBackupInput, ::aws_smithy_types::error::operation::BuildError> {
70 ::std::result::Result::Ok(crate::operation::delete_backup::DeleteBackupInput {
71 backup_id: self.backup_id,
72 client_request_token: self.client_request_token,
73 })
74 }
75}