aws_sdk_kendra/operation/describe_faq/
_describe_faq_output.rs1#[allow(missing_docs)] #[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct DescribeFaqOutput {
6 pub id: ::std::option::Option<::std::string::String>,
8 pub index_id: ::std::option::Option<::std::string::String>,
10 pub name: ::std::option::Option<::std::string::String>,
12 pub description: ::std::option::Option<::std::string::String>,
14 pub created_at: ::std::option::Option<::aws_smithy_types::DateTime>,
16 pub updated_at: ::std::option::Option<::aws_smithy_types::DateTime>,
18 pub s3_path: ::std::option::Option<crate::types::S3Path>,
20 pub status: ::std::option::Option<crate::types::FaqStatus>,
22 pub role_arn: ::std::option::Option<::std::string::String>,
24 pub error_message: ::std::option::Option<::std::string::String>,
26 pub file_format: ::std::option::Option<crate::types::FaqFileFormat>,
28 pub language_code: ::std::option::Option<::std::string::String>,
30 _request_id: Option<String>,
31}
32impl DescribeFaqOutput {
33 pub fn id(&self) -> ::std::option::Option<&str> {
35 self.id.as_deref()
36 }
37 pub fn index_id(&self) -> ::std::option::Option<&str> {
39 self.index_id.as_deref()
40 }
41 pub fn name(&self) -> ::std::option::Option<&str> {
43 self.name.as_deref()
44 }
45 pub fn description(&self) -> ::std::option::Option<&str> {
47 self.description.as_deref()
48 }
49 pub fn created_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
51 self.created_at.as_ref()
52 }
53 pub fn updated_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
55 self.updated_at.as_ref()
56 }
57 pub fn s3_path(&self) -> ::std::option::Option<&crate::types::S3Path> {
59 self.s3_path.as_ref()
60 }
61 pub fn status(&self) -> ::std::option::Option<&crate::types::FaqStatus> {
63 self.status.as_ref()
64 }
65 pub fn role_arn(&self) -> ::std::option::Option<&str> {
67 self.role_arn.as_deref()
68 }
69 pub fn error_message(&self) -> ::std::option::Option<&str> {
71 self.error_message.as_deref()
72 }
73 pub fn file_format(&self) -> ::std::option::Option<&crate::types::FaqFileFormat> {
75 self.file_format.as_ref()
76 }
77 pub fn language_code(&self) -> ::std::option::Option<&str> {
79 self.language_code.as_deref()
80 }
81}
82impl ::aws_types::request_id::RequestId for DescribeFaqOutput {
83 fn request_id(&self) -> Option<&str> {
84 self._request_id.as_deref()
85 }
86}
87impl DescribeFaqOutput {
88 pub fn builder() -> crate::operation::describe_faq::builders::DescribeFaqOutputBuilder {
90 crate::operation::describe_faq::builders::DescribeFaqOutputBuilder::default()
91 }
92}
93
94#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
96#[non_exhaustive]
97pub struct DescribeFaqOutputBuilder {
98 pub(crate) id: ::std::option::Option<::std::string::String>,
99 pub(crate) index_id: ::std::option::Option<::std::string::String>,
100 pub(crate) name: ::std::option::Option<::std::string::String>,
101 pub(crate) description: ::std::option::Option<::std::string::String>,
102 pub(crate) created_at: ::std::option::Option<::aws_smithy_types::DateTime>,
103 pub(crate) updated_at: ::std::option::Option<::aws_smithy_types::DateTime>,
104 pub(crate) s3_path: ::std::option::Option<crate::types::S3Path>,
105 pub(crate) status: ::std::option::Option<crate::types::FaqStatus>,
106 pub(crate) role_arn: ::std::option::Option<::std::string::String>,
107 pub(crate) error_message: ::std::option::Option<::std::string::String>,
108 pub(crate) file_format: ::std::option::Option<crate::types::FaqFileFormat>,
109 pub(crate) language_code: ::std::option::Option<::std::string::String>,
110 _request_id: Option<String>,
111}
112impl DescribeFaqOutputBuilder {
113 pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
115 self.id = ::std::option::Option::Some(input.into());
116 self
117 }
118 pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
120 self.id = input;
121 self
122 }
123 pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
125 &self.id
126 }
127 pub fn index_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
129 self.index_id = ::std::option::Option::Some(input.into());
130 self
131 }
132 pub fn set_index_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
134 self.index_id = input;
135 self
136 }
137 pub fn get_index_id(&self) -> &::std::option::Option<::std::string::String> {
139 &self.index_id
140 }
141 pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
143 self.name = ::std::option::Option::Some(input.into());
144 self
145 }
146 pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
148 self.name = input;
149 self
150 }
151 pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
153 &self.name
154 }
155 pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
157 self.description = ::std::option::Option::Some(input.into());
158 self
159 }
160 pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
162 self.description = input;
163 self
164 }
165 pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
167 &self.description
168 }
169 pub fn created_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
171 self.created_at = ::std::option::Option::Some(input);
172 self
173 }
174 pub fn set_created_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
176 self.created_at = input;
177 self
178 }
179 pub fn get_created_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
181 &self.created_at
182 }
183 pub fn updated_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
185 self.updated_at = ::std::option::Option::Some(input);
186 self
187 }
188 pub fn set_updated_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
190 self.updated_at = input;
191 self
192 }
193 pub fn get_updated_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
195 &self.updated_at
196 }
197 pub fn s3_path(mut self, input: crate::types::S3Path) -> Self {
199 self.s3_path = ::std::option::Option::Some(input);
200 self
201 }
202 pub fn set_s3_path(mut self, input: ::std::option::Option<crate::types::S3Path>) -> Self {
204 self.s3_path = input;
205 self
206 }
207 pub fn get_s3_path(&self) -> &::std::option::Option<crate::types::S3Path> {
209 &self.s3_path
210 }
211 pub fn status(mut self, input: crate::types::FaqStatus) -> Self {
213 self.status = ::std::option::Option::Some(input);
214 self
215 }
216 pub fn set_status(mut self, input: ::std::option::Option<crate::types::FaqStatus>) -> Self {
218 self.status = input;
219 self
220 }
221 pub fn get_status(&self) -> &::std::option::Option<crate::types::FaqStatus> {
223 &self.status
224 }
225 pub fn role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
227 self.role_arn = ::std::option::Option::Some(input.into());
228 self
229 }
230 pub fn set_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
232 self.role_arn = input;
233 self
234 }
235 pub fn get_role_arn(&self) -> &::std::option::Option<::std::string::String> {
237 &self.role_arn
238 }
239 pub fn error_message(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
241 self.error_message = ::std::option::Option::Some(input.into());
242 self
243 }
244 pub fn set_error_message(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
246 self.error_message = input;
247 self
248 }
249 pub fn get_error_message(&self) -> &::std::option::Option<::std::string::String> {
251 &self.error_message
252 }
253 pub fn file_format(mut self, input: crate::types::FaqFileFormat) -> Self {
255 self.file_format = ::std::option::Option::Some(input);
256 self
257 }
258 pub fn set_file_format(mut self, input: ::std::option::Option<crate::types::FaqFileFormat>) -> Self {
260 self.file_format = input;
261 self
262 }
263 pub fn get_file_format(&self) -> &::std::option::Option<crate::types::FaqFileFormat> {
265 &self.file_format
266 }
267 pub fn language_code(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
269 self.language_code = ::std::option::Option::Some(input.into());
270 self
271 }
272 pub fn set_language_code(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
274 self.language_code = input;
275 self
276 }
277 pub fn get_language_code(&self) -> &::std::option::Option<::std::string::String> {
279 &self.language_code
280 }
281 pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
282 self._request_id = Some(request_id.into());
283 self
284 }
285
286 pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
287 self._request_id = request_id;
288 self
289 }
290 pub fn build(self) -> crate::operation::describe_faq::DescribeFaqOutput {
292 crate::operation::describe_faq::DescribeFaqOutput {
293 id: self.id,
294 index_id: self.index_id,
295 name: self.name,
296 description: self.description,
297 created_at: self.created_at,
298 updated_at: self.updated_at,
299 s3_path: self.s3_path,
300 status: self.status,
301 role_arn: self.role_arn,
302 error_message: self.error_message,
303 file_format: self.file_format,
304 language_code: self.language_code,
305 _request_id: self._request_id,
306 }
307 }
308}