aws_sdk_mediapackage/operation/update_channel/
_update_channel_input.rs1#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct UpdateChannelInput {
7 pub description: ::std::option::Option<::std::string::String>,
9 pub id: ::std::option::Option<::std::string::String>,
11}
12impl UpdateChannelInput {
13 pub fn description(&self) -> ::std::option::Option<&str> {
15 self.description.as_deref()
16 }
17 pub fn id(&self) -> ::std::option::Option<&str> {
19 self.id.as_deref()
20 }
21}
22impl UpdateChannelInput {
23 pub fn builder() -> crate::operation::update_channel::builders::UpdateChannelInputBuilder {
25 crate::operation::update_channel::builders::UpdateChannelInputBuilder::default()
26 }
27}
28
29#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
31#[non_exhaustive]
32pub struct UpdateChannelInputBuilder {
33 pub(crate) description: ::std::option::Option<::std::string::String>,
34 pub(crate) id: ::std::option::Option<::std::string::String>,
35}
36impl UpdateChannelInputBuilder {
37 pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
39 self.description = ::std::option::Option::Some(input.into());
40 self
41 }
42 pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
44 self.description = input;
45 self
46 }
47 pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
49 &self.description
50 }
51 pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
54 self.id = ::std::option::Option::Some(input.into());
55 self
56 }
57 pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
59 self.id = input;
60 self
61 }
62 pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
64 &self.id
65 }
66 pub fn build(
68 self,
69 ) -> ::std::result::Result<crate::operation::update_channel::UpdateChannelInput, ::aws_smithy_types::error::operation::BuildError> {
70 ::std::result::Result::Ok(crate::operation::update_channel::UpdateChannelInput {
71 description: self.description,
72 id: self.id,
73 })
74 }
75}