aws-sdk-connect 1.166.0

AWS SDK for Amazon Connect 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 CreateViewVersionInput {
    /// <p>The identifier of the Amazon Connect instance. You can find the instanceId in the ARN of the instance.</p>
    pub instance_id: ::std::option::Option<::std::string::String>,
    /// <p>The identifier of the view. Both <code>ViewArn</code> and <code>ViewId</code> can be used.</p>
    pub view_id: ::std::option::Option<::std::string::String>,
    /// <p>The description for the version being published.</p>
    pub version_description: ::std::option::Option<::std::string::String>,
    /// <p>Indicates the checksum value of the latest published view content.</p>
    pub view_content_sha256: ::std::option::Option<::std::string::String>,
}
impl CreateViewVersionInput {
    /// <p>The identifier of the Amazon Connect instance. You can find the instanceId in the ARN of the instance.</p>
    pub fn instance_id(&self) -> ::std::option::Option<&str> {
        self.instance_id.as_deref()
    }
    /// <p>The identifier of the view. Both <code>ViewArn</code> and <code>ViewId</code> can be used.</p>
    pub fn view_id(&self) -> ::std::option::Option<&str> {
        self.view_id.as_deref()
    }
    /// <p>The description for the version being published.</p>
    pub fn version_description(&self) -> ::std::option::Option<&str> {
        self.version_description.as_deref()
    }
    /// <p>Indicates the checksum value of the latest published view content.</p>
    pub fn view_content_sha256(&self) -> ::std::option::Option<&str> {
        self.view_content_sha256.as_deref()
    }
}
impl CreateViewVersionInput {
    /// Creates a new builder-style object to manufacture [`CreateViewVersionInput`](crate::operation::create_view_version::CreateViewVersionInput).
    pub fn builder() -> crate::operation::create_view_version::builders::CreateViewVersionInputBuilder {
        crate::operation::create_view_version::builders::CreateViewVersionInputBuilder::default()
    }
}

/// A builder for [`CreateViewVersionInput`](crate::operation::create_view_version::CreateViewVersionInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct CreateViewVersionInputBuilder {
    pub(crate) instance_id: ::std::option::Option<::std::string::String>,
    pub(crate) view_id: ::std::option::Option<::std::string::String>,
    pub(crate) version_description: ::std::option::Option<::std::string::String>,
    pub(crate) view_content_sha256: ::std::option::Option<::std::string::String>,
}
impl CreateViewVersionInputBuilder {
    /// <p>The identifier of the Amazon Connect instance. You can find the instanceId in the ARN of the instance.</p>
    /// This field is required.
    pub fn instance_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.instance_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The identifier of the Amazon Connect instance. You can find the instanceId in the ARN of the instance.</p>
    pub fn set_instance_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.instance_id = input;
        self
    }
    /// <p>The identifier of the Amazon Connect instance. You can find the instanceId in the ARN of the instance.</p>
    pub fn get_instance_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.instance_id
    }
    /// <p>The identifier of the view. Both <code>ViewArn</code> and <code>ViewId</code> can be used.</p>
    /// This field is required.
    pub fn view_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.view_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The identifier of the view. Both <code>ViewArn</code> and <code>ViewId</code> can be used.</p>
    pub fn set_view_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.view_id = input;
        self
    }
    /// <p>The identifier of the view. Both <code>ViewArn</code> and <code>ViewId</code> can be used.</p>
    pub fn get_view_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.view_id
    }
    /// <p>The description for the version being published.</p>
    pub fn version_description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.version_description = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The description for the version being published.</p>
    pub fn set_version_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.version_description = input;
        self
    }
    /// <p>The description for the version being published.</p>
    pub fn get_version_description(&self) -> &::std::option::Option<::std::string::String> {
        &self.version_description
    }
    /// <p>Indicates the checksum value of the latest published view content.</p>
    pub fn view_content_sha256(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.view_content_sha256 = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>Indicates the checksum value of the latest published view content.</p>
    pub fn set_view_content_sha256(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.view_content_sha256 = input;
        self
    }
    /// <p>Indicates the checksum value of the latest published view content.</p>
    pub fn get_view_content_sha256(&self) -> &::std::option::Option<::std::string::String> {
        &self.view_content_sha256
    }
    /// Consumes the builder and constructs a [`CreateViewVersionInput`](crate::operation::create_view_version::CreateViewVersionInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::create_view_version::CreateViewVersionInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::create_view_version::CreateViewVersionInput {
            instance_id: self.instance_id,
            view_id: self.view_id,
            version_description: self.version_description,
            view_content_sha256: self.view_content_sha256,
        })
    }
}