#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct UpdateServiceInput {
pub id: ::std::option::Option<::std::string::String>,
pub service: ::std::option::Option<crate::types::ServiceChange>,
}
impl UpdateServiceInput {
pub fn id(&self) -> ::std::option::Option<&str> {
self.id.as_deref()
}
pub fn service(&self) -> ::std::option::Option<&crate::types::ServiceChange> {
self.service.as_ref()
}
}
impl UpdateServiceInput {
pub fn builder() -> crate::operation::update_service::builders::UpdateServiceInputBuilder {
crate::operation::update_service::builders::UpdateServiceInputBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateServiceInputBuilder {
pub(crate) id: ::std::option::Option<::std::string::String>,
pub(crate) service: ::std::option::Option<crate::types::ServiceChange>,
}
impl UpdateServiceInputBuilder {
pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.id = ::std::option::Option::Some(input.into());
self
}
pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.id = input;
self
}
pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
&self.id
}
pub fn service(mut self, input: crate::types::ServiceChange) -> Self {
self.service = ::std::option::Option::Some(input);
self
}
pub fn set_service(mut self, input: ::std::option::Option<crate::types::ServiceChange>) -> Self {
self.service = input;
self
}
pub fn get_service(&self) -> &::std::option::Option<crate::types::ServiceChange> {
&self.service
}
pub fn build(
self,
) -> ::std::result::Result<crate::operation::update_service::UpdateServiceInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::update_service::UpdateServiceInput {
id: self.id,
service: self.service,
})
}
}