aws-sdk-bedrockagent 1.55.0

AWS SDK for Agents for Amazon Bedrock
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct GetAgentVersionInput {
    /// <p>The unique identifier of the agent.</p>
    pub agent_id: ::std::option::Option<::std::string::String>,
    /// <p>The version of the agent.</p>
    pub agent_version: ::std::option::Option<::std::string::String>,
}
impl GetAgentVersionInput {
    /// <p>The unique identifier of the agent.</p>
    pub fn agent_id(&self) -> ::std::option::Option<&str> {
        self.agent_id.as_deref()
    }
    /// <p>The version of the agent.</p>
    pub fn agent_version(&self) -> ::std::option::Option<&str> {
        self.agent_version.as_deref()
    }
}
impl GetAgentVersionInput {
    /// Creates a new builder-style object to manufacture [`GetAgentVersionInput`](crate::operation::get_agent_version::GetAgentVersionInput).
    pub fn builder() -> crate::operation::get_agent_version::builders::GetAgentVersionInputBuilder {
        crate::operation::get_agent_version::builders::GetAgentVersionInputBuilder::default()
    }
}

/// A builder for [`GetAgentVersionInput`](crate::operation::get_agent_version::GetAgentVersionInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetAgentVersionInputBuilder {
    pub(crate) agent_id: ::std::option::Option<::std::string::String>,
    pub(crate) agent_version: ::std::option::Option<::std::string::String>,
}
impl GetAgentVersionInputBuilder {
    /// <p>The unique identifier of the agent.</p>
    /// This field is required.
    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
    }
    /// <p>The unique identifier of the agent.</p>
    pub fn set_agent_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.agent_id = input;
        self
    }
    /// <p>The unique identifier of the agent.</p>
    pub fn get_agent_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.agent_id
    }
    /// <p>The version of the agent.</p>
    /// This field is required.
    pub fn agent_version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.agent_version = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The version of the agent.</p>
    pub fn set_agent_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.agent_version = input;
        self
    }
    /// <p>The version of the agent.</p>
    pub fn get_agent_version(&self) -> &::std::option::Option<::std::string::String> {
        &self.agent_version
    }
    /// Consumes the builder and constructs a [`GetAgentVersionInput`](crate::operation::get_agent_version::GetAgentVersionInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::get_agent_version::GetAgentVersionInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::get_agent_version::GetAgentVersionInput {
            agent_id: self.agent_id,
            agent_version: self.agent_version,
        })
    }
}