aws-sdk-mediaconnect 0.27.0

AWS SDK for AWS MediaConnect
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// A request to update gateway instance state.
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct UpdateGatewayInstanceInput {
    /// The availability of the instance to host new bridges. The bridgePlacement property can be LOCKED or AVAILABLE. If it is LOCKED, no new bridges can be deployed to this instance. If it is AVAILABLE, new bridges can be added to this instance.
    #[doc(hidden)]
    pub bridge_placement: std::option::Option<crate::types::BridgePlacement>,
    /// The Amazon Resource Name (ARN) of the instance that you want to update.
    #[doc(hidden)]
    pub gateway_instance_arn: std::option::Option<std::string::String>,
}
impl UpdateGatewayInstanceInput {
    /// The availability of the instance to host new bridges. The bridgePlacement property can be LOCKED or AVAILABLE. If it is LOCKED, no new bridges can be deployed to this instance. If it is AVAILABLE, new bridges can be added to this instance.
    pub fn bridge_placement(&self) -> std::option::Option<&crate::types::BridgePlacement> {
        self.bridge_placement.as_ref()
    }
    /// The Amazon Resource Name (ARN) of the instance that you want to update.
    pub fn gateway_instance_arn(&self) -> std::option::Option<&str> {
        self.gateway_instance_arn.as_deref()
    }
}
impl UpdateGatewayInstanceInput {
    /// Creates a new builder-style object to manufacture [`UpdateGatewayInstanceInput`](crate::operation::update_gateway_instance::UpdateGatewayInstanceInput).
    pub fn builder(
    ) -> crate::operation::update_gateway_instance::builders::UpdateGatewayInstanceInputBuilder
    {
        crate::operation::update_gateway_instance::builders::UpdateGatewayInstanceInputBuilder::default()
    }
}

/// A builder for [`UpdateGatewayInstanceInput`](crate::operation::update_gateway_instance::UpdateGatewayInstanceInput).
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct UpdateGatewayInstanceInputBuilder {
    pub(crate) bridge_placement: std::option::Option<crate::types::BridgePlacement>,
    pub(crate) gateway_instance_arn: std::option::Option<std::string::String>,
}
impl UpdateGatewayInstanceInputBuilder {
    /// The availability of the instance to host new bridges. The bridgePlacement property can be LOCKED or AVAILABLE. If it is LOCKED, no new bridges can be deployed to this instance. If it is AVAILABLE, new bridges can be added to this instance.
    pub fn bridge_placement(mut self, input: crate::types::BridgePlacement) -> Self {
        self.bridge_placement = Some(input);
        self
    }
    /// The availability of the instance to host new bridges. The bridgePlacement property can be LOCKED or AVAILABLE. If it is LOCKED, no new bridges can be deployed to this instance. If it is AVAILABLE, new bridges can be added to this instance.
    pub fn set_bridge_placement(
        mut self,
        input: std::option::Option<crate::types::BridgePlacement>,
    ) -> Self {
        self.bridge_placement = input;
        self
    }
    /// The Amazon Resource Name (ARN) of the instance that you want to update.
    pub fn gateway_instance_arn(mut self, input: impl Into<std::string::String>) -> Self {
        self.gateway_instance_arn = Some(input.into());
        self
    }
    /// The Amazon Resource Name (ARN) of the instance that you want to update.
    pub fn set_gateway_instance_arn(
        mut self,
        input: std::option::Option<std::string::String>,
    ) -> Self {
        self.gateway_instance_arn = input;
        self
    }
    /// Consumes the builder and constructs a [`UpdateGatewayInstanceInput`](crate::operation::update_gateway_instance::UpdateGatewayInstanceInput).
    pub fn build(
        self,
    ) -> Result<
        crate::operation::update_gateway_instance::UpdateGatewayInstanceInput,
        aws_smithy_http::operation::error::BuildError,
    > {
        Ok(
            crate::operation::update_gateway_instance::UpdateGatewayInstanceInput {
                bridge_placement: self.bridge_placement,
                gateway_instance_arn: self.gateway_instance_arn,
            },
        )
    }
}