aws_sdk_connectcases/operation/get_case/
_get_case_input.rs#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct GetCaseInput {
pub case_id: ::std::option::Option<::std::string::String>,
pub domain_id: ::std::option::Option<::std::string::String>,
pub fields: ::std::option::Option<::std::vec::Vec<crate::types::FieldIdentifier>>,
pub next_token: ::std::option::Option<::std::string::String>,
}
impl GetCaseInput {
pub fn case_id(&self) -> ::std::option::Option<&str> {
self.case_id.as_deref()
}
pub fn domain_id(&self) -> ::std::option::Option<&str> {
self.domain_id.as_deref()
}
pub fn fields(&self) -> &[crate::types::FieldIdentifier] {
self.fields.as_deref().unwrap_or_default()
}
pub fn next_token(&self) -> ::std::option::Option<&str> {
self.next_token.as_deref()
}
}
impl GetCaseInput {
pub fn builder() -> crate::operation::get_case::builders::GetCaseInputBuilder {
crate::operation::get_case::builders::GetCaseInputBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetCaseInputBuilder {
pub(crate) case_id: ::std::option::Option<::std::string::String>,
pub(crate) domain_id: ::std::option::Option<::std::string::String>,
pub(crate) fields: ::std::option::Option<::std::vec::Vec<crate::types::FieldIdentifier>>,
pub(crate) next_token: ::std::option::Option<::std::string::String>,
}
impl GetCaseInputBuilder {
pub fn case_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.case_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_case_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.case_id = input;
self
}
pub fn get_case_id(&self) -> &::std::option::Option<::std::string::String> {
&self.case_id
}
pub fn domain_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.domain_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_domain_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.domain_id = input;
self
}
pub fn get_domain_id(&self) -> &::std::option::Option<::std::string::String> {
&self.domain_id
}
pub fn fields(mut self, input: crate::types::FieldIdentifier) -> Self {
let mut v = self.fields.unwrap_or_default();
v.push(input);
self.fields = ::std::option::Option::Some(v);
self
}
pub fn set_fields(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::FieldIdentifier>>) -> Self {
self.fields = input;
self
}
pub fn get_fields(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::FieldIdentifier>> {
&self.fields
}
pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.next_token = ::std::option::Option::Some(input.into());
self
}
pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.next_token = input;
self
}
pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
&self.next_token
}
pub fn build(self) -> ::std::result::Result<crate::operation::get_case::GetCaseInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::get_case::GetCaseInput {
case_id: self.case_id,
domain_id: self.domain_id,
fields: self.fields,
next_token: self.next_token,
})
}
}