#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq)]
pub struct UpdateAgentInput {
pub agent_id: ::std::option::Option<::std::string::String>,
pub aws_account_id: ::std::option::Option<::std::string::String>,
pub name: ::std::option::Option<::std::string::String>,
pub description: ::std::option::Option<::std::string::String>,
pub icon_id: ::std::option::Option<::std::string::String>,
pub starter_prompts: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub welcome_message: ::std::option::Option<::std::string::String>,
pub custom_prompt_input: ::std::option::Option<crate::types::CustomPromptInput>,
pub spaces_to_add: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub spaces_to_remove: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub action_connectors_to_add: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub action_connectors_to_remove: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
}
impl UpdateAgentInput {
pub fn agent_id(&self) -> ::std::option::Option<&str> {
self.agent_id.as_deref()
}
pub fn aws_account_id(&self) -> ::std::option::Option<&str> {
self.aws_account_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 icon_id(&self) -> ::std::option::Option<&str> {
self.icon_id.as_deref()
}
pub fn starter_prompts(&self) -> &[::std::string::String] {
self.starter_prompts.as_deref().unwrap_or_default()
}
pub fn welcome_message(&self) -> ::std::option::Option<&str> {
self.welcome_message.as_deref()
}
pub fn custom_prompt_input(&self) -> ::std::option::Option<&crate::types::CustomPromptInput> {
self.custom_prompt_input.as_ref()
}
pub fn spaces_to_add(&self) -> &[::std::string::String] {
self.spaces_to_add.as_deref().unwrap_or_default()
}
pub fn spaces_to_remove(&self) -> &[::std::string::String] {
self.spaces_to_remove.as_deref().unwrap_or_default()
}
pub fn action_connectors_to_add(&self) -> &[::std::string::String] {
self.action_connectors_to_add.as_deref().unwrap_or_default()
}
pub fn action_connectors_to_remove(&self) -> &[::std::string::String] {
self.action_connectors_to_remove.as_deref().unwrap_or_default()
}
}
impl ::std::fmt::Debug for UpdateAgentInput {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("UpdateAgentInput");
formatter.field("agent_id", &self.agent_id);
formatter.field("aws_account_id", &self.aws_account_id);
formatter.field("name", &self.name);
formatter.field("description", &self.description);
formatter.field("icon_id", &self.icon_id);
formatter.field("starter_prompts", &"*** Sensitive Data Redacted ***");
formatter.field("welcome_message", &"*** Sensitive Data Redacted ***");
formatter.field("custom_prompt_input", &"*** Sensitive Data Redacted ***");
formatter.field("spaces_to_add", &self.spaces_to_add);
formatter.field("spaces_to_remove", &self.spaces_to_remove);
formatter.field("action_connectors_to_add", &self.action_connectors_to_add);
formatter.field("action_connectors_to_remove", &self.action_connectors_to_remove);
formatter.finish()
}
}
impl UpdateAgentInput {
pub fn builder() -> crate::operation::update_agent::builders::UpdateAgentInputBuilder {
crate::operation::update_agent::builders::UpdateAgentInputBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
#[non_exhaustive]
pub struct UpdateAgentInputBuilder {
pub(crate) agent_id: ::std::option::Option<::std::string::String>,
pub(crate) aws_account_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) icon_id: ::std::option::Option<::std::string::String>,
pub(crate) starter_prompts: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub(crate) welcome_message: ::std::option::Option<::std::string::String>,
pub(crate) custom_prompt_input: ::std::option::Option<crate::types::CustomPromptInput>,
pub(crate) spaces_to_add: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub(crate) spaces_to_remove: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub(crate) action_connectors_to_add: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub(crate) action_connectors_to_remove: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
}
impl UpdateAgentInputBuilder {
pub fn agent_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.agent_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_agent_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.agent_id = input;
self
}
pub fn get_agent_id(&self) -> &::std::option::Option<::std::string::String> {
&self.agent_id
}
pub fn aws_account_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.aws_account_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_aws_account_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.aws_account_id = input;
self
}
pub fn get_aws_account_id(&self) -> &::std::option::Option<::std::string::String> {
&self.aws_account_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 icon_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.icon_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_icon_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.icon_id = input;
self
}
pub fn get_icon_id(&self) -> &::std::option::Option<::std::string::String> {
&self.icon_id
}
pub fn starter_prompts(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut v = self.starter_prompts.unwrap_or_default();
v.push(input.into());
self.starter_prompts = ::std::option::Option::Some(v);
self
}
pub fn set_starter_prompts(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
self.starter_prompts = input;
self
}
pub fn get_starter_prompts(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
&self.starter_prompts
}
pub fn welcome_message(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.welcome_message = ::std::option::Option::Some(input.into());
self
}
pub fn set_welcome_message(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.welcome_message = input;
self
}
pub fn get_welcome_message(&self) -> &::std::option::Option<::std::string::String> {
&self.welcome_message
}
pub fn custom_prompt_input(mut self, input: crate::types::CustomPromptInput) -> Self {
self.custom_prompt_input = ::std::option::Option::Some(input);
self
}
pub fn set_custom_prompt_input(mut self, input: ::std::option::Option<crate::types::CustomPromptInput>) -> Self {
self.custom_prompt_input = input;
self
}
pub fn get_custom_prompt_input(&self) -> &::std::option::Option<crate::types::CustomPromptInput> {
&self.custom_prompt_input
}
pub fn spaces_to_add(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut v = self.spaces_to_add.unwrap_or_default();
v.push(input.into());
self.spaces_to_add = ::std::option::Option::Some(v);
self
}
pub fn set_spaces_to_add(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
self.spaces_to_add = input;
self
}
pub fn get_spaces_to_add(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
&self.spaces_to_add
}
pub fn spaces_to_remove(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut v = self.spaces_to_remove.unwrap_or_default();
v.push(input.into());
self.spaces_to_remove = ::std::option::Option::Some(v);
self
}
pub fn set_spaces_to_remove(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
self.spaces_to_remove = input;
self
}
pub fn get_spaces_to_remove(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
&self.spaces_to_remove
}
pub fn action_connectors_to_add(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut v = self.action_connectors_to_add.unwrap_or_default();
v.push(input.into());
self.action_connectors_to_add = ::std::option::Option::Some(v);
self
}
pub fn set_action_connectors_to_add(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
self.action_connectors_to_add = input;
self
}
pub fn get_action_connectors_to_add(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
&self.action_connectors_to_add
}
pub fn action_connectors_to_remove(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut v = self.action_connectors_to_remove.unwrap_or_default();
v.push(input.into());
self.action_connectors_to_remove = ::std::option::Option::Some(v);
self
}
pub fn set_action_connectors_to_remove(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
self.action_connectors_to_remove = input;
self
}
pub fn get_action_connectors_to_remove(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
&self.action_connectors_to_remove
}
pub fn build(self) -> ::std::result::Result<crate::operation::update_agent::UpdateAgentInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::update_agent::UpdateAgentInput {
agent_id: self.agent_id,
aws_account_id: self.aws_account_id,
name: self.name,
description: self.description,
icon_id: self.icon_id,
starter_prompts: self.starter_prompts,
welcome_message: self.welcome_message,
custom_prompt_input: self.custom_prompt_input,
spaces_to_add: self.spaces_to_add,
spaces_to_remove: self.spaces_to_remove,
action_connectors_to_add: self.action_connectors_to_add,
action_connectors_to_remove: self.action_connectors_to_remove,
})
}
}
impl ::std::fmt::Debug for UpdateAgentInputBuilder {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("UpdateAgentInputBuilder");
formatter.field("agent_id", &self.agent_id);
formatter.field("aws_account_id", &self.aws_account_id);
formatter.field("name", &self.name);
formatter.field("description", &self.description);
formatter.field("icon_id", &self.icon_id);
formatter.field("starter_prompts", &"*** Sensitive Data Redacted ***");
formatter.field("welcome_message", &"*** Sensitive Data Redacted ***");
formatter.field("custom_prompt_input", &"*** Sensitive Data Redacted ***");
formatter.field("spaces_to_add", &self.spaces_to_add);
formatter.field("spaces_to_remove", &self.spaces_to_remove);
formatter.field("action_connectors_to_add", &self.action_connectors_to_add);
formatter.field("action_connectors_to_remove", &self.action_connectors_to_remove);
formatter.finish()
}
}