aws-sdk-appconfig 1.99.0

AWS SDK for Amazon AppConfig
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 GetExtensionInput {
    /// <p>The name, the ID, or the Amazon Resource Name (ARN) of the extension.</p>
    pub extension_identifier: ::std::option::Option<::std::string::String>,
    /// <p>The extension version number. If no version number was defined, AppConfig uses the highest version.</p>
    pub version_number: ::std::option::Option<i32>,
}
impl GetExtensionInput {
    /// <p>The name, the ID, or the Amazon Resource Name (ARN) of the extension.</p>
    pub fn extension_identifier(&self) -> ::std::option::Option<&str> {
        self.extension_identifier.as_deref()
    }
    /// <p>The extension version number. If no version number was defined, AppConfig uses the highest version.</p>
    pub fn version_number(&self) -> ::std::option::Option<i32> {
        self.version_number
    }
}
impl GetExtensionInput {
    /// Creates a new builder-style object to manufacture [`GetExtensionInput`](crate::operation::get_extension::GetExtensionInput).
    pub fn builder() -> crate::operation::get_extension::builders::GetExtensionInputBuilder {
        crate::operation::get_extension::builders::GetExtensionInputBuilder::default()
    }
}

/// A builder for [`GetExtensionInput`](crate::operation::get_extension::GetExtensionInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetExtensionInputBuilder {
    pub(crate) extension_identifier: ::std::option::Option<::std::string::String>,
    pub(crate) version_number: ::std::option::Option<i32>,
}
impl GetExtensionInputBuilder {
    /// <p>The name, the ID, or the Amazon Resource Name (ARN) of the extension.</p>
    /// This field is required.
    pub fn extension_identifier(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.extension_identifier = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name, the ID, or the Amazon Resource Name (ARN) of the extension.</p>
    pub fn set_extension_identifier(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.extension_identifier = input;
        self
    }
    /// <p>The name, the ID, or the Amazon Resource Name (ARN) of the extension.</p>
    pub fn get_extension_identifier(&self) -> &::std::option::Option<::std::string::String> {
        &self.extension_identifier
    }
    /// <p>The extension version number. If no version number was defined, AppConfig uses the highest version.</p>
    pub fn version_number(mut self, input: i32) -> Self {
        self.version_number = ::std::option::Option::Some(input);
        self
    }
    /// <p>The extension version number. If no version number was defined, AppConfig uses the highest version.</p>
    pub fn set_version_number(mut self, input: ::std::option::Option<i32>) -> Self {
        self.version_number = input;
        self
    }
    /// <p>The extension version number. If no version number was defined, AppConfig uses the highest version.</p>
    pub fn get_version_number(&self) -> &::std::option::Option<i32> {
        &self.version_number
    }
    /// Consumes the builder and constructs a [`GetExtensionInput`](crate::operation::get_extension::GetExtensionInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::get_extension::GetExtensionInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::get_extension::GetExtensionInput {
            extension_identifier: self.extension_identifier,
            version_number: self.version_number,
        })
    }
}