aws-sdk-medialive 1.97.0

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

/// Placeholder documentation for DescribeClusterResponse
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct DescribeClusterOutput {
    /// The ARN of this Cluster. It is automatically assigned when the Cluster is created.
    pub arn: ::std::option::Option<::std::string::String>,
    /// Placeholder documentation for __listOf__string
    pub channel_ids: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
    /// The hardware type for the Cluster
    pub cluster_type: ::std::option::Option<crate::types::ClusterType>,
    /// The ID of the Cluster. Unique in the AWS account. The ID is the resource-id portion of the ARN.
    pub id: ::std::option::Option<::std::string::String>,
    /// The ARN of the IAM role for the Node in this Cluster. Any Nodes that are associated with this Cluster assume this role. The role gives permissions to the operations that you expect these Node to perform.
    pub instance_role_arn: ::std::option::Option<::std::string::String>,
    /// The name that you specified for the Cluster.
    pub name: ::std::option::Option<::std::string::String>,
    /// Network settings that connect the Nodes in the Cluster to one or more of the Networks that the Cluster is associated with.
    pub network_settings: ::std::option::Option<crate::types::ClusterNetworkSettings>,
    /// The current state of the Cluster.
    pub state: ::std::option::Option<crate::types::ClusterState>,
    _request_id: Option<String>,
}
impl DescribeClusterOutput {
    /// The ARN of this Cluster. It is automatically assigned when the Cluster is created.
    pub fn arn(&self) -> ::std::option::Option<&str> {
        self.arn.as_deref()
    }
    /// Placeholder documentation for __listOf__string
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.channel_ids.is_none()`.
    pub fn channel_ids(&self) -> &[::std::string::String] {
        self.channel_ids.as_deref().unwrap_or_default()
    }
    /// The hardware type for the Cluster
    pub fn cluster_type(&self) -> ::std::option::Option<&crate::types::ClusterType> {
        self.cluster_type.as_ref()
    }
    /// The ID of the Cluster. Unique in the AWS account. The ID is the resource-id portion of the ARN.
    pub fn id(&self) -> ::std::option::Option<&str> {
        self.id.as_deref()
    }
    /// The ARN of the IAM role for the Node in this Cluster. Any Nodes that are associated with this Cluster assume this role. The role gives permissions to the operations that you expect these Node to perform.
    pub fn instance_role_arn(&self) -> ::std::option::Option<&str> {
        self.instance_role_arn.as_deref()
    }
    /// The name that you specified for the Cluster.
    pub fn name(&self) -> ::std::option::Option<&str> {
        self.name.as_deref()
    }
    /// Network settings that connect the Nodes in the Cluster to one or more of the Networks that the Cluster is associated with.
    pub fn network_settings(&self) -> ::std::option::Option<&crate::types::ClusterNetworkSettings> {
        self.network_settings.as_ref()
    }
    /// The current state of the Cluster.
    pub fn state(&self) -> ::std::option::Option<&crate::types::ClusterState> {
        self.state.as_ref()
    }
}
impl ::aws_types::request_id::RequestId for DescribeClusterOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl DescribeClusterOutput {
    /// Creates a new builder-style object to manufacture [`DescribeClusterOutput`](crate::operation::describe_cluster::DescribeClusterOutput).
    pub fn builder() -> crate::operation::describe_cluster::builders::DescribeClusterOutputBuilder {
        crate::operation::describe_cluster::builders::DescribeClusterOutputBuilder::default()
    }
}

/// A builder for [`DescribeClusterOutput`](crate::operation::describe_cluster::DescribeClusterOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct DescribeClusterOutputBuilder {
    pub(crate) arn: ::std::option::Option<::std::string::String>,
    pub(crate) channel_ids: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
    pub(crate) cluster_type: ::std::option::Option<crate::types::ClusterType>,
    pub(crate) id: ::std::option::Option<::std::string::String>,
    pub(crate) instance_role_arn: ::std::option::Option<::std::string::String>,
    pub(crate) name: ::std::option::Option<::std::string::String>,
    pub(crate) network_settings: ::std::option::Option<crate::types::ClusterNetworkSettings>,
    pub(crate) state: ::std::option::Option<crate::types::ClusterState>,
    _request_id: Option<String>,
}
impl DescribeClusterOutputBuilder {
    /// The ARN of this Cluster. It is automatically assigned when the Cluster is created.
    pub fn arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.arn = ::std::option::Option::Some(input.into());
        self
    }
    /// The ARN of this Cluster. It is automatically assigned when the Cluster is created.
    pub fn set_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.arn = input;
        self
    }
    /// The ARN of this Cluster. It is automatically assigned when the Cluster is created.
    pub fn get_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.arn
    }
    /// Appends an item to `channel_ids`.
    ///
    /// To override the contents of this collection use [`set_channel_ids`](Self::set_channel_ids).
    ///
    /// Placeholder documentation for __listOf__string
    pub fn channel_ids(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        let mut v = self.channel_ids.unwrap_or_default();
        v.push(input.into());
        self.channel_ids = ::std::option::Option::Some(v);
        self
    }
    /// Placeholder documentation for __listOf__string
    pub fn set_channel_ids(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
        self.channel_ids = input;
        self
    }
    /// Placeholder documentation for __listOf__string
    pub fn get_channel_ids(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
        &self.channel_ids
    }
    /// The hardware type for the Cluster
    pub fn cluster_type(mut self, input: crate::types::ClusterType) -> Self {
        self.cluster_type = ::std::option::Option::Some(input);
        self
    }
    /// The hardware type for the Cluster
    pub fn set_cluster_type(mut self, input: ::std::option::Option<crate::types::ClusterType>) -> Self {
        self.cluster_type = input;
        self
    }
    /// The hardware type for the Cluster
    pub fn get_cluster_type(&self) -> &::std::option::Option<crate::types::ClusterType> {
        &self.cluster_type
    }
    /// The ID of the Cluster. Unique in the AWS account. The ID is the resource-id portion of the ARN.
    pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.id = ::std::option::Option::Some(input.into());
        self
    }
    /// The ID of the Cluster. Unique in the AWS account. The ID is the resource-id portion of the ARN.
    pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.id = input;
        self
    }
    /// The ID of the Cluster. Unique in the AWS account. The ID is the resource-id portion of the ARN.
    pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.id
    }
    /// The ARN of the IAM role for the Node in this Cluster. Any Nodes that are associated with this Cluster assume this role. The role gives permissions to the operations that you expect these Node to perform.
    pub fn instance_role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.instance_role_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// The ARN of the IAM role for the Node in this Cluster. Any Nodes that are associated with this Cluster assume this role. The role gives permissions to the operations that you expect these Node to perform.
    pub fn set_instance_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.instance_role_arn = input;
        self
    }
    /// The ARN of the IAM role for the Node in this Cluster. Any Nodes that are associated with this Cluster assume this role. The role gives permissions to the operations that you expect these Node to perform.
    pub fn get_instance_role_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.instance_role_arn
    }
    /// The name that you specified for the Cluster.
    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.name = ::std::option::Option::Some(input.into());
        self
    }
    /// The name that you specified for the Cluster.
    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.name = input;
        self
    }
    /// The name that you specified for the Cluster.
    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.name
    }
    /// Network settings that connect the Nodes in the Cluster to one or more of the Networks that the Cluster is associated with.
    pub fn network_settings(mut self, input: crate::types::ClusterNetworkSettings) -> Self {
        self.network_settings = ::std::option::Option::Some(input);
        self
    }
    /// Network settings that connect the Nodes in the Cluster to one or more of the Networks that the Cluster is associated with.
    pub fn set_network_settings(mut self, input: ::std::option::Option<crate::types::ClusterNetworkSettings>) -> Self {
        self.network_settings = input;
        self
    }
    /// Network settings that connect the Nodes in the Cluster to one or more of the Networks that the Cluster is associated with.
    pub fn get_network_settings(&self) -> &::std::option::Option<crate::types::ClusterNetworkSettings> {
        &self.network_settings
    }
    /// The current state of the Cluster.
    pub fn state(mut self, input: crate::types::ClusterState) -> Self {
        self.state = ::std::option::Option::Some(input);
        self
    }
    /// The current state of the Cluster.
    pub fn set_state(mut self, input: ::std::option::Option<crate::types::ClusterState>) -> Self {
        self.state = input;
        self
    }
    /// The current state of the Cluster.
    pub fn get_state(&self) -> &::std::option::Option<crate::types::ClusterState> {
        &self.state
    }
    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
        self._request_id = Some(request_id.into());
        self
    }

    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
        self._request_id = request_id;
        self
    }
    /// Consumes the builder and constructs a [`DescribeClusterOutput`](crate::operation::describe_cluster::DescribeClusterOutput).
    pub fn build(self) -> crate::operation::describe_cluster::DescribeClusterOutput {
        crate::operation::describe_cluster::DescribeClusterOutput {
            arn: self.arn,
            channel_ids: self.channel_ids,
            cluster_type: self.cluster_type,
            id: self.id,
            instance_role_arn: self.instance_role_arn,
            name: self.name,
            network_settings: self.network_settings,
            state: self.state,
            _request_id: self._request_id,
        }
    }
}