aws_sdk_lexmodelsv2/operation/delete_intent/
_delete_intent_input.rs1#[allow(missing_docs)] #[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct DeleteIntentInput {
6 pub intent_id: ::std::option::Option<::std::string::String>,
8 pub bot_id: ::std::option::Option<::std::string::String>,
10 pub bot_version: ::std::option::Option<::std::string::String>,
12 pub locale_id: ::std::option::Option<::std::string::String>,
14}
15impl DeleteIntentInput {
16 pub fn intent_id(&self) -> ::std::option::Option<&str> {
18 self.intent_id.as_deref()
19 }
20 pub fn bot_id(&self) -> ::std::option::Option<&str> {
22 self.bot_id.as_deref()
23 }
24 pub fn bot_version(&self) -> ::std::option::Option<&str> {
26 self.bot_version.as_deref()
27 }
28 pub fn locale_id(&self) -> ::std::option::Option<&str> {
30 self.locale_id.as_deref()
31 }
32}
33impl DeleteIntentInput {
34 pub fn builder() -> crate::operation::delete_intent::builders::DeleteIntentInputBuilder {
36 crate::operation::delete_intent::builders::DeleteIntentInputBuilder::default()
37 }
38}
39
40#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
42#[non_exhaustive]
43pub struct DeleteIntentInputBuilder {
44 pub(crate) intent_id: ::std::option::Option<::std::string::String>,
45 pub(crate) bot_id: ::std::option::Option<::std::string::String>,
46 pub(crate) bot_version: ::std::option::Option<::std::string::String>,
47 pub(crate) locale_id: ::std::option::Option<::std::string::String>,
48}
49impl DeleteIntentInputBuilder {
50 pub fn intent_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
53 self.intent_id = ::std::option::Option::Some(input.into());
54 self
55 }
56 pub fn set_intent_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
58 self.intent_id = input;
59 self
60 }
61 pub fn get_intent_id(&self) -> &::std::option::Option<::std::string::String> {
63 &self.intent_id
64 }
65 pub fn bot_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
68 self.bot_id = ::std::option::Option::Some(input.into());
69 self
70 }
71 pub fn set_bot_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
73 self.bot_id = input;
74 self
75 }
76 pub fn get_bot_id(&self) -> &::std::option::Option<::std::string::String> {
78 &self.bot_id
79 }
80 pub fn bot_version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
83 self.bot_version = ::std::option::Option::Some(input.into());
84 self
85 }
86 pub fn set_bot_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
88 self.bot_version = input;
89 self
90 }
91 pub fn get_bot_version(&self) -> &::std::option::Option<::std::string::String> {
93 &self.bot_version
94 }
95 pub fn locale_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
98 self.locale_id = ::std::option::Option::Some(input.into());
99 self
100 }
101 pub fn set_locale_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
103 self.locale_id = input;
104 self
105 }
106 pub fn get_locale_id(&self) -> &::std::option::Option<::std::string::String> {
108 &self.locale_id
109 }
110 pub fn build(
112 self,
113 ) -> ::std::result::Result<crate::operation::delete_intent::DeleteIntentInput, ::aws_smithy_types::error::operation::BuildError> {
114 ::std::result::Result::Ok(crate::operation::delete_intent::DeleteIntentInput {
115 intent_id: self.intent_id,
116 bot_id: self.bot_id,
117 bot_version: self.bot_version,
118 locale_id: self.locale_id,
119 })
120 }
121}