aws-sdk-appstream 1.111.0

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

/// <p>The custom branding theme, which might include a custom logo, website links, and other branding to display to users.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct Theme {
    /// <p>The stack that has the custom branding theme.</p>
    pub stack_name: ::std::option::Option<::std::string::String>,
    /// <p>The state of the theme.</p>
    pub state: ::std::option::Option<crate::types::ThemeState>,
    /// <p>The browser tab page title.</p>
    pub theme_title_text: ::std::option::Option<::std::string::String>,
    /// <p>The color that is used for the website links, text, buttons, and catalog page background.</p>
    pub theme_styling: ::std::option::Option<crate::types::ThemeStyling>,
    /// <p>The website links that display in the catalog page footer.</p>
    pub theme_footer_links: ::std::option::Option<::std::vec::Vec<crate::types::ThemeFooterLink>>,
    /// <p>The URL of the logo that displays in the catalog page header.</p>
    pub theme_organization_logo_url: ::std::option::Option<::std::string::String>,
    /// <p>The URL of the icon that displays at the top of a user's browser tab during streaming sessions.</p>
    pub theme_favicon_url: ::std::option::Option<::std::string::String>,
    /// <p>The time the theme was created.</p>
    pub created_time: ::std::option::Option<::aws_smithy_types::DateTime>,
}
impl Theme {
    /// <p>The stack that has the custom branding theme.</p>
    pub fn stack_name(&self) -> ::std::option::Option<&str> {
        self.stack_name.as_deref()
    }
    /// <p>The state of the theme.</p>
    pub fn state(&self) -> ::std::option::Option<&crate::types::ThemeState> {
        self.state.as_ref()
    }
    /// <p>The browser tab page title.</p>
    pub fn theme_title_text(&self) -> ::std::option::Option<&str> {
        self.theme_title_text.as_deref()
    }
    /// <p>The color that is used for the website links, text, buttons, and catalog page background.</p>
    pub fn theme_styling(&self) -> ::std::option::Option<&crate::types::ThemeStyling> {
        self.theme_styling.as_ref()
    }
    /// <p>The website links that display in the catalog page footer.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.theme_footer_links.is_none()`.
    pub fn theme_footer_links(&self) -> &[crate::types::ThemeFooterLink] {
        self.theme_footer_links.as_deref().unwrap_or_default()
    }
    /// <p>The URL of the logo that displays in the catalog page header.</p>
    pub fn theme_organization_logo_url(&self) -> ::std::option::Option<&str> {
        self.theme_organization_logo_url.as_deref()
    }
    /// <p>The URL of the icon that displays at the top of a user's browser tab during streaming sessions.</p>
    pub fn theme_favicon_url(&self) -> ::std::option::Option<&str> {
        self.theme_favicon_url.as_deref()
    }
    /// <p>The time the theme was created.</p>
    pub fn created_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.created_time.as_ref()
    }
}
impl Theme {
    /// Creates a new builder-style object to manufacture [`Theme`](crate::types::Theme).
    pub fn builder() -> crate::types::builders::ThemeBuilder {
        crate::types::builders::ThemeBuilder::default()
    }
}

/// A builder for [`Theme`](crate::types::Theme).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct ThemeBuilder {
    pub(crate) stack_name: ::std::option::Option<::std::string::String>,
    pub(crate) state: ::std::option::Option<crate::types::ThemeState>,
    pub(crate) theme_title_text: ::std::option::Option<::std::string::String>,
    pub(crate) theme_styling: ::std::option::Option<crate::types::ThemeStyling>,
    pub(crate) theme_footer_links: ::std::option::Option<::std::vec::Vec<crate::types::ThemeFooterLink>>,
    pub(crate) theme_organization_logo_url: ::std::option::Option<::std::string::String>,
    pub(crate) theme_favicon_url: ::std::option::Option<::std::string::String>,
    pub(crate) created_time: ::std::option::Option<::aws_smithy_types::DateTime>,
}
impl ThemeBuilder {
    /// <p>The stack that has the custom branding theme.</p>
    pub fn stack_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.stack_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The stack that has the custom branding theme.</p>
    pub fn set_stack_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.stack_name = input;
        self
    }
    /// <p>The stack that has the custom branding theme.</p>
    pub fn get_stack_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.stack_name
    }
    /// <p>The state of the theme.</p>
    pub fn state(mut self, input: crate::types::ThemeState) -> Self {
        self.state = ::std::option::Option::Some(input);
        self
    }
    /// <p>The state of the theme.</p>
    pub fn set_state(mut self, input: ::std::option::Option<crate::types::ThemeState>) -> Self {
        self.state = input;
        self
    }
    /// <p>The state of the theme.</p>
    pub fn get_state(&self) -> &::std::option::Option<crate::types::ThemeState> {
        &self.state
    }
    /// <p>The browser tab page title.</p>
    pub fn theme_title_text(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.theme_title_text = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The browser tab page title.</p>
    pub fn set_theme_title_text(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.theme_title_text = input;
        self
    }
    /// <p>The browser tab page title.</p>
    pub fn get_theme_title_text(&self) -> &::std::option::Option<::std::string::String> {
        &self.theme_title_text
    }
    /// <p>The color that is used for the website links, text, buttons, and catalog page background.</p>
    pub fn theme_styling(mut self, input: crate::types::ThemeStyling) -> Self {
        self.theme_styling = ::std::option::Option::Some(input);
        self
    }
    /// <p>The color that is used for the website links, text, buttons, and catalog page background.</p>
    pub fn set_theme_styling(mut self, input: ::std::option::Option<crate::types::ThemeStyling>) -> Self {
        self.theme_styling = input;
        self
    }
    /// <p>The color that is used for the website links, text, buttons, and catalog page background.</p>
    pub fn get_theme_styling(&self) -> &::std::option::Option<crate::types::ThemeStyling> {
        &self.theme_styling
    }
    /// Appends an item to `theme_footer_links`.
    ///
    /// To override the contents of this collection use [`set_theme_footer_links`](Self::set_theme_footer_links).
    ///
    /// <p>The website links that display in the catalog page footer.</p>
    pub fn theme_footer_links(mut self, input: crate::types::ThemeFooterLink) -> Self {
        let mut v = self.theme_footer_links.unwrap_or_default();
        v.push(input);
        self.theme_footer_links = ::std::option::Option::Some(v);
        self
    }
    /// <p>The website links that display in the catalog page footer.</p>
    pub fn set_theme_footer_links(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::ThemeFooterLink>>) -> Self {
        self.theme_footer_links = input;
        self
    }
    /// <p>The website links that display in the catalog page footer.</p>
    pub fn get_theme_footer_links(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::ThemeFooterLink>> {
        &self.theme_footer_links
    }
    /// <p>The URL of the logo that displays in the catalog page header.</p>
    pub fn theme_organization_logo_url(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.theme_organization_logo_url = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The URL of the logo that displays in the catalog page header.</p>
    pub fn set_theme_organization_logo_url(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.theme_organization_logo_url = input;
        self
    }
    /// <p>The URL of the logo that displays in the catalog page header.</p>
    pub fn get_theme_organization_logo_url(&self) -> &::std::option::Option<::std::string::String> {
        &self.theme_organization_logo_url
    }
    /// <p>The URL of the icon that displays at the top of a user's browser tab during streaming sessions.</p>
    pub fn theme_favicon_url(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.theme_favicon_url = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The URL of the icon that displays at the top of a user's browser tab during streaming sessions.</p>
    pub fn set_theme_favicon_url(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.theme_favicon_url = input;
        self
    }
    /// <p>The URL of the icon that displays at the top of a user's browser tab during streaming sessions.</p>
    pub fn get_theme_favicon_url(&self) -> &::std::option::Option<::std::string::String> {
        &self.theme_favicon_url
    }
    /// <p>The time the theme was created.</p>
    pub fn created_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.created_time = ::std::option::Option::Some(input);
        self
    }
    /// <p>The time the theme was created.</p>
    pub fn set_created_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.created_time = input;
        self
    }
    /// <p>The time the theme was created.</p>
    pub fn get_created_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.created_time
    }
    /// Consumes the builder and constructs a [`Theme`](crate::types::Theme).
    pub fn build(self) -> crate::types::Theme {
        crate::types::Theme {
            stack_name: self.stack_name,
            state: self.state,
            theme_title_text: self.theme_title_text,
            theme_styling: self.theme_styling,
            theme_footer_links: self.theme_footer_links,
            theme_organization_logo_url: self.theme_organization_logo_url,
            theme_favicon_url: self.theme_favicon_url,
            created_time: self.created_time,
        }
    }
}