aws-sdk-outposts 1.114.0

AWS SDK for AWS Outposts
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)]
pub struct UpdateQuoteInput {
    /// <p>The ID or ARN of the quote.</p>
    pub quote_identifier: ::std::option::Option<::std::string::String>,
    /// <p>The ID or ARN of the Outpost to associate with the quote. Specify an empty string to remove the Outpost association.</p>
    pub outpost_identifier: ::std::option::Option<::std::string::String>,
    /// <p>The country code for the Outpost site location.</p>
    pub country_code: ::std::option::Option<::std::string::String>,
    /// <p>The updated capacity requirements for the quote.</p>
    pub requested_capacities: ::std::option::Option<::std::vec::Vec<crate::types::QuoteCapacity>>,
    /// <p>The updated physical constraints for the quote.</p>
    pub requested_constraints: ::std::option::Option<::std::vec::Vec<crate::types::QuoteConstraint>>,
    /// <p>The updated payment options to include in the quote pricing.</p>
    pub requested_payment_options: ::std::option::Option<::std::vec::Vec<crate::types::PaymentOption>>,
    /// <p>The updated payment terms to include in the quote pricing.</p>
    pub requested_payment_terms: ::std::option::Option<::std::vec::Vec<crate::types::PaymentTerm>>,
    /// <p>A description for the quote.</p>
    pub description: ::std::option::Option<::std::string::String>,
}
impl UpdateQuoteInput {
    /// <p>The ID or ARN of the quote.</p>
    pub fn quote_identifier(&self) -> ::std::option::Option<&str> {
        self.quote_identifier.as_deref()
    }
    /// <p>The ID or ARN of the Outpost to associate with the quote. Specify an empty string to remove the Outpost association.</p>
    pub fn outpost_identifier(&self) -> ::std::option::Option<&str> {
        self.outpost_identifier.as_deref()
    }
    /// <p>The country code for the Outpost site location.</p>
    pub fn country_code(&self) -> ::std::option::Option<&str> {
        self.country_code.as_deref()
    }
    /// <p>The updated capacity requirements for the quote.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.requested_capacities.is_none()`.
    pub fn requested_capacities(&self) -> &[crate::types::QuoteCapacity] {
        self.requested_capacities.as_deref().unwrap_or_default()
    }
    /// <p>The updated physical constraints for the quote.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.requested_constraints.is_none()`.
    pub fn requested_constraints(&self) -> &[crate::types::QuoteConstraint] {
        self.requested_constraints.as_deref().unwrap_or_default()
    }
    /// <p>The updated payment options to include in the quote pricing.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.requested_payment_options.is_none()`.
    pub fn requested_payment_options(&self) -> &[crate::types::PaymentOption] {
        self.requested_payment_options.as_deref().unwrap_or_default()
    }
    /// <p>The updated payment terms to include in the quote pricing.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.requested_payment_terms.is_none()`.
    pub fn requested_payment_terms(&self) -> &[crate::types::PaymentTerm] {
        self.requested_payment_terms.as_deref().unwrap_or_default()
    }
    /// <p>A description for the quote.</p>
    pub fn description(&self) -> ::std::option::Option<&str> {
        self.description.as_deref()
    }
}
impl ::std::fmt::Debug for UpdateQuoteInput {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        let mut formatter = f.debug_struct("UpdateQuoteInput");
        formatter.field("quote_identifier", &self.quote_identifier);
        formatter.field("outpost_identifier", &self.outpost_identifier);
        formatter.field("country_code", &self.country_code);
        formatter.field("requested_capacities", &self.requested_capacities);
        formatter.field("requested_constraints", &self.requested_constraints);
        formatter.field("requested_payment_options", &self.requested_payment_options);
        formatter.field("requested_payment_terms", &self.requested_payment_terms);
        formatter.field("description", &"*** Sensitive Data Redacted ***");
        formatter.finish()
    }
}
impl UpdateQuoteInput {
    /// Creates a new builder-style object to manufacture [`UpdateQuoteInput`](crate::operation::update_quote::UpdateQuoteInput).
    pub fn builder() -> crate::operation::update_quote::builders::UpdateQuoteInputBuilder {
        crate::operation::update_quote::builders::UpdateQuoteInputBuilder::default()
    }
}

/// A builder for [`UpdateQuoteInput`](crate::operation::update_quote::UpdateQuoteInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
#[non_exhaustive]
pub struct UpdateQuoteInputBuilder {
    pub(crate) quote_identifier: ::std::option::Option<::std::string::String>,
    pub(crate) outpost_identifier: ::std::option::Option<::std::string::String>,
    pub(crate) country_code: ::std::option::Option<::std::string::String>,
    pub(crate) requested_capacities: ::std::option::Option<::std::vec::Vec<crate::types::QuoteCapacity>>,
    pub(crate) requested_constraints: ::std::option::Option<::std::vec::Vec<crate::types::QuoteConstraint>>,
    pub(crate) requested_payment_options: ::std::option::Option<::std::vec::Vec<crate::types::PaymentOption>>,
    pub(crate) requested_payment_terms: ::std::option::Option<::std::vec::Vec<crate::types::PaymentTerm>>,
    pub(crate) description: ::std::option::Option<::std::string::String>,
}
impl UpdateQuoteInputBuilder {
    /// <p>The ID or ARN of the quote.</p>
    /// This field is required.
    pub fn quote_identifier(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.quote_identifier = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID or ARN of the quote.</p>
    pub fn set_quote_identifier(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.quote_identifier = input;
        self
    }
    /// <p>The ID or ARN of the quote.</p>
    pub fn get_quote_identifier(&self) -> &::std::option::Option<::std::string::String> {
        &self.quote_identifier
    }
    /// <p>The ID or ARN of the Outpost to associate with the quote. Specify an empty string to remove the Outpost association.</p>
    pub fn outpost_identifier(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.outpost_identifier = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID or ARN of the Outpost to associate with the quote. Specify an empty string to remove the Outpost association.</p>
    pub fn set_outpost_identifier(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.outpost_identifier = input;
        self
    }
    /// <p>The ID or ARN of the Outpost to associate with the quote. Specify an empty string to remove the Outpost association.</p>
    pub fn get_outpost_identifier(&self) -> &::std::option::Option<::std::string::String> {
        &self.outpost_identifier
    }
    /// <p>The country code for the Outpost site location.</p>
    pub fn country_code(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.country_code = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The country code for the Outpost site location.</p>
    pub fn set_country_code(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.country_code = input;
        self
    }
    /// <p>The country code for the Outpost site location.</p>
    pub fn get_country_code(&self) -> &::std::option::Option<::std::string::String> {
        &self.country_code
    }
    /// Appends an item to `requested_capacities`.
    ///
    /// To override the contents of this collection use [`set_requested_capacities`](Self::set_requested_capacities).
    ///
    /// <p>The updated capacity requirements for the quote.</p>
    pub fn requested_capacities(mut self, input: crate::types::QuoteCapacity) -> Self {
        let mut v = self.requested_capacities.unwrap_or_default();
        v.push(input);
        self.requested_capacities = ::std::option::Option::Some(v);
        self
    }
    /// <p>The updated capacity requirements for the quote.</p>
    pub fn set_requested_capacities(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::QuoteCapacity>>) -> Self {
        self.requested_capacities = input;
        self
    }
    /// <p>The updated capacity requirements for the quote.</p>
    pub fn get_requested_capacities(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::QuoteCapacity>> {
        &self.requested_capacities
    }
    /// Appends an item to `requested_constraints`.
    ///
    /// To override the contents of this collection use [`set_requested_constraints`](Self::set_requested_constraints).
    ///
    /// <p>The updated physical constraints for the quote.</p>
    pub fn requested_constraints(mut self, input: crate::types::QuoteConstraint) -> Self {
        let mut v = self.requested_constraints.unwrap_or_default();
        v.push(input);
        self.requested_constraints = ::std::option::Option::Some(v);
        self
    }
    /// <p>The updated physical constraints for the quote.</p>
    pub fn set_requested_constraints(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::QuoteConstraint>>) -> Self {
        self.requested_constraints = input;
        self
    }
    /// <p>The updated physical constraints for the quote.</p>
    pub fn get_requested_constraints(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::QuoteConstraint>> {
        &self.requested_constraints
    }
    /// Appends an item to `requested_payment_options`.
    ///
    /// To override the contents of this collection use [`set_requested_payment_options`](Self::set_requested_payment_options).
    ///
    /// <p>The updated payment options to include in the quote pricing.</p>
    pub fn requested_payment_options(mut self, input: crate::types::PaymentOption) -> Self {
        let mut v = self.requested_payment_options.unwrap_or_default();
        v.push(input);
        self.requested_payment_options = ::std::option::Option::Some(v);
        self
    }
    /// <p>The updated payment options to include in the quote pricing.</p>
    pub fn set_requested_payment_options(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::PaymentOption>>) -> Self {
        self.requested_payment_options = input;
        self
    }
    /// <p>The updated payment options to include in the quote pricing.</p>
    pub fn get_requested_payment_options(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::PaymentOption>> {
        &self.requested_payment_options
    }
    /// Appends an item to `requested_payment_terms`.
    ///
    /// To override the contents of this collection use [`set_requested_payment_terms`](Self::set_requested_payment_terms).
    ///
    /// <p>The updated payment terms to include in the quote pricing.</p>
    pub fn requested_payment_terms(mut self, input: crate::types::PaymentTerm) -> Self {
        let mut v = self.requested_payment_terms.unwrap_or_default();
        v.push(input);
        self.requested_payment_terms = ::std::option::Option::Some(v);
        self
    }
    /// <p>The updated payment terms to include in the quote pricing.</p>
    pub fn set_requested_payment_terms(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::PaymentTerm>>) -> Self {
        self.requested_payment_terms = input;
        self
    }
    /// <p>The updated payment terms to include in the quote pricing.</p>
    pub fn get_requested_payment_terms(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::PaymentTerm>> {
        &self.requested_payment_terms
    }
    /// <p>A description for the quote.</p>
    pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.description = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A description for the quote.</p>
    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.description = input;
        self
    }
    /// <p>A description for the quote.</p>
    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
        &self.description
    }
    /// Consumes the builder and constructs a [`UpdateQuoteInput`](crate::operation::update_quote::UpdateQuoteInput).
    pub fn build(self) -> ::std::result::Result<crate::operation::update_quote::UpdateQuoteInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::update_quote::UpdateQuoteInput {
            quote_identifier: self.quote_identifier,
            outpost_identifier: self.outpost_identifier,
            country_code: self.country_code,
            requested_capacities: self.requested_capacities,
            requested_constraints: self.requested_constraints,
            requested_payment_options: self.requested_payment_options,
            requested_payment_terms: self.requested_payment_terms,
            description: self.description,
        })
    }
}
impl ::std::fmt::Debug for UpdateQuoteInputBuilder {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        let mut formatter = f.debug_struct("UpdateQuoteInputBuilder");
        formatter.field("quote_identifier", &self.quote_identifier);
        formatter.field("outpost_identifier", &self.outpost_identifier);
        formatter.field("country_code", &self.country_code);
        formatter.field("requested_capacities", &self.requested_capacities);
        formatter.field("requested_constraints", &self.requested_constraints);
        formatter.field("requested_payment_options", &self.requested_payment_options);
        formatter.field("requested_payment_terms", &self.requested_payment_terms);
        formatter.field("description", &"*** Sensitive Data Redacted ***");
        formatter.finish()
    }
}