#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct DescribeLagsOutput {
pub lags: ::std::option::Option<::std::vec::Vec<crate::types::Lag>>,
_request_id: Option<String>,
}
impl DescribeLagsOutput {
pub fn lags(&self) -> &[crate::types::Lag] {
self.lags.as_deref().unwrap_or_default()
}
}
impl ::aws_types::request_id::RequestId for DescribeLagsOutput {
fn request_id(&self) -> Option<&str> {
self._request_id.as_deref()
}
}
impl DescribeLagsOutput {
pub fn builder() -> crate::operation::describe_lags::builders::DescribeLagsOutputBuilder {
crate::operation::describe_lags::builders::DescribeLagsOutputBuilder::default()
}
}
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct DescribeLagsOutputBuilder {
pub(crate) lags: ::std::option::Option<::std::vec::Vec<crate::types::Lag>>,
_request_id: Option<String>,
}
impl DescribeLagsOutputBuilder {
pub fn lags(mut self, input: crate::types::Lag) -> Self {
let mut v = self.lags.unwrap_or_default();
v.push(input);
self.lags = ::std::option::Option::Some(v);
self
}
pub fn set_lags(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Lag>>) -> Self {
self.lags = input;
self
}
pub fn get_lags(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Lag>> {
&self.lags
}
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::describe_lags::DescribeLagsOutput {
crate::operation::describe_lags::DescribeLagsOutput {
lags: self.lags,
_request_id: self._request_id,
}
}
}