aws-sdk-eks 1.129.0

AWS SDK for Amazon Elastic Kubernetes Service
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 UpdateCapabilityInput {
    /// <p>The name of the Amazon EKS cluster that contains the capability you want to update configuration for.</p>
    pub cluster_name: ::std::option::Option<::std::string::String>,
    /// <p>The name of the capability to update configuration for.</p>
    pub capability_name: ::std::option::Option<::std::string::String>,
    /// <p>The Amazon Resource Name (ARN) of the IAM role that the capability uses to interact with Amazon Web Services services. If you specify a new role ARN, the capability will start using the new role for all subsequent operations.</p>
    pub role_arn: ::std::option::Option<::std::string::String>,
    /// <p>The updated configuration settings for the capability. You only need to specify the configuration parameters you want to change. For Argo CD capabilities, you can update RBAC role mappings and network access settings.</p>
    pub configuration: ::std::option::Option<crate::types::UpdateCapabilityConfiguration>,
    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. This token is valid for 24 hours after creation.</p>
    pub client_request_token: ::std::option::Option<::std::string::String>,
    /// <p>The updated delete propagation policy for the capability. Currently, the only supported value is <code>RETAIN</code>.</p>
    pub delete_propagation_policy: ::std::option::Option<crate::types::CapabilityDeletePropagationPolicy>,
}
impl UpdateCapabilityInput {
    /// <p>The name of the Amazon EKS cluster that contains the capability you want to update configuration for.</p>
    pub fn cluster_name(&self) -> ::std::option::Option<&str> {
        self.cluster_name.as_deref()
    }
    /// <p>The name of the capability to update configuration for.</p>
    pub fn capability_name(&self) -> ::std::option::Option<&str> {
        self.capability_name.as_deref()
    }
    /// <p>The Amazon Resource Name (ARN) of the IAM role that the capability uses to interact with Amazon Web Services services. If you specify a new role ARN, the capability will start using the new role for all subsequent operations.</p>
    pub fn role_arn(&self) -> ::std::option::Option<&str> {
        self.role_arn.as_deref()
    }
    /// <p>The updated configuration settings for the capability. You only need to specify the configuration parameters you want to change. For Argo CD capabilities, you can update RBAC role mappings and network access settings.</p>
    pub fn configuration(&self) -> ::std::option::Option<&crate::types::UpdateCapabilityConfiguration> {
        self.configuration.as_ref()
    }
    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. This token is valid for 24 hours after creation.</p>
    pub fn client_request_token(&self) -> ::std::option::Option<&str> {
        self.client_request_token.as_deref()
    }
    /// <p>The updated delete propagation policy for the capability. Currently, the only supported value is <code>RETAIN</code>.</p>
    pub fn delete_propagation_policy(&self) -> ::std::option::Option<&crate::types::CapabilityDeletePropagationPolicy> {
        self.delete_propagation_policy.as_ref()
    }
}
impl UpdateCapabilityInput {
    /// Creates a new builder-style object to manufacture [`UpdateCapabilityInput`](crate::operation::update_capability::UpdateCapabilityInput).
    pub fn builder() -> crate::operation::update_capability::builders::UpdateCapabilityInputBuilder {
        crate::operation::update_capability::builders::UpdateCapabilityInputBuilder::default()
    }
}

/// A builder for [`UpdateCapabilityInput`](crate::operation::update_capability::UpdateCapabilityInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateCapabilityInputBuilder {
    pub(crate) cluster_name: ::std::option::Option<::std::string::String>,
    pub(crate) capability_name: ::std::option::Option<::std::string::String>,
    pub(crate) role_arn: ::std::option::Option<::std::string::String>,
    pub(crate) configuration: ::std::option::Option<crate::types::UpdateCapabilityConfiguration>,
    pub(crate) client_request_token: ::std::option::Option<::std::string::String>,
    pub(crate) delete_propagation_policy: ::std::option::Option<crate::types::CapabilityDeletePropagationPolicy>,
}
impl UpdateCapabilityInputBuilder {
    /// <p>The name of the Amazon EKS cluster that contains the capability you want to update configuration for.</p>
    /// This field is required.
    pub fn cluster_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.cluster_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of the Amazon EKS cluster that contains the capability you want to update configuration for.</p>
    pub fn set_cluster_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.cluster_name = input;
        self
    }
    /// <p>The name of the Amazon EKS cluster that contains the capability you want to update configuration for.</p>
    pub fn get_cluster_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.cluster_name
    }
    /// <p>The name of the capability to update configuration for.</p>
    /// This field is required.
    pub fn capability_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.capability_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of the capability to update configuration for.</p>
    pub fn set_capability_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.capability_name = input;
        self
    }
    /// <p>The name of the capability to update configuration for.</p>
    pub fn get_capability_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.capability_name
    }
    /// <p>The Amazon Resource Name (ARN) of the IAM role that the capability uses to interact with Amazon Web Services services. If you specify a new role ARN, the capability will start using the new role for all subsequent operations.</p>
    pub fn role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.role_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon Resource Name (ARN) of the IAM role that the capability uses to interact with Amazon Web Services services. If you specify a new role ARN, the capability will start using the new role for all subsequent operations.</p>
    pub fn set_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.role_arn = input;
        self
    }
    /// <p>The Amazon Resource Name (ARN) of the IAM role that the capability uses to interact with Amazon Web Services services. If you specify a new role ARN, the capability will start using the new role for all subsequent operations.</p>
    pub fn get_role_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.role_arn
    }
    /// <p>The updated configuration settings for the capability. You only need to specify the configuration parameters you want to change. For Argo CD capabilities, you can update RBAC role mappings and network access settings.</p>
    pub fn configuration(mut self, input: crate::types::UpdateCapabilityConfiguration) -> Self {
        self.configuration = ::std::option::Option::Some(input);
        self
    }
    /// <p>The updated configuration settings for the capability. You only need to specify the configuration parameters you want to change. For Argo CD capabilities, you can update RBAC role mappings and network access settings.</p>
    pub fn set_configuration(mut self, input: ::std::option::Option<crate::types::UpdateCapabilityConfiguration>) -> Self {
        self.configuration = input;
        self
    }
    /// <p>The updated configuration settings for the capability. You only need to specify the configuration parameters you want to change. For Argo CD capabilities, you can update RBAC role mappings and network access settings.</p>
    pub fn get_configuration(&self) -> &::std::option::Option<crate::types::UpdateCapabilityConfiguration> {
        &self.configuration
    }
    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. This token is valid for 24 hours after creation.</p>
    pub fn client_request_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.client_request_token = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. This token is valid for 24 hours after creation.</p>
    pub fn set_client_request_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.client_request_token = input;
        self
    }
    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. This token is valid for 24 hours after creation.</p>
    pub fn get_client_request_token(&self) -> &::std::option::Option<::std::string::String> {
        &self.client_request_token
    }
    /// <p>The updated delete propagation policy for the capability. Currently, the only supported value is <code>RETAIN</code>.</p>
    pub fn delete_propagation_policy(mut self, input: crate::types::CapabilityDeletePropagationPolicy) -> Self {
        self.delete_propagation_policy = ::std::option::Option::Some(input);
        self
    }
    /// <p>The updated delete propagation policy for the capability. Currently, the only supported value is <code>RETAIN</code>.</p>
    pub fn set_delete_propagation_policy(mut self, input: ::std::option::Option<crate::types::CapabilityDeletePropagationPolicy>) -> Self {
        self.delete_propagation_policy = input;
        self
    }
    /// <p>The updated delete propagation policy for the capability. Currently, the only supported value is <code>RETAIN</code>.</p>
    pub fn get_delete_propagation_policy(&self) -> &::std::option::Option<crate::types::CapabilityDeletePropagationPolicy> {
        &self.delete_propagation_policy
    }
    /// Consumes the builder and constructs a [`UpdateCapabilityInput`](crate::operation::update_capability::UpdateCapabilityInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::update_capability::UpdateCapabilityInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::update_capability::UpdateCapabilityInput {
            cluster_name: self.cluster_name,
            capability_name: self.capability_name,
            role_arn: self.role_arn,
            configuration: self.configuration,
            client_request_token: self.client_request_token,
            delete_propagation_policy: self.delete_propagation_policy,
        })
    }
}