aws-sdk-wickr 1.1.0

AWS SDK for AWS Wickr Admin API
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 CreateSecurityGroupInput {
    /// <p>The ID of the Wickr network where the security group will be created.</p>
    pub network_id: ::std::option::Option<::std::string::String>,
    /// <p>The name for the new security group.</p>
    pub name: ::std::option::Option<::std::string::String>,
    /// <p>The configuration settings for the security group, including permissions, federation settings, and feature controls.</p>
    pub security_group_settings: ::std::option::Option<crate::types::SecurityGroupSettingsRequest>,
    /// <p>A unique identifier for this request to ensure idempotency.</p>
    pub client_token: ::std::option::Option<::std::string::String>,
}
impl CreateSecurityGroupInput {
    /// <p>The ID of the Wickr network where the security group will be created.</p>
    pub fn network_id(&self) -> ::std::option::Option<&str> {
        self.network_id.as_deref()
    }
    /// <p>The name for the new security group.</p>
    pub fn name(&self) -> ::std::option::Option<&str> {
        self.name.as_deref()
    }
    /// <p>The configuration settings for the security group, including permissions, federation settings, and feature controls.</p>
    pub fn security_group_settings(&self) -> ::std::option::Option<&crate::types::SecurityGroupSettingsRequest> {
        self.security_group_settings.as_ref()
    }
    /// <p>A unique identifier for this request to ensure idempotency.</p>
    pub fn client_token(&self) -> ::std::option::Option<&str> {
        self.client_token.as_deref()
    }
}
impl CreateSecurityGroupInput {
    /// Creates a new builder-style object to manufacture [`CreateSecurityGroupInput`](crate::operation::create_security_group::CreateSecurityGroupInput).
    pub fn builder() -> crate::operation::create_security_group::builders::CreateSecurityGroupInputBuilder {
        crate::operation::create_security_group::builders::CreateSecurityGroupInputBuilder::default()
    }
}

/// A builder for [`CreateSecurityGroupInput`](crate::operation::create_security_group::CreateSecurityGroupInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct CreateSecurityGroupInputBuilder {
    pub(crate) network_id: ::std::option::Option<::std::string::String>,
    pub(crate) name: ::std::option::Option<::std::string::String>,
    pub(crate) security_group_settings: ::std::option::Option<crate::types::SecurityGroupSettingsRequest>,
    pub(crate) client_token: ::std::option::Option<::std::string::String>,
}
impl CreateSecurityGroupInputBuilder {
    /// <p>The ID of the Wickr network where the security group will be created.</p>
    /// This field is required.
    pub fn network_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.network_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the Wickr network where the security group will be created.</p>
    pub fn set_network_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.network_id = input;
        self
    }
    /// <p>The ID of the Wickr network where the security group will be created.</p>
    pub fn get_network_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.network_id
    }
    /// <p>The name for the new security group.</p>
    /// This field is required.
    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name for the new security group.</p>
    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.name = input;
        self
    }
    /// <p>The name for the new security group.</p>
    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.name
    }
    /// <p>The configuration settings for the security group, including permissions, federation settings, and feature controls.</p>
    /// This field is required.
    pub fn security_group_settings(mut self, input: crate::types::SecurityGroupSettingsRequest) -> Self {
        self.security_group_settings = ::std::option::Option::Some(input);
        self
    }
    /// <p>The configuration settings for the security group, including permissions, federation settings, and feature controls.</p>
    pub fn set_security_group_settings(mut self, input: ::std::option::Option<crate::types::SecurityGroupSettingsRequest>) -> Self {
        self.security_group_settings = input;
        self
    }
    /// <p>The configuration settings for the security group, including permissions, federation settings, and feature controls.</p>
    pub fn get_security_group_settings(&self) -> &::std::option::Option<crate::types::SecurityGroupSettingsRequest> {
        &self.security_group_settings
    }
    /// <p>A unique identifier for this request to ensure idempotency.</p>
    pub fn client_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.client_token = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A unique identifier for this request to ensure idempotency.</p>
    pub fn set_client_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.client_token = input;
        self
    }
    /// <p>A unique identifier for this request to ensure idempotency.</p>
    pub fn get_client_token(&self) -> &::std::option::Option<::std::string::String> {
        &self.client_token
    }
    /// Consumes the builder and constructs a [`CreateSecurityGroupInput`](crate::operation::create_security_group::CreateSecurityGroupInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::create_security_group::CreateSecurityGroupInput, ::aws_smithy_types::error::operation::BuildError>
    {
        ::std::result::Result::Ok(crate::operation::create_security_group::CreateSecurityGroupInput {
            network_id: self.network_id,
            name: self.name,
            security_group_settings: self.security_group_settings,
            client_token: self.client_token,
        })
    }
}