#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct BatchGetCommentInput {
pub environment_arn: ::std::option::Option<::std::string::String>,
pub project: ::std::option::Option<::std::string::String>,
pub keys: ::std::option::Option<::std::vec::Vec<crate::types::CommentKey>>,
}
impl BatchGetCommentInput {
pub fn environment_arn(&self) -> ::std::option::Option<&str> {
self.environment_arn.as_deref()
}
pub fn project(&self) -> ::std::option::Option<&str> {
self.project.as_deref()
}
pub fn keys(&self) -> &[crate::types::CommentKey] {
self.keys.as_deref().unwrap_or_default()
}
}
impl BatchGetCommentInput {
pub fn builder() -> crate::operation::batch_get_comment::builders::BatchGetCommentInputBuilder {
crate::operation::batch_get_comment::builders::BatchGetCommentInputBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct BatchGetCommentInputBuilder {
pub(crate) environment_arn: ::std::option::Option<::std::string::String>,
pub(crate) project: ::std::option::Option<::std::string::String>,
pub(crate) keys: ::std::option::Option<::std::vec::Vec<crate::types::CommentKey>>,
}
impl BatchGetCommentInputBuilder {
pub fn environment_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.environment_arn = ::std::option::Option::Some(input.into());
self
}
pub fn set_environment_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.environment_arn = input;
self
}
pub fn get_environment_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.environment_arn
}
pub fn project(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.project = ::std::option::Option::Some(input.into());
self
}
pub fn set_project(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.project = input;
self
}
pub fn get_project(&self) -> &::std::option::Option<::std::string::String> {
&self.project
}
pub fn keys(mut self, input: crate::types::CommentKey) -> Self {
let mut v = self.keys.unwrap_or_default();
v.push(input);
self.keys = ::std::option::Option::Some(v);
self
}
pub fn set_keys(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::CommentKey>>) -> Self {
self.keys = input;
self
}
pub fn get_keys(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::CommentKey>> {
&self.keys
}
pub fn build(
self,
) -> ::std::result::Result<crate::operation::batch_get_comment::BatchGetCommentInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::batch_get_comment::BatchGetCommentInput {
environment_arn: self.environment_arn,
project: self.project,
keys: self.keys,
})
}
}