aws_sdk_geomaps/operation/get_tile/
_get_tile_input.rs1#[allow(missing_docs)] #[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq)]
5pub struct GetTileInput {
6 pub additional_features: ::std::option::Option<::std::vec::Vec<crate::types::TileAdditionalFeature>>,
8 pub tileset: ::std::option::Option<::std::string::String>,
11 pub z: ::std::option::Option<::std::string::String>,
13 pub x: ::std::option::Option<::std::string::String>,
15 pub y: ::std::option::Option<::std::string::String>,
17 pub key: ::std::option::Option<::std::string::String>,
19}
20impl GetTileInput {
21 pub fn additional_features(&self) -> &[crate::types::TileAdditionalFeature] {
25 self.additional_features.as_deref().unwrap_or_default()
26 }
27 pub fn tileset(&self) -> ::std::option::Option<&str> {
30 self.tileset.as_deref()
31 }
32 pub fn z(&self) -> ::std::option::Option<&str> {
34 self.z.as_deref()
35 }
36 pub fn x(&self) -> ::std::option::Option<&str> {
38 self.x.as_deref()
39 }
40 pub fn y(&self) -> ::std::option::Option<&str> {
42 self.y.as_deref()
43 }
44 pub fn key(&self) -> ::std::option::Option<&str> {
46 self.key.as_deref()
47 }
48}
49impl ::std::fmt::Debug for GetTileInput {
50 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
51 let mut formatter = f.debug_struct("GetTileInput");
52 formatter.field("additional_features", &self.additional_features);
53 formatter.field("tileset", &self.tileset);
54 formatter.field("z", &"*** Sensitive Data Redacted ***");
55 formatter.field("x", &"*** Sensitive Data Redacted ***");
56 formatter.field("y", &"*** Sensitive Data Redacted ***");
57 formatter.field("key", &"*** Sensitive Data Redacted ***");
58 formatter.finish()
59 }
60}
61impl GetTileInput {
62 pub fn builder() -> crate::operation::get_tile::builders::GetTileInputBuilder {
64 crate::operation::get_tile::builders::GetTileInputBuilder::default()
65 }
66}
67
68#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
70#[non_exhaustive]
71pub struct GetTileInputBuilder {
72 pub(crate) additional_features: ::std::option::Option<::std::vec::Vec<crate::types::TileAdditionalFeature>>,
73 pub(crate) tileset: ::std::option::Option<::std::string::String>,
74 pub(crate) z: ::std::option::Option<::std::string::String>,
75 pub(crate) x: ::std::option::Option<::std::string::String>,
76 pub(crate) y: ::std::option::Option<::std::string::String>,
77 pub(crate) key: ::std::option::Option<::std::string::String>,
78}
79impl GetTileInputBuilder {
80 pub fn additional_features(mut self, input: crate::types::TileAdditionalFeature) -> Self {
86 let mut v = self.additional_features.unwrap_or_default();
87 v.push(input);
88 self.additional_features = ::std::option::Option::Some(v);
89 self
90 }
91 pub fn set_additional_features(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::TileAdditionalFeature>>) -> Self {
93 self.additional_features = input;
94 self
95 }
96 pub fn get_additional_features(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::TileAdditionalFeature>> {
98 &self.additional_features
99 }
100 pub fn tileset(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
104 self.tileset = ::std::option::Option::Some(input.into());
105 self
106 }
107 pub fn set_tileset(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
110 self.tileset = input;
111 self
112 }
113 pub fn get_tileset(&self) -> &::std::option::Option<::std::string::String> {
116 &self.tileset
117 }
118 pub fn z(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
121 self.z = ::std::option::Option::Some(input.into());
122 self
123 }
124 pub fn set_z(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
126 self.z = input;
127 self
128 }
129 pub fn get_z(&self) -> &::std::option::Option<::std::string::String> {
131 &self.z
132 }
133 pub fn x(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
136 self.x = ::std::option::Option::Some(input.into());
137 self
138 }
139 pub fn set_x(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
141 self.x = input;
142 self
143 }
144 pub fn get_x(&self) -> &::std::option::Option<::std::string::String> {
146 &self.x
147 }
148 pub fn y(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
151 self.y = ::std::option::Option::Some(input.into());
152 self
153 }
154 pub fn set_y(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
156 self.y = input;
157 self
158 }
159 pub fn get_y(&self) -> &::std::option::Option<::std::string::String> {
161 &self.y
162 }
163 pub fn key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
165 self.key = ::std::option::Option::Some(input.into());
166 self
167 }
168 pub fn set_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
170 self.key = input;
171 self
172 }
173 pub fn get_key(&self) -> &::std::option::Option<::std::string::String> {
175 &self.key
176 }
177 pub fn build(self) -> ::std::result::Result<crate::operation::get_tile::GetTileInput, ::aws_smithy_types::error::operation::BuildError> {
179 ::std::result::Result::Ok(crate::operation::get_tile::GetTileInput {
180 additional_features: self.additional_features,
181 tileset: self.tileset,
182 z: self.z,
183 x: self.x,
184 y: self.y,
185 key: self.key,
186 })
187 }
188}
189impl ::std::fmt::Debug for GetTileInputBuilder {
190 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
191 let mut formatter = f.debug_struct("GetTileInputBuilder");
192 formatter.field("additional_features", &self.additional_features);
193 formatter.field("tileset", &self.tileset);
194 formatter.field("z", &"*** Sensitive Data Redacted ***");
195 formatter.field("x", &"*** Sensitive Data Redacted ***");
196 formatter.field("y", &"*** Sensitive Data Redacted ***");
197 formatter.field("key", &"*** Sensitive Data Redacted ***");
198 formatter.finish()
199 }
200}