#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct CreateTokenOutput {
pub app_id: ::std::option::Option<::std::string::String>,
pub challenge_code: ::std::option::Option<::std::string::String>,
pub session_id: ::std::option::Option<::std::string::String>,
pub ttl: ::std::option::Option<::std::string::String>,
_request_id: Option<String>,
}
impl CreateTokenOutput {
pub fn app_id(&self) -> ::std::option::Option<&str> {
self.app_id.as_deref()
}
pub fn challenge_code(&self) -> ::std::option::Option<&str> {
self.challenge_code.as_deref()
}
pub fn session_id(&self) -> ::std::option::Option<&str> {
self.session_id.as_deref()
}
pub fn ttl(&self) -> ::std::option::Option<&str> {
self.ttl.as_deref()
}
}
impl ::aws_types::request_id::RequestId for CreateTokenOutput {
fn request_id(&self) -> Option<&str> {
self._request_id.as_deref()
}
}
impl CreateTokenOutput {
pub fn builder() -> crate::operation::create_token::builders::CreateTokenOutputBuilder {
crate::operation::create_token::builders::CreateTokenOutputBuilder::default()
}
}
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct CreateTokenOutputBuilder {
pub(crate) app_id: ::std::option::Option<::std::string::String>,
pub(crate) challenge_code: ::std::option::Option<::std::string::String>,
pub(crate) session_id: ::std::option::Option<::std::string::String>,
pub(crate) ttl: ::std::option::Option<::std::string::String>,
_request_id: Option<String>,
}
impl CreateTokenOutputBuilder {
pub fn app_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.app_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_app_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.app_id = input;
self
}
pub fn get_app_id(&self) -> &::std::option::Option<::std::string::String> {
&self.app_id
}
pub fn challenge_code(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.challenge_code = ::std::option::Option::Some(input.into());
self
}
pub fn set_challenge_code(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.challenge_code = input;
self
}
pub fn get_challenge_code(&self) -> &::std::option::Option<::std::string::String> {
&self.challenge_code
}
pub fn session_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.session_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_session_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.session_id = input;
self
}
pub fn get_session_id(&self) -> &::std::option::Option<::std::string::String> {
&self.session_id
}
pub fn ttl(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.ttl = ::std::option::Option::Some(input.into());
self
}
pub fn set_ttl(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.ttl = input;
self
}
pub fn get_ttl(&self) -> &::std::option::Option<::std::string::String> {
&self.ttl
}
pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
self._request_id = Some(request_id.into());
self
}
pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
self._request_id = request_id;
self
}
pub fn build(self) -> crate::operation::create_token::CreateTokenOutput {
crate::operation::create_token::CreateTokenOutput {
app_id: self.app_id,
challenge_code: self.challenge_code,
session_id: self.session_id,
ttl: self.ttl,
_request_id: self._request_id,
}
}
}