#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct Failure {
pub arn: ::std::option::Option<::std::string::String>,
pub reason: ::std::option::Option<::std::string::String>,
pub detail: ::std::option::Option<::std::string::String>,
}
impl Failure {
pub fn arn(&self) -> ::std::option::Option<&str> {
self.arn.as_deref()
}
pub fn reason(&self) -> ::std::option::Option<&str> {
self.reason.as_deref()
}
pub fn detail(&self) -> ::std::option::Option<&str> {
self.detail.as_deref()
}
}
impl Failure {
pub fn builder() -> crate::types::builders::FailureBuilder {
crate::types::builders::FailureBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct FailureBuilder {
pub(crate) arn: ::std::option::Option<::std::string::String>,
pub(crate) reason: ::std::option::Option<::std::string::String>,
pub(crate) detail: ::std::option::Option<::std::string::String>,
}
impl FailureBuilder {
pub fn arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.arn = ::std::option::Option::Some(input.into());
self
}
pub fn set_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.arn = input;
self
}
pub fn get_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.arn
}
pub fn reason(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.reason = ::std::option::Option::Some(input.into());
self
}
pub fn set_reason(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.reason = input;
self
}
pub fn get_reason(&self) -> &::std::option::Option<::std::string::String> {
&self.reason
}
pub fn detail(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.detail = ::std::option::Option::Some(input.into());
self
}
pub fn set_detail(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.detail = input;
self
}
pub fn get_detail(&self) -> &::std::option::Option<::std::string::String> {
&self.detail
}
pub fn build(self) -> crate::types::Failure {
crate::types::Failure {
arn: self.arn,
reason: self.reason,
detail: self.detail,
}
}
}