aws-sdk-connect 1.159.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 UpdateViewContentInput {
    /// <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>Indicates the view status as either <code>SAVED</code> or <code>PUBLISHED</code>. The <code>PUBLISHED</code> status will initiate validation on the content.</p>
    pub status: ::std::option::Option<crate::types::ViewStatus>,
    /// <p>View content containing all content necessary to render a view except for runtime input data and the runtime input schema, which is auto-generated by this operation.</p>
    /// <p>The total uncompressed content has a maximum file size of 400kB.</p>
    pub content: ::std::option::Option<crate::types::ViewInputContent>,
}
impl UpdateViewContentInput {
    /// <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>Indicates the view status as either <code>SAVED</code> or <code>PUBLISHED</code>. The <code>PUBLISHED</code> status will initiate validation on the content.</p>
    pub fn status(&self) -> ::std::option::Option<&crate::types::ViewStatus> {
        self.status.as_ref()
    }
    /// <p>View content containing all content necessary to render a view except for runtime input data and the runtime input schema, which is auto-generated by this operation.</p>
    /// <p>The total uncompressed content has a maximum file size of 400kB.</p>
    pub fn content(&self) -> ::std::option::Option<&crate::types::ViewInputContent> {
        self.content.as_ref()
    }
}
impl UpdateViewContentInput {
    /// Creates a new builder-style object to manufacture [`UpdateViewContentInput`](crate::operation::update_view_content::UpdateViewContentInput).
    pub fn builder() -> crate::operation::update_view_content::builders::UpdateViewContentInputBuilder {
        crate::operation::update_view_content::builders::UpdateViewContentInputBuilder::default()
    }
}

/// A builder for [`UpdateViewContentInput`](crate::operation::update_view_content::UpdateViewContentInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateViewContentInputBuilder {
    pub(crate) instance_id: ::std::option::Option<::std::string::String>,
    pub(crate) view_id: ::std::option::Option<::std::string::String>,
    pub(crate) status: ::std::option::Option<crate::types::ViewStatus>,
    pub(crate) content: ::std::option::Option<crate::types::ViewInputContent>,
}
impl UpdateViewContentInputBuilder {
    /// <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>Indicates the view status as either <code>SAVED</code> or <code>PUBLISHED</code>. The <code>PUBLISHED</code> status will initiate validation on the content.</p>
    /// This field is required.
    pub fn status(mut self, input: crate::types::ViewStatus) -> Self {
        self.status = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates the view status as either <code>SAVED</code> or <code>PUBLISHED</code>. The <code>PUBLISHED</code> status will initiate validation on the content.</p>
    pub fn set_status(mut self, input: ::std::option::Option<crate::types::ViewStatus>) -> Self {
        self.status = input;
        self
    }
    /// <p>Indicates the view status as either <code>SAVED</code> or <code>PUBLISHED</code>. The <code>PUBLISHED</code> status will initiate validation on the content.</p>
    pub fn get_status(&self) -> &::std::option::Option<crate::types::ViewStatus> {
        &self.status
    }
    /// <p>View content containing all content necessary to render a view except for runtime input data and the runtime input schema, which is auto-generated by this operation.</p>
    /// <p>The total uncompressed content has a maximum file size of 400kB.</p>
    /// This field is required.
    pub fn content(mut self, input: crate::types::ViewInputContent) -> Self {
        self.content = ::std::option::Option::Some(input);
        self
    }
    /// <p>View content containing all content necessary to render a view except for runtime input data and the runtime input schema, which is auto-generated by this operation.</p>
    /// <p>The total uncompressed content has a maximum file size of 400kB.</p>
    pub fn set_content(mut self, input: ::std::option::Option<crate::types::ViewInputContent>) -> Self {
        self.content = input;
        self
    }
    /// <p>View content containing all content necessary to render a view except for runtime input data and the runtime input schema, which is auto-generated by this operation.</p>
    /// <p>The total uncompressed content has a maximum file size of 400kB.</p>
    pub fn get_content(&self) -> &::std::option::Option<crate::types::ViewInputContent> {
        &self.content
    }
    /// Consumes the builder and constructs a [`UpdateViewContentInput`](crate::operation::update_view_content::UpdateViewContentInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::update_view_content::UpdateViewContentInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::update_view_content::UpdateViewContentInput {
            instance_id: self.instance_id,
            view_id: self.view_id,
            status: self.status,
            content: self.content,
        })
    }
}