aws-sdk-pinpoint 0.28.0

AWS SDK for Amazon Pinpoint
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 GetEndpointInput {
    /// <p>The unique identifier for the application. This identifier is displayed as the <b>Project ID</b> on the Amazon Pinpoint console.</p>
    #[doc(hidden)]
    pub application_id: ::std::option::Option<::std::string::String>,
    /// <p>The unique identifier for the endpoint.</p>
    #[doc(hidden)]
    pub endpoint_id: ::std::option::Option<::std::string::String>,
}
impl GetEndpointInput {
    /// <p>The unique identifier for the application. This identifier is displayed as the <b>Project ID</b> on the Amazon Pinpoint console.</p>
    pub fn application_id(&self) -> ::std::option::Option<&str> {
        self.application_id.as_deref()
    }
    /// <p>The unique identifier for the endpoint.</p>
    pub fn endpoint_id(&self) -> ::std::option::Option<&str> {
        self.endpoint_id.as_deref()
    }
}
impl GetEndpointInput {
    /// Creates a new builder-style object to manufacture [`GetEndpointInput`](crate::operation::get_endpoint::GetEndpointInput).
    pub fn builder() -> crate::operation::get_endpoint::builders::GetEndpointInputBuilder {
        crate::operation::get_endpoint::builders::GetEndpointInputBuilder::default()
    }
}

/// A builder for [`GetEndpointInput`](crate::operation::get_endpoint::GetEndpointInput).
#[non_exhaustive]
#[derive(
    ::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug,
)]
pub struct GetEndpointInputBuilder {
    pub(crate) application_id: ::std::option::Option<::std::string::String>,
    pub(crate) endpoint_id: ::std::option::Option<::std::string::String>,
}
impl GetEndpointInputBuilder {
    /// <p>The unique identifier for the application. This identifier is displayed as the <b>Project ID</b> on the Amazon Pinpoint console.</p>
    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 unique identifier for the application. This identifier is displayed as the <b>Project ID</b> on the Amazon Pinpoint console.</p>
    pub fn set_application_id(
        mut self,
        input: ::std::option::Option<::std::string::String>,
    ) -> Self {
        self.application_id = input;
        self
    }
    /// <p>The unique identifier for the endpoint.</p>
    pub fn endpoint_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.endpoint_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The unique identifier for the endpoint.</p>
    pub fn set_endpoint_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.endpoint_id = input;
        self
    }
    /// Consumes the builder and constructs a [`GetEndpointInput`](crate::operation::get_endpoint::GetEndpointInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<
        crate::operation::get_endpoint::GetEndpointInput,
        ::aws_smithy_http::operation::error::BuildError,
    > {
        ::std::result::Result::Ok(crate::operation::get_endpoint::GetEndpointInput {
            application_id: self.application_id,
            endpoint_id: self.endpoint_id,
        })
    }
}