aws-sdk-emrserverless 1.109.0

AWS SDK for EMR Serverless
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 GetResourceDashboardInput {
    /// <p>The ID of the application that the resource belongs to.</p>
    pub application_id: ::std::option::Option<::std::string::String>,
    /// <p>The ID of the resource.</p>
    pub resource_id: ::std::option::Option<::std::string::String>,
    /// <p>The type of resource to access the dashboard for. Currently, only <code>Session</code> is supported.</p>
    pub resource_type: ::std::option::Option<crate::types::ResourceType>,
}
impl GetResourceDashboardInput {
    /// <p>The ID of the application that the resource belongs to.</p>
    pub fn application_id(&self) -> ::std::option::Option<&str> {
        self.application_id.as_deref()
    }
    /// <p>The ID of the resource.</p>
    pub fn resource_id(&self) -> ::std::option::Option<&str> {
        self.resource_id.as_deref()
    }
    /// <p>The type of resource to access the dashboard for. Currently, only <code>Session</code> is supported.</p>
    pub fn resource_type(&self) -> ::std::option::Option<&crate::types::ResourceType> {
        self.resource_type.as_ref()
    }
}
impl GetResourceDashboardInput {
    /// Creates a new builder-style object to manufacture [`GetResourceDashboardInput`](crate::operation::get_resource_dashboard::GetResourceDashboardInput).
    pub fn builder() -> crate::operation::get_resource_dashboard::builders::GetResourceDashboardInputBuilder {
        crate::operation::get_resource_dashboard::builders::GetResourceDashboardInputBuilder::default()
    }
}

/// A builder for [`GetResourceDashboardInput`](crate::operation::get_resource_dashboard::GetResourceDashboardInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetResourceDashboardInputBuilder {
    pub(crate) application_id: ::std::option::Option<::std::string::String>,
    pub(crate) resource_id: ::std::option::Option<::std::string::String>,
    pub(crate) resource_type: ::std::option::Option<crate::types::ResourceType>,
}
impl GetResourceDashboardInputBuilder {
    /// <p>The ID of the application that the resource belongs to.</p>
    /// This field is required.
    pub fn application_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.application_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the application that the resource belongs to.</p>
    pub fn set_application_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.application_id = input;
        self
    }
    /// <p>The ID of the application that the resource belongs to.</p>
    pub fn get_application_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.application_id
    }
    /// <p>The ID of the resource.</p>
    /// This field is required.
    pub fn resource_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.resource_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the resource.</p>
    pub fn set_resource_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.resource_id = input;
        self
    }
    /// <p>The ID of the resource.</p>
    pub fn get_resource_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.resource_id
    }
    /// <p>The type of resource to access the dashboard for. Currently, only <code>Session</code> is supported.</p>
    /// This field is required.
    pub fn resource_type(mut self, input: crate::types::ResourceType) -> Self {
        self.resource_type = ::std::option::Option::Some(input);
        self
    }
    /// <p>The type of resource to access the dashboard for. Currently, only <code>Session</code> is supported.</p>
    pub fn set_resource_type(mut self, input: ::std::option::Option<crate::types::ResourceType>) -> Self {
        self.resource_type = input;
        self
    }
    /// <p>The type of resource to access the dashboard for. Currently, only <code>Session</code> is supported.</p>
    pub fn get_resource_type(&self) -> &::std::option::Option<crate::types::ResourceType> {
        &self.resource_type
    }
    /// Consumes the builder and constructs a [`GetResourceDashboardInput`](crate::operation::get_resource_dashboard::GetResourceDashboardInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::get_resource_dashboard::GetResourceDashboardInput, ::aws_smithy_types::error::operation::BuildError>
    {
        ::std::result::Result::Ok(crate::operation::get_resource_dashboard::GetResourceDashboardInput {
            application_id: self.application_id,
            resource_id: self.resource_id,
            resource_type: self.resource_type,
        })
    }
}