aws_sdk_appmesh/operation/delete_route/
_delete_route_input.rs1#[allow(missing_docs)] #[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct DeleteRouteInput {
6 pub route_name: ::std::option::Option<::std::string::String>,
8 pub mesh_name: ::std::option::Option<::std::string::String>,
10 pub virtual_router_name: ::std::option::Option<::std::string::String>,
12 pub mesh_owner: ::std::option::Option<::std::string::String>,
14}
15impl DeleteRouteInput {
16 pub fn route_name(&self) -> ::std::option::Option<&str> {
18 self.route_name.as_deref()
19 }
20 pub fn mesh_name(&self) -> ::std::option::Option<&str> {
22 self.mesh_name.as_deref()
23 }
24 pub fn virtual_router_name(&self) -> ::std::option::Option<&str> {
26 self.virtual_router_name.as_deref()
27 }
28 pub fn mesh_owner(&self) -> ::std::option::Option<&str> {
30 self.mesh_owner.as_deref()
31 }
32}
33impl DeleteRouteInput {
34 pub fn builder() -> crate::operation::delete_route::builders::DeleteRouteInputBuilder {
36 crate::operation::delete_route::builders::DeleteRouteInputBuilder::default()
37 }
38}
39
40#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
42#[non_exhaustive]
43pub struct DeleteRouteInputBuilder {
44 pub(crate) route_name: ::std::option::Option<::std::string::String>,
45 pub(crate) mesh_name: ::std::option::Option<::std::string::String>,
46 pub(crate) virtual_router_name: ::std::option::Option<::std::string::String>,
47 pub(crate) mesh_owner: ::std::option::Option<::std::string::String>,
48}
49impl DeleteRouteInputBuilder {
50 pub fn route_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
53 self.route_name = ::std::option::Option::Some(input.into());
54 self
55 }
56 pub fn set_route_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
58 self.route_name = input;
59 self
60 }
61 pub fn get_route_name(&self) -> &::std::option::Option<::std::string::String> {
63 &self.route_name
64 }
65 pub fn mesh_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
68 self.mesh_name = ::std::option::Option::Some(input.into());
69 self
70 }
71 pub fn set_mesh_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
73 self.mesh_name = input;
74 self
75 }
76 pub fn get_mesh_name(&self) -> &::std::option::Option<::std::string::String> {
78 &self.mesh_name
79 }
80 pub fn virtual_router_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
83 self.virtual_router_name = ::std::option::Option::Some(input.into());
84 self
85 }
86 pub fn set_virtual_router_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
88 self.virtual_router_name = input;
89 self
90 }
91 pub fn get_virtual_router_name(&self) -> &::std::option::Option<::std::string::String> {
93 &self.virtual_router_name
94 }
95 pub fn mesh_owner(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
97 self.mesh_owner = ::std::option::Option::Some(input.into());
98 self
99 }
100 pub fn set_mesh_owner(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
102 self.mesh_owner = input;
103 self
104 }
105 pub fn get_mesh_owner(&self) -> &::std::option::Option<::std::string::String> {
107 &self.mesh_owner
108 }
109 pub fn build(self) -> ::std::result::Result<crate::operation::delete_route::DeleteRouteInput, ::aws_smithy_types::error::operation::BuildError> {
111 ::std::result::Result::Ok(crate::operation::delete_route::DeleteRouteInput {
112 route_name: self.route_name,
113 mesh_name: self.mesh_name,
114 virtual_router_name: self.virtual_router_name,
115 mesh_owner: self.mesh_owner,
116 })
117 }
118}