#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct Prompt {
pub prompt_arn: ::std::option::Option<::std::string::String>,
pub prompt_id: ::std::option::Option<::std::string::String>,
pub name: ::std::option::Option<::std::string::String>,
pub description: ::std::option::Option<::std::string::String>,
pub tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
pub last_modified_time: ::std::option::Option<::aws_smithy_types::DateTime>,
pub last_modified_region: ::std::option::Option<::std::string::String>,
}
impl Prompt {
pub fn prompt_arn(&self) -> ::std::option::Option<&str> {
self.prompt_arn.as_deref()
}
pub fn prompt_id(&self) -> ::std::option::Option<&str> {
self.prompt_id.as_deref()
}
pub fn name(&self) -> ::std::option::Option<&str> {
self.name.as_deref()
}
pub fn description(&self) -> ::std::option::Option<&str> {
self.description.as_deref()
}
pub fn tags(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
self.tags.as_ref()
}
pub fn last_modified_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.last_modified_time.as_ref()
}
pub fn last_modified_region(&self) -> ::std::option::Option<&str> {
self.last_modified_region.as_deref()
}
}
impl Prompt {
pub fn builder() -> crate::types::builders::PromptBuilder {
crate::types::builders::PromptBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct PromptBuilder {
pub(crate) prompt_arn: ::std::option::Option<::std::string::String>,
pub(crate) prompt_id: ::std::option::Option<::std::string::String>,
pub(crate) name: ::std::option::Option<::std::string::String>,
pub(crate) description: ::std::option::Option<::std::string::String>,
pub(crate) tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
pub(crate) last_modified_time: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) last_modified_region: ::std::option::Option<::std::string::String>,
}
impl PromptBuilder {
pub fn prompt_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.prompt_arn = ::std::option::Option::Some(input.into());
self
}
pub fn set_prompt_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.prompt_arn = input;
self
}
pub fn get_prompt_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.prompt_arn
}
pub fn prompt_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.prompt_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_prompt_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.prompt_id = input;
self
}
pub fn get_prompt_id(&self) -> &::std::option::Option<::std::string::String> {
&self.prompt_id
}
pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.name = ::std::option::Option::Some(input.into());
self
}
pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.name = input;
self
}
pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
&self.name
}
pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.description = ::std::option::Option::Some(input.into());
self
}
pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.description = input;
self
}
pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
&self.description
}
pub fn tags(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut hash_map = self.tags.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.tags = ::std::option::Option::Some(hash_map);
self
}
pub fn set_tags(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
self.tags = input;
self
}
pub fn get_tags(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
&self.tags
}
pub fn last_modified_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.last_modified_time = ::std::option::Option::Some(input);
self
}
pub fn set_last_modified_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.last_modified_time = input;
self
}
pub fn get_last_modified_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.last_modified_time
}
pub fn last_modified_region(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.last_modified_region = ::std::option::Option::Some(input.into());
self
}
pub fn set_last_modified_region(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.last_modified_region = input;
self
}
pub fn get_last_modified_region(&self) -> &::std::option::Option<::std::string::String> {
&self.last_modified_region
}
pub fn build(self) -> crate::types::Prompt {
crate::types::Prompt {
prompt_arn: self.prompt_arn,
prompt_id: self.prompt_id,
name: self.name,
description: self.description,
tags: self.tags,
last_modified_time: self.last_modified_time,
last_modified_region: self.last_modified_region,
}
}
}