#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq)]
pub struct GetProfileRecommendationsOutput {
pub recommendations: ::std::option::Option<::std::vec::Vec<crate::types::Recommendation>>,
_request_id: Option<String>,
}
impl GetProfileRecommendationsOutput {
pub fn recommendations(&self) -> &[crate::types::Recommendation] {
self.recommendations.as_deref().unwrap_or_default()
}
}
impl ::std::fmt::Debug for GetProfileRecommendationsOutput {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("GetProfileRecommendationsOutput");
formatter.field("recommendations", &"*** Sensitive Data Redacted ***");
formatter.field("_request_id", &self._request_id);
formatter.finish()
}
}
impl ::aws_types::request_id::RequestId for GetProfileRecommendationsOutput {
fn request_id(&self) -> Option<&str> {
self._request_id.as_deref()
}
}
impl GetProfileRecommendationsOutput {
pub fn builder() -> crate::operation::get_profile_recommendations::builders::GetProfileRecommendationsOutputBuilder {
crate::operation::get_profile_recommendations::builders::GetProfileRecommendationsOutputBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
#[non_exhaustive]
pub struct GetProfileRecommendationsOutputBuilder {
pub(crate) recommendations: ::std::option::Option<::std::vec::Vec<crate::types::Recommendation>>,
_request_id: Option<String>,
}
impl GetProfileRecommendationsOutputBuilder {
pub fn recommendations(mut self, input: crate::types::Recommendation) -> Self {
let mut v = self.recommendations.unwrap_or_default();
v.push(input);
self.recommendations = ::std::option::Option::Some(v);
self
}
pub fn set_recommendations(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Recommendation>>) -> Self {
self.recommendations = input;
self
}
pub fn get_recommendations(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Recommendation>> {
&self.recommendations
}
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_profile_recommendations::GetProfileRecommendationsOutput {
crate::operation::get_profile_recommendations::GetProfileRecommendationsOutput {
recommendations: self.recommendations,
_request_id: self._request_id,
}
}
}
impl ::std::fmt::Debug for GetProfileRecommendationsOutputBuilder {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("GetProfileRecommendationsOutputBuilder");
formatter.field("recommendations", &"*** Sensitive Data Redacted ***");
formatter.field("_request_id", &self._request_id);
formatter.finish()
}
}