#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct GetPaymentInstrumentOutput {
pub payment_instrument: ::std::option::Option<crate::types::PaymentInstrument>,
_request_id: Option<String>,
}
impl GetPaymentInstrumentOutput {
pub fn payment_instrument(&self) -> ::std::option::Option<&crate::types::PaymentInstrument> {
self.payment_instrument.as_ref()
}
}
impl ::aws_types::request_id::RequestId for GetPaymentInstrumentOutput {
fn request_id(&self) -> Option<&str> {
self._request_id.as_deref()
}
}
impl GetPaymentInstrumentOutput {
pub fn builder() -> crate::operation::get_payment_instrument::builders::GetPaymentInstrumentOutputBuilder {
crate::operation::get_payment_instrument::builders::GetPaymentInstrumentOutputBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetPaymentInstrumentOutputBuilder {
pub(crate) payment_instrument: ::std::option::Option<crate::types::PaymentInstrument>,
_request_id: Option<String>,
}
impl GetPaymentInstrumentOutputBuilder {
pub fn payment_instrument(mut self, input: crate::types::PaymentInstrument) -> Self {
self.payment_instrument = ::std::option::Option::Some(input);
self
}
pub fn set_payment_instrument(mut self, input: ::std::option::Option<crate::types::PaymentInstrument>) -> Self {
self.payment_instrument = input;
self
}
pub fn get_payment_instrument(&self) -> &::std::option::Option<crate::types::PaymentInstrument> {
&self.payment_instrument
}
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::get_payment_instrument::GetPaymentInstrumentOutput {
crate::operation::get_payment_instrument::GetPaymentInstrumentOutput {
payment_instrument: self.payment_instrument,
_request_id: self._request_id,
}
}
}