1 1 | // Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
|
2 2 | #[::pyo3::pyclass]
|
3 - | /// :param tags typing.Optional\[typing.List\[ebs.model.Tag\]\]:
|
4 - | /// :param kms_key_arn typing.Optional\[str\]:
|
5 - | /// :param owner_id typing.Optional\[str\]:
|
6 - | /// :param volume_size typing.Optional\[int\]:
|
7 - | /// :param parent_snapshot_id typing.Optional\[str\]:
|
8 - | /// :param description typing.Optional\[str\]:
|
9 - | /// :param snapshot_id typing.Optional\[str\]:
|
10 - | /// :param block_size typing.Optional\[int\]:
|
11 - | /// :param start_time typing.Optional\[ebs.types.DateTime\]:
|
12 3 | /// :param status typing.Optional\[ebs.model.Status\]:
|
13 4 | /// :rtype None:
|
14 5 | #[allow(missing_docs)] // documentation missing in model
|
15 - | #[derive(::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::hash::Hash)]
|
16 - | pub struct StartSnapshotOutput {
|
17 - | #[pyo3(get, set)]
|
18 - | /// :type typing.Optional\[typing.List\[ebs.model.Tag\]\]:
|
19 - | /// <p>The tags applied to the snapshot. You can specify up to 50 tags per snapshot. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html"> Tagging your Amazon EC2 resources</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
|
20 - | pub tags: ::std::option::Option<::std::vec::Vec<crate::model::Tag>>,
|
21 - | #[pyo3(get, set)]
|
22 - | /// :type typing.Optional\[str\]:
|
23 - | /// <p>The Amazon Resource Name (ARN) of the AWS Key Management Service (AWS KMS) customer master key (CMK) used to encrypt the snapshot.</p>
|
24 - | pub kms_key_arn: ::std::option::Option<::std::string::String>,
|
25 - | #[pyo3(get, set)]
|
26 - | /// :type typing.Optional\[str\]:
|
27 - | /// <p>The AWS account ID of the snapshot owner.</p>
|
28 - | pub owner_id: ::std::option::Option<::std::string::String>,
|
29 - | #[pyo3(get, set)]
|
30 - | /// :type typing.Optional\[int\]:
|
31 - | /// <p>The size of the volume, in GiB.</p>
|
32 - | pub volume_size: ::std::option::Option<i64>,
|
33 - | #[pyo3(get, set)]
|
34 - | /// :type typing.Optional\[str\]:
|
35 - | /// <p>The ID of the parent snapshot.</p>
|
36 - | pub parent_snapshot_id: ::std::option::Option<::std::string::String>,
|
37 - | #[pyo3(get, set)]
|
38 - | /// :type typing.Optional\[str\]:
|
39 - | /// <p>The description of the snapshot.</p>
|
40 - | pub description: ::std::option::Option<::std::string::String>,
|
41 - | #[pyo3(get, set)]
|
42 - | /// :type typing.Optional\[str\]:
|
43 - | /// <p>The ID of the snapshot.</p>
|
44 - | pub snapshot_id: ::std::option::Option<::std::string::String>,
|
45 - | #[pyo3(get, set)]
|
46 - | /// :type typing.Optional\[int\]:
|
47 - | /// <p>The size of the blocks in the snapshot, in bytes.</p>
|
48 - | pub block_size: ::std::option::Option<i32>,
|
49 - | #[pyo3(get, set)]
|
50 - | /// :type typing.Optional\[ebs.types.DateTime\]:
|
51 - | /// <p>The timestamp when the snapshot was created.</p>
|
52 - | pub start_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
6 + | #[derive(
|
7 + | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
8 + | )]
|
9 + | pub struct CompleteSnapshotOutput {
|
53 10 | #[pyo3(get, set)]
|
54 11 | /// :type typing.Optional\[ebs.model.Status\]:
|
55 12 | /// <p>The status of the snapshot.</p>
|
56 13 | pub status: ::std::option::Option<crate::model::Status>,
|
57 14 | }
|
58 - | impl StartSnapshotOutput {
|
59 - | /// <p>The tags applied to the snapshot. You can specify up to 50 tags per snapshot. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html"> Tagging your Amazon EC2 resources</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
|
60 - | pub fn tags(&self) -> ::std::option::Option<&[crate::model::Tag]> {
|
61 - | self.tags.as_deref()
|
62 - | }
|
63 - | /// <p>The Amazon Resource Name (ARN) of the AWS Key Management Service (AWS KMS) customer master key (CMK) used to encrypt the snapshot.</p>
|
64 - | pub fn kms_key_arn(&self) -> ::std::option::Option<&str> {
|
65 - | self.kms_key_arn.as_deref()
|
66 - | }
|
67 - | /// <p>The AWS account ID of the snapshot owner.</p>
|
68 - | pub fn owner_id(&self) -> ::std::option::Option<&str> {
|
69 - | self.owner_id.as_deref()
|
70 - | }
|
71 - | /// <p>The size of the volume, in GiB.</p>
|
72 - | pub fn volume_size(&self) -> ::std::option::Option<i64> {
|
73 - | self.volume_size
|
74 - | }
|
75 - | /// <p>The ID of the parent snapshot.</p>
|
76 - | pub fn parent_snapshot_id(&self) -> ::std::option::Option<&str> {
|
77 - | self.parent_snapshot_id.as_deref()
|
78 - | }
|
79 - | /// <p>The description of the snapshot.</p>
|
80 - | pub fn description(&self) -> ::std::option::Option<&str> {
|
81 - | self.description.as_deref()
|
82 - | }
|
83 - | /// <p>The ID of the snapshot.</p>
|
84 - | pub fn snapshot_id(&self) -> ::std::option::Option<&str> {
|
85 - | self.snapshot_id.as_deref()
|
86 - | }
|
87 - | /// <p>The size of the blocks in the snapshot, in bytes.</p>
|
88 - | pub fn block_size(&self) -> ::std::option::Option<i32> {
|
89 - | self.block_size
|
90 - | }
|
91 - | /// <p>The timestamp when the snapshot was created.</p>
|
92 - | pub fn start_time(
|
93 - | &self,
|
94 - | ) -> ::std::option::Option<&::aws_smithy_http_server_python::types::DateTime> {
|
95 - | self.start_time.as_ref()
|
96 - | }
|
15 + | impl CompleteSnapshotOutput {
|
97 16 | /// <p>The status of the snapshot.</p>
|
98 17 | pub fn status(&self) -> ::std::option::Option<&crate::model::Status> {
|
99 18 | self.status.as_ref()
|
100 19 | }
|
101 20 | }
|
102 - | impl ::std::fmt::Debug for StartSnapshotOutput {
|
103 - | fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
104 - | let mut formatter = f.debug_struct("StartSnapshotOutput");
|
105 - | formatter.field("tags", &self.tags);
|
106 - | formatter.field("kms_key_arn", &"*** Sensitive Data Redacted ***");
|
107 - | formatter.field("owner_id", &self.owner_id);
|
108 - | formatter.field("volume_size", &self.volume_size);
|
109 - | formatter.field("parent_snapshot_id", &self.parent_snapshot_id);
|
110 - | formatter.field("description", &self.description);
|
111 - | formatter.field("snapshot_id", &self.snapshot_id);
|
112 - | formatter.field("block_size", &self.block_size);
|
113 - | formatter.field("start_time", &self.start_time);
|
114 - | formatter.field("status", &self.status);
|
115 - | formatter.finish()
|
116 - | }
|
117 - | }
|
118 21 | #[allow(clippy::new_without_default)]
|
119 22 | #[allow(clippy::too_many_arguments)]
|
120 23 | #[::pyo3::pymethods]
|
121 - | impl StartSnapshotOutput {
|
24 + | impl CompleteSnapshotOutput {
|
122 25 | #[new]
|
123 - | pub fn new(
|
124 - | tags: ::std::option::Option<::std::vec::Vec<crate::model::Tag>>,
|
125 - | kms_key_arn: ::std::option::Option<::std::string::String>,
|
126 - | owner_id: ::std::option::Option<::std::string::String>,
|
127 - | volume_size: ::std::option::Option<i64>,
|
128 - | parent_snapshot_id: ::std::option::Option<::std::string::String>,
|
129 - | description: ::std::option::Option<::std::string::String>,
|
130 - | snapshot_id: ::std::option::Option<::std::string::String>,
|
131 - | block_size: ::std::option::Option<i32>,
|
132 - | start_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
133 - | status: ::std::option::Option<crate::model::Status>,
|
134 - | ) -> Self {
|
135 - | Self {
|
136 - | tags,
|
137 - | kms_key_arn,
|
138 - | owner_id,
|
139 - | volume_size,
|
140 - | parent_snapshot_id,
|
141 - | description,
|
142 - | snapshot_id,
|
143 - | block_size,
|
144 - | start_time,
|
145 - | status,
|
146 - | }
|
26 + | pub fn new(status: ::std::option::Option<crate::model::Status>) -> Self {
|
27 + | Self { status }
|
147 28 | }
|
148 29 | fn __repr__(&self) -> String {
|
149 30 | format!("{self:?}")
|
150 31 | }
|
151 32 | fn __str__(&self) -> String {
|
152 33 | format!("{self:?}")
|
153 34 | }
|
154 35 | }
|
155 - | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<StartSnapshotOutput> {
|
36 + | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<CompleteSnapshotOutput> {
|
156 37 | fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
|
157 - | ob.extract::<StartSnapshotOutput>().map(Box::new)
|
38 + | ob.extract::<CompleteSnapshotOutput>().map(Box::new)
|
158 39 | }
|
159 40 | }
|
160 41 |
|
161 - | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<StartSnapshotOutput> {
|
42 + | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<CompleteSnapshotOutput> {
|
162 43 | fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
|
163 44 | (*self).into_py(py)
|
164 45 | }
|
165 46 | }
|
166 - | impl StartSnapshotOutput {
|
167 - | /// Creates a new builder-style object to manufacture [`StartSnapshotOutput`](crate::output::StartSnapshotOutput).
|
168 - | pub fn builder() -> crate::output::start_snapshot_output::Builder {
|
169 - | crate::output::start_snapshot_output::Builder::default()
|
47 + | impl CompleteSnapshotOutput {
|
48 + | /// Creates a new builder-style object to manufacture [`CompleteSnapshotOutput`](crate::output::CompleteSnapshotOutput).
|
49 + | pub fn builder() -> crate::output::complete_snapshot_output::Builder {
|
50 + | crate::output::complete_snapshot_output::Builder::default()
|
170 51 | }
|
171 52 | }
|
172 53 |
|
173 54 | #[::pyo3::pyclass]
|
55 + | /// :param block_data ebs.types.ByteStream:
|
56 + | /// :param data_length typing.Optional\[int\]:
|
174 57 | /// :param checksum_algorithm typing.Optional\[ebs.model.ChecksumAlgorithm\]:
|
175 58 | /// :param checksum typing.Optional\[str\]:
|
176 59 | /// :rtype None:
|
177 60 | #[allow(missing_docs)] // documentation missing in model
|
178 - | #[derive(
|
179 - | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
180 - | )]
|
181 - | pub struct PutSnapshotBlockOutput {
|
61 + | #[derive(::std::clone::Clone)]
|
62 + | pub struct GetSnapshotBlockOutput {
|
63 + | #[pyo3(get, set)]
|
64 + | /// :type typing.Optional\[int\]:
|
65 + | /// <p>The size of the data in the block.</p>
|
66 + | pub data_length: ::std::option::Option<i32>,
|
182 67 | #[pyo3(get, set)]
|
183 68 | /// :type typing.Optional\[ebs.model.ChecksumAlgorithm\]:
|
184 - | /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
|
69 + | /// <p>The algorithm used to generate the checksum for the block, such as SHA256.</p>
|
185 70 | pub checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
186 71 | #[pyo3(get, set)]
|
187 72 | /// :type typing.Optional\[str\]:
|
188 - | /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
|
73 + | /// <p>The checksum generated for the block, which is Base64 encoded.</p>
|
189 74 | pub checksum: ::std::option::Option<::std::string::String>,
|
75 + | #[pyo3(get, set)]
|
76 + | /// :type ebs.types.ByteStream:
|
77 + | /// <p>The data content of the block.</p>
|
78 + | pub block_data: ::aws_smithy_http_server_python::types::ByteStream,
|
190 79 | }
|
191 - | impl PutSnapshotBlockOutput {
|
192 - | /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
|
80 + | impl GetSnapshotBlockOutput {
|
81 + | /// <p>The size of the data in the block.</p>
|
82 + | pub fn data_length(&self) -> ::std::option::Option<i32> {
|
83 + | self.data_length
|
84 + | }
|
85 + | /// <p>The algorithm used to generate the checksum for the block, such as SHA256.</p>
|
193 86 | pub fn checksum_algorithm(&self) -> ::std::option::Option<&crate::model::ChecksumAlgorithm> {
|
194 87 | self.checksum_algorithm.as_ref()
|
195 88 | }
|
196 - | /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
|
89 + | /// <p>The checksum generated for the block, which is Base64 encoded.</p>
|
197 90 | pub fn checksum(&self) -> ::std::option::Option<&str> {
|
198 91 | self.checksum.as_deref()
|
199 92 | }
|
93 + | /// <p>The data content of the block.</p>
|
94 + | pub fn block_data(&self) -> &::aws_smithy_http_server_python::types::ByteStream {
|
95 + | &self.block_data
|
96 + | }
|
97 + | }
|
98 + | impl ::std::fmt::Debug for GetSnapshotBlockOutput {
|
99 + | fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
100 + | let mut formatter = f.debug_struct("GetSnapshotBlockOutput");
|
101 + | formatter.field("data_length", &self.data_length);
|
102 + | formatter.field("checksum_algorithm", &self.checksum_algorithm);
|
103 + | formatter.field("checksum", &self.checksum);
|
104 + | formatter.field("block_data", &"*** Sensitive Data Redacted ***");
|
105 + | formatter.finish()
|
106 + | }
|
200 107 | }
|
201 108 | #[allow(clippy::new_without_default)]
|
202 109 | #[allow(clippy::too_many_arguments)]
|
203 110 | #[::pyo3::pymethods]
|
204 - | impl PutSnapshotBlockOutput {
|
111 + | impl GetSnapshotBlockOutput {
|
205 112 | #[new]
|
206 113 | pub fn new(
|
114 + | block_data: ::aws_smithy_http_server_python::types::ByteStream,
|
115 + | data_length: ::std::option::Option<i32>,
|
207 116 | checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
208 117 | checksum: ::std::option::Option<::std::string::String>,
|
209 118 | ) -> Self {
|
210 119 | Self {
|
120 + | block_data,
|
121 + | data_length,
|
211 122 | checksum_algorithm,
|
212 123 | checksum,
|
213 124 | }
|
214 125 | }
|
215 126 | fn __repr__(&self) -> String {
|
216 127 | format!("{self:?}")
|
217 128 | }
|
218 129 | fn __str__(&self) -> String {
|
219 130 | format!("{self:?}")
|
220 131 | }
|
221 132 | }
|
222 - | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<PutSnapshotBlockOutput> {
|
133 + | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<GetSnapshotBlockOutput> {
|
223 134 | fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
|
224 - | ob.extract::<PutSnapshotBlockOutput>().map(Box::new)
|
135 + | ob.extract::<GetSnapshotBlockOutput>().map(Box::new)
|
225 136 | }
|
226 137 | }
|
227 138 |
|
228 - | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<PutSnapshotBlockOutput> {
|
139 + | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<GetSnapshotBlockOutput> {
|
229 140 | fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
|
230 141 | (*self).into_py(py)
|
231 142 | }
|
232 143 | }
|
233 - | impl PutSnapshotBlockOutput {
|
234 - | /// Creates a new builder-style object to manufacture [`PutSnapshotBlockOutput`](crate::output::PutSnapshotBlockOutput).
|
235 - | pub fn builder() -> crate::output::put_snapshot_block_output::Builder {
|
236 - | crate::output::put_snapshot_block_output::Builder::default()
|
144 + | impl GetSnapshotBlockOutput {
|
145 + | /// Creates a new builder-style object to manufacture [`GetSnapshotBlockOutput`](crate::output::GetSnapshotBlockOutput).
|
146 + | pub fn builder() -> crate::output::get_snapshot_block_output::Builder {
|
147 + | crate::output::get_snapshot_block_output::Builder::default()
|
237 148 | }
|
238 149 | }
|
239 150 |
|
240 151 | #[::pyo3::pyclass]
|
152 + | /// :param block_size typing.Optional\[int\]:
|
153 + | /// :param expiry_time typing.Optional\[ebs.types.DateTime\]:
|
241 154 | /// :param volume_size typing.Optional\[int\]:
|
242 155 | /// :param next_token typing.Optional\[str\]:
|
243 - | /// :param expiry_time typing.Optional\[ebs.types.DateTime\]:
|
244 - | /// :param blocks typing.Optional\[typing.List\[ebs.model.Block\]\]:
|
245 - | /// :param block_size typing.Optional\[int\]:
|
156 + | /// :param changed_blocks typing.Optional\[typing.List\[ebs.model.ChangedBlock\]\]:
|
246 157 | /// :rtype None:
|
247 158 | #[allow(missing_docs)] // documentation missing in model
|
248 - | #[derive(::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::hash::Hash)]
|
249 - | pub struct ListSnapshotBlocksOutput {
|
159 + | #[derive(
|
160 + | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
161 + | )]
|
162 + | pub struct ListChangedBlocksOutput {
|
163 + | #[pyo3(get, set)]
|
164 + | /// :type typing.Optional\[int\]:
|
165 + | /// <p>The size of the block.</p>
|
166 + | pub block_size: ::std::option::Option<i32>,
|
167 + | #[pyo3(get, set)]
|
168 + | /// :type typing.Optional\[ebs.types.DateTime\]:
|
169 + | /// <p>The time when the <code>BlockToken</code> expires.</p>
|
170 + | pub expiry_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
250 171 | #[pyo3(get, set)]
|
251 172 | /// :type typing.Optional\[int\]:
|
252 173 | /// <p>The size of the volume in GB.</p>
|
253 174 | pub volume_size: ::std::option::Option<i64>,
|
254 175 | #[pyo3(get, set)]
|
255 176 | /// :type typing.Optional\[str\]:
|
256 177 | /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
|
257 178 | pub next_token: ::std::option::Option<::std::string::String>,
|
258 179 | #[pyo3(get, set)]
|
259 - | /// :type typing.Optional\[ebs.types.DateTime\]:
|
260 - | /// <p>The time when the <code>BlockToken</code> expires.</p>
|
261 - | pub expiry_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
262 - | #[pyo3(get, set)]
|
263 - | /// :type typing.Optional\[typing.List\[ebs.model.Block\]\]:
|
264 - | /// <p>An array of objects containing information about the blocks.</p>
|
265 - | pub blocks: ::std::option::Option<::std::vec::Vec<crate::model::Block>>,
|
266 - | #[pyo3(get, set)]
|
267 - | /// :type typing.Optional\[int\]:
|
268 - | /// <p>The size of the block.</p>
|
269 - | pub block_size: ::std::option::Option<i32>,
|
180 + | /// :type typing.Optional\[typing.List\[ebs.model.ChangedBlock\]\]:
|
181 + | /// <p>An array of objects containing information about the changed blocks.</p>
|
182 + | pub changed_blocks: ::std::option::Option<::std::vec::Vec<crate::model::ChangedBlock>>,
|
270 183 | }
|
271 - | impl ListSnapshotBlocksOutput {
|
272 - | /// <p>The size of the volume in GB.</p>
|
273 - | pub fn volume_size(&self) -> ::std::option::Option<i64> {
|
274 - | self.volume_size
|
275 - | }
|
276 - | /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
|
277 - | pub fn next_token(&self) -> ::std::option::Option<&str> {
|
278 - | self.next_token.as_deref()
|
184 + | impl ListChangedBlocksOutput {
|
185 + | /// <p>The size of the block.</p>
|
186 + | pub fn block_size(&self) -> ::std::option::Option<i32> {
|
187 + | self.block_size
|
279 188 | }
|
280 189 | /// <p>The time when the <code>BlockToken</code> expires.</p>
|
281 190 | pub fn expiry_time(
|
282 191 | &self,
|
283 192 | ) -> ::std::option::Option<&::aws_smithy_http_server_python::types::DateTime> {
|
284 193 | self.expiry_time.as_ref()
|
285 194 | }
|
286 - | /// <p>An array of objects containing information about the blocks.</p>
|
287 - | pub fn blocks(&self) -> ::std::option::Option<&[crate::model::Block]> {
|
288 - | self.blocks.as_deref()
|
195 + | /// <p>The size of the volume in GB.</p>
|
196 + | pub fn volume_size(&self) -> ::std::option::Option<i64> {
|
197 + | self.volume_size
|
289 198 | }
|
290 - | /// <p>The size of the block.</p>
|
291 - | pub fn block_size(&self) -> ::std::option::Option<i32> {
|
292 - | self.block_size
|
199 + | /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
|
200 + | pub fn next_token(&self) -> ::std::option::Option<&str> {
|
201 + | self.next_token.as_deref()
|
293 202 | }
|
294 - | }
|
295 - | impl ::std::fmt::Debug for ListSnapshotBlocksOutput {
|
296 - | fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
297 - | let mut formatter = f.debug_struct("ListSnapshotBlocksOutput");
|
298 - | formatter.field("volume_size", &self.volume_size);
|
299 - | formatter.field("next_token", &self.next_token);
|
300 - | formatter.field("expiry_time", &self.expiry_time);
|
301 - | formatter.field("blocks", &"*** Sensitive Data Redacted ***");
|
302 - | formatter.field("block_size", &self.block_size);
|
303 - | formatter.finish()
|
203 + | /// <p>An array of objects containing information about the changed blocks.</p>
|
204 + | pub fn changed_blocks(&self) -> ::std::option::Option<&[crate::model::ChangedBlock]> {
|
205 + | self.changed_blocks.as_deref()
|
304 206 | }
|
305 207 | }
|
306 208 | #[allow(clippy::new_without_default)]
|
307 209 | #[allow(clippy::too_many_arguments)]
|
308 210 | #[::pyo3::pymethods]
|
309 - | impl ListSnapshotBlocksOutput {
|
211 + | impl ListChangedBlocksOutput {
|
310 212 | #[new]
|
311 213 | pub fn new(
|
214 + | block_size: ::std::option::Option<i32>,
|
215 + | expiry_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
312 216 | volume_size: ::std::option::Option<i64>,
|
313 217 | next_token: ::std::option::Option<::std::string::String>,
|
314 - | expiry_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
315 - | blocks: ::std::option::Option<::std::vec::Vec<crate::model::Block>>,
|
316 - | block_size: ::std::option::Option<i32>,
|
218 + | changed_blocks: ::std::option::Option<::std::vec::Vec<crate::model::ChangedBlock>>,
|
317 219 | ) -> Self {
|
318 220 | Self {
|
221 + | block_size,
|
222 + | expiry_time,
|
319 223 | volume_size,
|
320 224 | next_token,
|
321 - | expiry_time,
|
322 - | blocks,
|
323 - | block_size,
|
225 + | changed_blocks,
|
324 226 | }
|
325 227 | }
|
326 228 | fn __repr__(&self) -> String {
|
327 229 | format!("{self:?}")
|
328 230 | }
|
329 231 | fn __str__(&self) -> String {
|
330 232 | format!("{self:?}")
|
331 233 | }
|
332 234 | }
|
333 - | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<ListSnapshotBlocksOutput> {
|
235 + | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<ListChangedBlocksOutput> {
|
334 236 | fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
|
335 - | ob.extract::<ListSnapshotBlocksOutput>().map(Box::new)
|
237 + | ob.extract::<ListChangedBlocksOutput>().map(Box::new)
|
336 238 | }
|
337 239 | }
|
338 240 |
|
339 - | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<ListSnapshotBlocksOutput> {
|
241 + | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<ListChangedBlocksOutput> {
|
340 242 | fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
|
341 243 | (*self).into_py(py)
|
342 244 | }
|
343 245 | }
|
344 - | impl ListSnapshotBlocksOutput {
|
345 - | /// Creates a new builder-style object to manufacture [`ListSnapshotBlocksOutput`](crate::output::ListSnapshotBlocksOutput).
|
346 - | pub fn builder() -> crate::output::list_snapshot_blocks_output::Builder {
|
347 - | crate::output::list_snapshot_blocks_output::Builder::default()
|
246 + | impl ListChangedBlocksOutput {
|
247 + | /// Creates a new builder-style object to manufacture [`ListChangedBlocksOutput`](crate::output::ListChangedBlocksOutput).
|
248 + | pub fn builder() -> crate::output::list_changed_blocks_output::Builder {
|
249 + | crate::output::list_changed_blocks_output::Builder::default()
|
348 250 | }
|
349 251 | }
|
350 252 |
|
351 253 | #[::pyo3::pyclass]
|
352 - | /// :param block_size typing.Optional\[int\]:
|
353 - | /// :param expiry_time typing.Optional\[ebs.types.DateTime\]:
|
354 254 | /// :param volume_size typing.Optional\[int\]:
|
355 255 | /// :param next_token typing.Optional\[str\]:
|
356 - | /// :param changed_blocks typing.Optional\[typing.List\[ebs.model.ChangedBlock\]\]:
|
256 + | /// :param expiry_time typing.Optional\[ebs.types.DateTime\]:
|
257 + | /// :param blocks typing.Optional\[typing.List\[ebs.model.Block\]\]:
|
258 + | /// :param block_size typing.Optional\[int\]:
|
357 259 | /// :rtype None:
|
358 260 | #[allow(missing_docs)] // documentation missing in model
|
359 - | #[derive(
|
360 - | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
361 - | )]
|
362 - | pub struct ListChangedBlocksOutput {
|
363 - | #[pyo3(get, set)]
|
364 - | /// :type typing.Optional\[int\]:
|
365 - | /// <p>The size of the block.</p>
|
366 - | pub block_size: ::std::option::Option<i32>,
|
367 - | #[pyo3(get, set)]
|
368 - | /// :type typing.Optional\[ebs.types.DateTime\]:
|
369 - | /// <p>The time when the <code>BlockToken</code> expires.</p>
|
370 - | pub expiry_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
261 + | #[derive(::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::hash::Hash)]
|
262 + | pub struct ListSnapshotBlocksOutput {
|
371 263 | #[pyo3(get, set)]
|
372 264 | /// :type typing.Optional\[int\]:
|
373 265 | /// <p>The size of the volume in GB.</p>
|
374 266 | pub volume_size: ::std::option::Option<i64>,
|
375 267 | #[pyo3(get, set)]
|
376 268 | /// :type typing.Optional\[str\]:
|
377 269 | /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
|
378 270 | pub next_token: ::std::option::Option<::std::string::String>,
|
379 271 | #[pyo3(get, set)]
|
380 - | /// :type typing.Optional\[typing.List\[ebs.model.ChangedBlock\]\]:
|
381 - | /// <p>An array of objects containing information about the changed blocks.</p>
|
382 - | pub changed_blocks: ::std::option::Option<::std::vec::Vec<crate::model::ChangedBlock>>,
|
383 - | }
|
384 - | impl ListChangedBlocksOutput {
|
272 + | /// :type typing.Optional\[ebs.types.DateTime\]:
|
273 + | /// <p>The time when the <code>BlockToken</code> expires.</p>
|
274 + | pub expiry_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
275 + | #[pyo3(get, set)]
|
276 + | /// :type typing.Optional\[typing.List\[ebs.model.Block\]\]:
|
277 + | /// <p>An array of objects containing information about the blocks.</p>
|
278 + | pub blocks: ::std::option::Option<::std::vec::Vec<crate::model::Block>>,
|
279 + | #[pyo3(get, set)]
|
280 + | /// :type typing.Optional\[int\]:
|
385 281 | /// <p>The size of the block.</p>
|
386 - | pub fn block_size(&self) -> ::std::option::Option<i32> {
|
387 - | self.block_size
|
282 + | pub block_size: ::std::option::Option<i32>,
|
283 + | }
|
284 + | impl ListSnapshotBlocksOutput {
|
285 + | /// <p>The size of the volume in GB.</p>
|
286 + | pub fn volume_size(&self) -> ::std::option::Option<i64> {
|
287 + | self.volume_size
|
288 + | }
|
289 + | /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
|
290 + | pub fn next_token(&self) -> ::std::option::Option<&str> {
|
291 + | self.next_token.as_deref()
|
388 292 | }
|
389 293 | /// <p>The time when the <code>BlockToken</code> expires.</p>
|
390 294 | pub fn expiry_time(
|
391 295 | &self,
|
392 296 | ) -> ::std::option::Option<&::aws_smithy_http_server_python::types::DateTime> {
|
393 297 | self.expiry_time.as_ref()
|
394 298 | }
|
395 - | /// <p>The size of the volume in GB.</p>
|
396 - | pub fn volume_size(&self) -> ::std::option::Option<i64> {
|
397 - | self.volume_size
|
299 + | /// <p>An array of objects containing information about the blocks.</p>
|
300 + | pub fn blocks(&self) -> ::std::option::Option<&[crate::model::Block]> {
|
301 + | self.blocks.as_deref()
|
398 302 | }
|
399 - | /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
|
400 - | pub fn next_token(&self) -> ::std::option::Option<&str> {
|
401 - | self.next_token.as_deref()
|
303 + | /// <p>The size of the block.</p>
|
304 + | pub fn block_size(&self) -> ::std::option::Option<i32> {
|
305 + | self.block_size
|
402 306 | }
|
403 - | /// <p>An array of objects containing information about the changed blocks.</p>
|
404 - | pub fn changed_blocks(&self) -> ::std::option::Option<&[crate::model::ChangedBlock]> {
|
405 - | self.changed_blocks.as_deref()
|
307 + | }
|
308 + | impl ::std::fmt::Debug for ListSnapshotBlocksOutput {
|
309 + | fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
310 + | let mut formatter = f.debug_struct("ListSnapshotBlocksOutput");
|
311 + | formatter.field("volume_size", &self.volume_size);
|
312 + | formatter.field("next_token", &self.next_token);
|
313 + | formatter.field("expiry_time", &self.expiry_time);
|
314 + | formatter.field("blocks", &"*** Sensitive Data Redacted ***");
|
315 + | formatter.field("block_size", &self.block_size);
|
316 + | formatter.finish()
|
406 317 | }
|
407 318 | }
|
408 319 | #[allow(clippy::new_without_default)]
|
409 320 | #[allow(clippy::too_many_arguments)]
|
410 321 | #[::pyo3::pymethods]
|
411 - | impl ListChangedBlocksOutput {
|
322 + | impl ListSnapshotBlocksOutput {
|
412 323 | #[new]
|
413 324 | pub fn new(
|
414 - | block_size: ::std::option::Option<i32>,
|
415 - | expiry_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
416 325 | volume_size: ::std::option::Option<i64>,
|
417 326 | next_token: ::std::option::Option<::std::string::String>,
|
418 - | changed_blocks: ::std::option::Option<::std::vec::Vec<crate::model::ChangedBlock>>,
|
327 + | expiry_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
328 + | blocks: ::std::option::Option<::std::vec::Vec<crate::model::Block>>,
|
329 + | block_size: ::std::option::Option<i32>,
|
419 330 | ) -> Self {
|
420 331 | Self {
|
421 - | block_size,
|
422 - | expiry_time,
|
423 332 | volume_size,
|
424 333 | next_token,
|
425 - | changed_blocks,
|
334 + | expiry_time,
|
335 + | blocks,
|
336 + | block_size,
|
426 337 | }
|
427 338 | }
|
428 339 | fn __repr__(&self) -> String {
|
429 340 | format!("{self:?}")
|
430 341 | }
|
431 342 | fn __str__(&self) -> String {
|
432 343 | format!("{self:?}")
|
433 344 | }
|
434 345 | }
|
435 - | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<ListChangedBlocksOutput> {
|
346 + | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<ListSnapshotBlocksOutput> {
|
436 347 | fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
|
437 - | ob.extract::<ListChangedBlocksOutput>().map(Box::new)
|
348 + | ob.extract::<ListSnapshotBlocksOutput>().map(Box::new)
|
438 349 | }
|
439 350 | }
|
440 351 |
|
441 - | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<ListChangedBlocksOutput> {
|
352 + | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<ListSnapshotBlocksOutput> {
|
442 353 | fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
|
443 354 | (*self).into_py(py)
|
444 355 | }
|
445 356 | }
|
446 - | impl ListChangedBlocksOutput {
|
447 - | /// Creates a new builder-style object to manufacture [`ListChangedBlocksOutput`](crate::output::ListChangedBlocksOutput).
|
448 - | pub fn builder() -> crate::output::list_changed_blocks_output::Builder {
|
449 - | crate::output::list_changed_blocks_output::Builder::default()
|
357 + | impl ListSnapshotBlocksOutput {
|
358 + | /// Creates a new builder-style object to manufacture [`ListSnapshotBlocksOutput`](crate::output::ListSnapshotBlocksOutput).
|
359 + | pub fn builder() -> crate::output::list_snapshot_blocks_output::Builder {
|
360 + | crate::output::list_snapshot_blocks_output::Builder::default()
|
450 361 | }
|
451 362 | }
|
452 363 |
|
453 364 | #[::pyo3::pyclass]
|
454 - | /// :param block_data ebs.types.ByteStream:
|
455 - | /// :param data_length typing.Optional\[int\]:
|
456 365 | /// :param checksum_algorithm typing.Optional\[ebs.model.ChecksumAlgorithm\]:
|
457 366 | /// :param checksum typing.Optional\[str\]:
|
458 367 | /// :rtype None:
|
459 368 | #[allow(missing_docs)] // documentation missing in model
|
460 - | #[derive(::std::clone::Clone)]
|
461 - | pub struct GetSnapshotBlockOutput {
|
462 - | #[pyo3(get, set)]
|
463 - | /// :type typing.Optional\[int\]:
|
464 - | /// <p>The size of the data in the block.</p>
|
465 - | pub data_length: ::std::option::Option<i32>,
|
369 + | #[derive(
|
370 + | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
371 + | )]
|
372 + | pub struct PutSnapshotBlockOutput {
|
466 373 | #[pyo3(get, set)]
|
467 374 | /// :type typing.Optional\[ebs.model.ChecksumAlgorithm\]:
|
468 - | /// <p>The algorithm used to generate the checksum for the block, such as SHA256.</p>
|
375 + | /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
|
469 376 | pub checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
470 377 | #[pyo3(get, set)]
|
471 378 | /// :type typing.Optional\[str\]:
|
472 - | /// <p>The checksum generated for the block, which is Base64 encoded.</p>
|
379 + | /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
|
473 380 | pub checksum: ::std::option::Option<::std::string::String>,
|
474 - | #[pyo3(get, set)]
|
475 - | /// :type ebs.types.ByteStream:
|
476 - | /// <p>The data content of the block.</p>
|
477 - | pub block_data: ::aws_smithy_http_server_python::types::ByteStream,
|
478 381 | }
|
479 - | impl GetSnapshotBlockOutput {
|
480 - | /// <p>The size of the data in the block.</p>
|
481 - | pub fn data_length(&self) -> ::std::option::Option<i32> {
|
482 - | self.data_length
|
483 - | }
|
484 - | /// <p>The algorithm used to generate the checksum for the block, such as SHA256.</p>
|
382 + | impl PutSnapshotBlockOutput {
|
383 + | /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
|
485 384 | pub fn checksum_algorithm(&self) -> ::std::option::Option<&crate::model::ChecksumAlgorithm> {
|
486 385 | self.checksum_algorithm.as_ref()
|
487 386 | }
|
488 - | /// <p>The checksum generated for the block, which is Base64 encoded.</p>
|
387 + | /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
|
489 388 | pub fn checksum(&self) -> ::std::option::Option<&str> {
|
490 389 | self.checksum.as_deref()
|
491 390 | }
|
492 - | /// <p>The data content of the block.</p>
|
493 - | pub fn block_data(&self) -> &::aws_smithy_http_server_python::types::ByteStream {
|
494 - | &self.block_data
|
495 - | }
|
496 - | }
|
497 - | impl ::std::fmt::Debug for GetSnapshotBlockOutput {
|
498 - | fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
499 - | let mut formatter = f.debug_struct("GetSnapshotBlockOutput");
|
500 - | formatter.field("data_length", &self.data_length);
|
501 - | formatter.field("checksum_algorithm", &self.checksum_algorithm);
|
502 - | formatter.field("checksum", &self.checksum);
|
503 - | formatter.field("block_data", &"*** Sensitive Data Redacted ***");
|
504 - | formatter.finish()
|
505 - | }
|
506 391 | }
|
507 392 | #[allow(clippy::new_without_default)]
|
508 393 | #[allow(clippy::too_many_arguments)]
|
509 394 | #[::pyo3::pymethods]
|
510 - | impl GetSnapshotBlockOutput {
|
395 + | impl PutSnapshotBlockOutput {
|
511 396 | #[new]
|
512 397 | pub fn new(
|
513 - | block_data: ::aws_smithy_http_server_python::types::ByteStream,
|
514 - | data_length: ::std::option::Option<i32>,
|
515 398 | checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
516 399 | checksum: ::std::option::Option<::std::string::String>,
|
517 400 | ) -> Self {
|
518 401 | Self {
|
519 - | block_data,
|
520 - | data_length,
|
521 402 | checksum_algorithm,
|
522 403 | checksum,
|
523 404 | }
|
524 405 | }
|
525 406 | fn __repr__(&self) -> String {
|
526 407 | format!("{self:?}")
|
527 408 | }
|
528 409 | fn __str__(&self) -> String {
|
529 410 | format!("{self:?}")
|
530 411 | }
|
531 412 | }
|
532 - | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<GetSnapshotBlockOutput> {
|
413 + | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<PutSnapshotBlockOutput> {
|
533 414 | fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
|
534 - | ob.extract::<GetSnapshotBlockOutput>().map(Box::new)
|
415 + | ob.extract::<PutSnapshotBlockOutput>().map(Box::new)
|
535 416 | }
|
536 417 | }
|
537 418 |
|
538 - | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<GetSnapshotBlockOutput> {
|
419 + | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<PutSnapshotBlockOutput> {
|
539 420 | fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
|
540 421 | (*self).into_py(py)
|
541 422 | }
|
542 423 | }
|
543 - | impl GetSnapshotBlockOutput {
|
544 - | /// Creates a new builder-style object to manufacture [`GetSnapshotBlockOutput`](crate::output::GetSnapshotBlockOutput).
|
545 - | pub fn builder() -> crate::output::get_snapshot_block_output::Builder {
|
546 - | crate::output::get_snapshot_block_output::Builder::default()
|
424 + | impl PutSnapshotBlockOutput {
|
425 + | /// Creates a new builder-style object to manufacture [`PutSnapshotBlockOutput`](crate::output::PutSnapshotBlockOutput).
|
426 + | pub fn builder() -> crate::output::put_snapshot_block_output::Builder {
|
427 + | crate::output::put_snapshot_block_output::Builder::default()
|
547 428 | }
|
548 429 | }
|
549 430 |
|
550 431 | #[::pyo3::pyclass]
|
432 + | /// :param tags typing.Optional\[typing.List\[ebs.model.Tag\]\]:
|
433 + | /// :param kms_key_arn typing.Optional\[str\]:
|
434 + | /// :param owner_id typing.Optional\[str\]:
|
435 + | /// :param volume_size typing.Optional\[int\]:
|
436 + | /// :param parent_snapshot_id typing.Optional\[str\]:
|
437 + | /// :param description typing.Optional\[str\]:
|
438 + | /// :param snapshot_id typing.Optional\[str\]:
|
439 + | /// :param block_size typing.Optional\[int\]:
|
440 + | /// :param start_time typing.Optional\[ebs.types.DateTime\]:
|
551 441 | /// :param status typing.Optional\[ebs.model.Status\]:
|
552 442 | /// :rtype None:
|
553 443 | #[allow(missing_docs)] // documentation missing in model
|
554 - | #[derive(
|
555 - | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
556 - | )]
|
557 - | pub struct CompleteSnapshotOutput {
|
444 + | #[derive(::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::hash::Hash)]
|
445 + | pub struct StartSnapshotOutput {
|
446 + | #[pyo3(get, set)]
|
447 + | /// :type typing.Optional\[typing.List\[ebs.model.Tag\]\]:
|
448 + | /// <p>The tags applied to the snapshot. You can specify up to 50 tags per snapshot. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html"> Tagging your Amazon EC2 resources</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
|
449 + | pub tags: ::std::option::Option<::std::vec::Vec<crate::model::Tag>>,
|
450 + | #[pyo3(get, set)]
|
451 + | /// :type typing.Optional\[str\]:
|
452 + | /// <p>The Amazon Resource Name (ARN) of the AWS Key Management Service (AWS KMS) customer master key (CMK) used to encrypt the snapshot.</p>
|
453 + | pub kms_key_arn: ::std::option::Option<::std::string::String>,
|
454 + | #[pyo3(get, set)]
|
455 + | /// :type typing.Optional\[str\]:
|
456 + | /// <p>The AWS account ID of the snapshot owner.</p>
|
457 + | pub owner_id: ::std::option::Option<::std::string::String>,
|
458 + | #[pyo3(get, set)]
|
459 + | /// :type typing.Optional\[int\]:
|
460 + | /// <p>The size of the volume, in GiB.</p>
|
461 + | pub volume_size: ::std::option::Option<i64>,
|
462 + | #[pyo3(get, set)]
|
463 + | /// :type typing.Optional\[str\]:
|
464 + | /// <p>The ID of the parent snapshot.</p>
|
465 + | pub parent_snapshot_id: ::std::option::Option<::std::string::String>,
|
466 + | #[pyo3(get, set)]
|
467 + | /// :type typing.Optional\[str\]:
|
468 + | /// <p>The description of the snapshot.</p>
|
469 + | pub description: ::std::option::Option<::std::string::String>,
|
470 + | #[pyo3(get, set)]
|
471 + | /// :type typing.Optional\[str\]:
|
472 + | /// <p>The ID of the snapshot.</p>
|
473 + | pub snapshot_id: ::std::option::Option<::std::string::String>,
|
474 + | #[pyo3(get, set)]
|
475 + | /// :type typing.Optional\[int\]:
|
476 + | /// <p>The size of the blocks in the snapshot, in bytes.</p>
|
477 + | pub block_size: ::std::option::Option<i32>,
|
478 + | #[pyo3(get, set)]
|
479 + | /// :type typing.Optional\[ebs.types.DateTime\]:
|
480 + | /// <p>The timestamp when the snapshot was created.</p>
|
481 + | pub start_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
558 482 | #[pyo3(get, set)]
|
559 483 | /// :type typing.Optional\[ebs.model.Status\]:
|
560 484 | /// <p>The status of the snapshot.</p>
|
561 485 | pub status: ::std::option::Option<crate::model::Status>,
|
562 486 | }
|
563 - | impl CompleteSnapshotOutput {
|
487 + | impl StartSnapshotOutput {
|
488 + | /// <p>The tags applied to the snapshot. You can specify up to 50 tags per snapshot. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html"> Tagging your Amazon EC2 resources</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
|
489 + | pub fn tags(&self) -> ::std::option::Option<&[crate::model::Tag]> {
|
490 + | self.tags.as_deref()
|
491 + | }
|
492 + | /// <p>The Amazon Resource Name (ARN) of the AWS Key Management Service (AWS KMS) customer master key (CMK) used to encrypt the snapshot.</p>
|
493 + | pub fn kms_key_arn(&self) -> ::std::option::Option<&str> {
|
494 + | self.kms_key_arn.as_deref()
|
495 + | }
|
496 + | /// <p>The AWS account ID of the snapshot owner.</p>
|
497 + | pub fn owner_id(&self) -> ::std::option::Option<&str> {
|
498 + | self.owner_id.as_deref()
|
499 + | }
|
500 + | /// <p>The size of the volume, in GiB.</p>
|
501 + | pub fn volume_size(&self) -> ::std::option::Option<i64> {
|
502 + | self.volume_size
|
503 + | }
|
504 + | /// <p>The ID of the parent snapshot.</p>
|
505 + | pub fn parent_snapshot_id(&self) -> ::std::option::Option<&str> {
|
506 + | self.parent_snapshot_id.as_deref()
|
507 + | }
|
508 + | /// <p>The description of the snapshot.</p>
|
509 + | pub fn description(&self) -> ::std::option::Option<&str> {
|
510 + | self.description.as_deref()
|
511 + | }
|
512 + | /// <p>The ID of the snapshot.</p>
|
513 + | pub fn snapshot_id(&self) -> ::std::option::Option<&str> {
|
514 + | self.snapshot_id.as_deref()
|
515 + | }
|
516 + | /// <p>The size of the blocks in the snapshot, in bytes.</p>
|
517 + | pub fn block_size(&self) -> ::std::option::Option<i32> {
|
518 + | self.block_size
|
519 + | }
|
520 + | /// <p>The timestamp when the snapshot was created.</p>
|
521 + | pub fn start_time(
|
522 + | &self,
|
523 + | ) -> ::std::option::Option<&::aws_smithy_http_server_python::types::DateTime> {
|
524 + | self.start_time.as_ref()
|
525 + | }
|
564 526 | /// <p>The status of the snapshot.</p>
|
565 527 | pub fn status(&self) -> ::std::option::Option<&crate::model::Status> {
|
566 528 | self.status.as_ref()
|
567 529 | }
|
568 530 | }
|
531 + | impl ::std::fmt::Debug for StartSnapshotOutput {
|
532 + | fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
|
533 + | let mut formatter = f.debug_struct("StartSnapshotOutput");
|
534 + | formatter.field("tags", &self.tags);
|
535 + | formatter.field("kms_key_arn", &"*** Sensitive Data Redacted ***");
|
536 + | formatter.field("owner_id", &self.owner_id);
|
537 + | formatter.field("volume_size", &self.volume_size);
|
538 + | formatter.field("parent_snapshot_id", &self.parent_snapshot_id);
|
539 + | formatter.field("description", &self.description);
|
540 + | formatter.field("snapshot_id", &self.snapshot_id);
|
541 + | formatter.field("block_size", &self.block_size);
|
542 + | formatter.field("start_time", &self.start_time);
|
543 + | formatter.field("status", &self.status);
|
544 + | formatter.finish()
|
545 + | }
|
546 + | }
|
569 547 | #[allow(clippy::new_without_default)]
|
570 548 | #[allow(clippy::too_many_arguments)]
|
571 549 | #[::pyo3::pymethods]
|
572 - | impl CompleteSnapshotOutput {
|
550 + | impl StartSnapshotOutput {
|
573 551 | #[new]
|
574 - | pub fn new(status: ::std::option::Option<crate::model::Status>) -> Self {
|
575 - | Self { status }
|
552 + | pub fn new(
|
553 + | tags: ::std::option::Option<::std::vec::Vec<crate::model::Tag>>,
|
554 + | kms_key_arn: ::std::option::Option<::std::string::String>,
|
555 + | owner_id: ::std::option::Option<::std::string::String>,
|
556 + | volume_size: ::std::option::Option<i64>,
|
557 + | parent_snapshot_id: ::std::option::Option<::std::string::String>,
|
558 + | description: ::std::option::Option<::std::string::String>,
|
559 + | snapshot_id: ::std::option::Option<::std::string::String>,
|
560 + | block_size: ::std::option::Option<i32>,
|
561 + | start_time: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
562 + | status: ::std::option::Option<crate::model::Status>,
|
563 + | ) -> Self {
|
564 + | Self {
|
565 + | tags,
|
566 + | kms_key_arn,
|
567 + | owner_id,
|
568 + | volume_size,
|
569 + | parent_snapshot_id,
|
570 + | description,
|
571 + | snapshot_id,
|
572 + | block_size,
|
573 + | start_time,
|
574 + | status,
|
575 + | }
|
576 576 | }
|
577 577 | fn __repr__(&self) -> String {
|
578 578 | format!("{self:?}")
|
579 579 | }
|
580 580 | fn __str__(&self) -> String {
|
581 581 | format!("{self:?}")
|
582 582 | }
|
583 583 | }
|
584 - | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<CompleteSnapshotOutput> {
|
584 + | impl<'source> ::pyo3::FromPyObject<'source> for std::boxed::Box<StartSnapshotOutput> {
|
585 585 | fn extract(ob: &'source ::pyo3::PyAny) -> ::pyo3::PyResult<Self> {
|
586 - | ob.extract::<CompleteSnapshotOutput>().map(Box::new)
|
586 + | ob.extract::<StartSnapshotOutput>().map(Box::new)
|
587 587 | }
|
588 588 | }
|
589 589 |
|
590 - | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<CompleteSnapshotOutput> {
|
590 + | impl ::pyo3::IntoPy<::pyo3::PyObject> for std::boxed::Box<StartSnapshotOutput> {
|
591 591 | fn into_py(self, py: ::pyo3::Python<'_>) -> ::pyo3::PyObject {
|
592 592 | (*self).into_py(py)
|
593 593 | }
|
594 594 | }
|
595 - | impl CompleteSnapshotOutput {
|
596 - | /// Creates a new builder-style object to manufacture [`CompleteSnapshotOutput`](crate::output::CompleteSnapshotOutput).
|
597 - | pub fn builder() -> crate::output::complete_snapshot_output::Builder {
|
598 - | crate::output::complete_snapshot_output::Builder::default()
|
595 + | impl StartSnapshotOutput {
|
596 + | /// Creates a new builder-style object to manufacture [`StartSnapshotOutput`](crate::output::StartSnapshotOutput).
|
597 + | pub fn builder() -> crate::output::start_snapshot_output::Builder {
|
598 + | crate::output::start_snapshot_output::Builder::default()
|
599 599 | }
|
600 600 | }
|
601 - | /// See [`StartSnapshotOutput`](crate::output::StartSnapshotOutput).
|
602 - | pub mod start_snapshot_output {
|
601 + | /// See [`CompleteSnapshotOutput`](crate::output::CompleteSnapshotOutput).
|
602 + | pub mod complete_snapshot_output {
|
603 603 |
|
604 - | impl ::std::convert::From<Builder> for crate::output::StartSnapshotOutput {
|
604 + | impl ::std::convert::From<Builder> for crate::output::CompleteSnapshotOutput {
|
605 605 | fn from(builder: Builder) -> Self {
|
606 606 | builder.build()
|
607 607 | }
|
608 608 | }
|
609 - | /// A builder for [`StartSnapshotOutput`](crate::output::StartSnapshotOutput).
|
610 - | #[derive(::std::clone::Clone, ::std::default::Default)]
|
609 + | /// A builder for [`CompleteSnapshotOutput`](crate::output::CompleteSnapshotOutput).
|
610 + | #[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
|
611 611 | pub struct Builder {
|
612 - | pub(crate) tags: ::std::option::Option<::std::vec::Vec<crate::model::Tag>>,
|
613 - | pub(crate) kms_key_arn: ::std::option::Option<::std::string::String>,
|
614 - | pub(crate) owner_id: ::std::option::Option<::std::string::String>,
|
615 - | pub(crate) volume_size: ::std::option::Option<i64>,
|
616 - | pub(crate) parent_snapshot_id: ::std::option::Option<::std::string::String>,
|
617 - | pub(crate) description: ::std::option::Option<::std::string::String>,
|
618 - | pub(crate) snapshot_id: ::std::option::Option<::std::string::String>,
|
619 - | pub(crate) block_size: ::std::option::Option<i32>,
|
620 - | pub(crate) start_time:
|
621 - | ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
622 612 | pub(crate) status: ::std::option::Option<crate::model::Status>,
|
623 613 | }
|
624 614 | impl Builder {
|
625 - | /// <p>The tags applied to the snapshot. You can specify up to 50 tags per snapshot. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html"> Tagging your Amazon EC2 resources</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
|
626 - | pub fn tags(
|
627 - | mut self,
|
628 - | input: ::std::option::Option<::std::vec::Vec<crate::model::Tag>>,
|
629 - | ) -> Self {
|
630 - | self.tags = input;
|
615 + | /// <p>The status of the snapshot.</p>
|
616 + | pub fn status(mut self, input: ::std::option::Option<crate::model::Status>) -> Self {
|
617 + | self.status = input;
|
631 618 | self
|
632 619 | }
|
633 - | /// <p>The Amazon Resource Name (ARN) of the AWS Key Management Service (AWS KMS) customer master key (CMK) used to encrypt the snapshot.</p>
|
634 - | pub fn kms_key_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
635 - | self.kms_key_arn = input;
|
636 - | self
|
620 + | /// Consumes the builder and constructs a [`CompleteSnapshotOutput`](crate::output::CompleteSnapshotOutput).
|
621 + | pub fn build(self) -> crate::output::CompleteSnapshotOutput {
|
622 + | self.build_enforcing_required_and_enum_traits()
|
637 623 | }
|
638 - | /// <p>The AWS account ID of the snapshot owner.</p>
|
639 - | pub fn owner_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
640 - | self.owner_id = input;
|
641 - | self
|
624 + | fn build_enforcing_required_and_enum_traits(self) -> crate::output::CompleteSnapshotOutput {
|
625 + | crate::output::CompleteSnapshotOutput {
|
626 + | status: self.status,
|
642 627 | }
|
643 - | /// <p>The size of the volume, in GiB.</p>
|
644 - | pub fn volume_size(mut self, input: ::std::option::Option<i64>) -> Self {
|
645 - | self.volume_size = input;
|
646 - | self
|
647 628 | }
|
648 - | /// <p>The ID of the parent snapshot.</p>
|
649 - | pub fn parent_snapshot_id(
|
650 - | mut self,
|
651 - | input: ::std::option::Option<::std::string::String>,
|
652 - | ) -> Self {
|
653 - | self.parent_snapshot_id = input;
|
654 - | self
|
655 629 | }
|
656 - | /// <p>The description of the snapshot.</p>
|
657 - | pub fn description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
658 - | self.description = input;
|
659 - | self
|
630 + | }
|
631 + | /// See [`GetSnapshotBlockOutput`](crate::output::GetSnapshotBlockOutput).
|
632 + | pub mod get_snapshot_block_output {
|
633 + |
|
634 + | impl ::std::convert::From<Builder> for crate::output::GetSnapshotBlockOutput {
|
635 + | fn from(builder: Builder) -> Self {
|
636 + | builder.build()
|
660 637 | }
|
661 - | /// <p>The ID of the snapshot.</p>
|
662 - | pub fn snapshot_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
663 - | self.snapshot_id = input;
|
664 - | self
|
665 638 | }
|
666 - | /// <p>The size of the blocks in the snapshot, in bytes.</p>
|
667 - | pub fn block_size(mut self, input: ::std::option::Option<i32>) -> Self {
|
668 - | self.block_size = input;
|
639 + | /// A builder for [`GetSnapshotBlockOutput`](crate::output::GetSnapshotBlockOutput).
|
640 + | #[derive(::std::clone::Clone, ::std::default::Default)]
|
641 + | pub struct Builder {
|
642 + | pub(crate) data_length: ::std::option::Option<i32>,
|
643 + | pub(crate) checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
644 + | pub(crate) checksum: ::std::option::Option<::std::string::String>,
|
645 + | pub(crate) block_data:
|
646 + | ::std::option::Option<::aws_smithy_http_server_python::types::ByteStream>,
|
647 + | }
|
648 + | impl Builder {
|
649 + | /// <p>The size of the data in the block.</p>
|
650 + | pub fn data_length(mut self, input: ::std::option::Option<i32>) -> Self {
|
651 + | self.data_length = input;
|
669 652 | self
|
670 653 | }
|
671 - | /// <p>The timestamp when the snapshot was created.</p>
|
672 - | pub fn start_time(
|
654 + | /// <p>The algorithm used to generate the checksum for the block, such as SHA256.</p>
|
655 + | pub fn checksum_algorithm(
|
673 656 | mut self,
|
674 - | input: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
657 + | input: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
675 658 | ) -> Self {
|
676 - | self.start_time = input;
|
659 + | self.checksum_algorithm = input;
|
677 660 | self
|
678 661 | }
|
679 - | /// <p>The status of the snapshot.</p>
|
680 - | pub fn status(mut self, input: ::std::option::Option<crate::model::Status>) -> Self {
|
681 - | self.status = input;
|
662 + | /// <p>The checksum generated for the block, which is Base64 encoded.</p>
|
663 + | pub fn checksum(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
664 + | self.checksum = input;
|
682 665 | self
|
683 666 | }
|
684 - | /// Consumes the builder and constructs a [`StartSnapshotOutput`](crate::output::StartSnapshotOutput).
|
685 - | pub fn build(self) -> crate::output::StartSnapshotOutput {
|
667 + | /// <p>The data content of the block.</p>
|
668 + | pub fn block_data(
|
669 + | mut self,
|
670 + | input: ::aws_smithy_http_server_python::types::ByteStream,
|
671 + | ) -> Self {
|
672 + | self.block_data = Some(input);
|
673 + | self
|
674 + | }
|
675 + | /// Consumes the builder and constructs a [`GetSnapshotBlockOutput`](crate::output::GetSnapshotBlockOutput).
|
676 + | pub fn build(self) -> crate::output::GetSnapshotBlockOutput {
|
686 677 | self.build_enforcing_required_and_enum_traits()
|
687 678 | }
|
688 - | fn build_enforcing_required_and_enum_traits(self) -> crate::output::StartSnapshotOutput {
|
689 - | crate::output::StartSnapshotOutput {
|
690 - | tags: self.tags,
|
691 - | kms_key_arn: self.kms_key_arn,
|
692 - | owner_id: self.owner_id,
|
693 - | volume_size: self.volume_size,
|
694 - | parent_snapshot_id: self.parent_snapshot_id,
|
695 - | description: self.description,
|
696 - | snapshot_id: self.snapshot_id,
|
697 - | block_size: self.block_size,
|
698 - | start_time: self.start_time,
|
699 - | status: self.status,
|
679 + | fn build_enforcing_required_and_enum_traits(self) -> crate::output::GetSnapshotBlockOutput {
|
680 + | crate::output::GetSnapshotBlockOutput {
|
681 + | data_length: self.data_length,
|
682 + | checksum_algorithm: self.checksum_algorithm,
|
683 + | checksum: self.checksum,
|
684 + | block_data: self.block_data.unwrap_or_default(),
|
700 685 | }
|
701 686 | }
|
702 687 | }
|
703 688 | }
|
704 - | /// See [`PutSnapshotBlockOutput`](crate::output::PutSnapshotBlockOutput).
|
705 - | pub mod put_snapshot_block_output {
|
689 + | /// See [`ListChangedBlocksOutput`](crate::output::ListChangedBlocksOutput).
|
690 + | pub mod list_changed_blocks_output {
|
706 691 |
|
707 - | impl ::std::convert::From<Builder> for crate::output::PutSnapshotBlockOutput {
|
692 + | impl ::std::convert::From<Builder> for crate::output::ListChangedBlocksOutput {
|
708 693 | fn from(builder: Builder) -> Self {
|
709 694 | builder.build()
|
710 695 | }
|
711 696 | }
|
712 - | /// A builder for [`PutSnapshotBlockOutput`](crate::output::PutSnapshotBlockOutput).
|
697 + | /// A builder for [`ListChangedBlocksOutput`](crate::output::ListChangedBlocksOutput).
|
713 698 | #[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
|
714 699 | pub struct Builder {
|
715 - | pub(crate) checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
716 - | pub(crate) checksum: ::std::option::Option<::std::string::String>,
|
700 + | pub(crate) block_size: ::std::option::Option<i32>,
|
701 + | pub(crate) expiry_time:
|
702 + | ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
703 + | pub(crate) volume_size: ::std::option::Option<i64>,
|
704 + | pub(crate) next_token: ::std::option::Option<::std::string::String>,
|
705 + | pub(crate) changed_blocks:
|
706 + | ::std::option::Option<::std::vec::Vec<crate::model::ChangedBlock>>,
|
717 707 | }
|
718 708 | impl Builder {
|
719 - | /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
|
720 - | pub fn checksum_algorithm(
|
709 + | /// <p>The size of the block.</p>
|
710 + | pub fn block_size(mut self, input: ::std::option::Option<i32>) -> Self {
|
711 + | self.block_size = input;
|
712 + | self
|
713 + | }
|
714 + | /// <p>The time when the <code>BlockToken</code> expires.</p>
|
715 + | pub fn expiry_time(
|
721 716 | mut self,
|
722 - | input: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
717 + | input: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
723 718 | ) -> Self {
|
724 - | self.checksum_algorithm = input;
|
719 + | self.expiry_time = input;
|
725 720 | self
|
726 721 | }
|
727 - | /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
|
728 - | pub fn checksum(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
729 - | self.checksum = input;
|
722 + | /// <p>The size of the volume in GB.</p>
|
723 + | pub fn volume_size(mut self, input: ::std::option::Option<i64>) -> Self {
|
724 + | self.volume_size = input;
|
730 725 | self
|
731 726 | }
|
732 - | /// Consumes the builder and constructs a [`PutSnapshotBlockOutput`](crate::output::PutSnapshotBlockOutput).
|
733 - | pub fn build(self) -> crate::output::PutSnapshotBlockOutput {
|
727 + | /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
|
728 + | pub fn next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
729 + | self.next_token = input;
|
730 + | self
|
731 + | }
|
732 + | /// <p>An array of objects containing information about the changed blocks.</p>
|
733 + | pub fn changed_blocks(
|
734 + | mut self,
|
735 + | input: ::std::option::Option<::std::vec::Vec<crate::model::ChangedBlock>>,
|
736 + | ) -> Self {
|
737 + | self.changed_blocks = input;
|
738 + | self
|
739 + | }
|
740 + | /// Consumes the builder and constructs a [`ListChangedBlocksOutput`](crate::output::ListChangedBlocksOutput).
|
741 + | pub fn build(self) -> crate::output::ListChangedBlocksOutput {
|
734 742 | self.build_enforcing_required_and_enum_traits()
|
735 743 | }
|
736 - | fn build_enforcing_required_and_enum_traits(self) -> crate::output::PutSnapshotBlockOutput {
|
737 - | crate::output::PutSnapshotBlockOutput {
|
738 - | checksum_algorithm: self.checksum_algorithm,
|
739 - | checksum: self.checksum,
|
744 + | fn build_enforcing_required_and_enum_traits(
|
745 + | self,
|
746 + | ) -> crate::output::ListChangedBlocksOutput {
|
747 + | crate::output::ListChangedBlocksOutput {
|
748 + | block_size: self.block_size,
|
749 + | expiry_time: self.expiry_time,
|
750 + | volume_size: self.volume_size,
|
751 + | next_token: self.next_token,
|
752 + | changed_blocks: self.changed_blocks,
|
740 753 | }
|
741 754 | }
|
742 755 | }
|
743 756 | }
|
744 757 | /// See [`ListSnapshotBlocksOutput`](crate::output::ListSnapshotBlocksOutput).
|
745 758 | pub mod list_snapshot_blocks_output {
|
746 759 |
|
747 760 | impl ::std::convert::From<Builder> for crate::output::ListSnapshotBlocksOutput {
|
748 761 | fn from(builder: Builder) -> Self {
|
749 762 | builder.build()
|
801 814 | crate::output::ListSnapshotBlocksOutput {
|
802 815 | volume_size: self.volume_size,
|
803 816 | next_token: self.next_token,
|
804 817 | expiry_time: self.expiry_time,
|
805 818 | blocks: self.blocks,
|
806 819 | block_size: self.block_size,
|
807 820 | }
|
808 821 | }
|
809 822 | }
|
810 823 | }
|
811 - | /// See [`ListChangedBlocksOutput`](crate::output::ListChangedBlocksOutput).
|
812 - | pub mod list_changed_blocks_output {
|
824 + | /// See [`PutSnapshotBlockOutput`](crate::output::PutSnapshotBlockOutput).
|
825 + | pub mod put_snapshot_block_output {
|
813 826 |
|
814 - | impl ::std::convert::From<Builder> for crate::output::ListChangedBlocksOutput {
|
827 + | impl ::std::convert::From<Builder> for crate::output::PutSnapshotBlockOutput {
|
815 828 | fn from(builder: Builder) -> Self {
|
816 829 | builder.build()
|
817 830 | }
|
818 831 | }
|
819 - | /// A builder for [`ListChangedBlocksOutput`](crate::output::ListChangedBlocksOutput).
|
832 + | /// A builder for [`PutSnapshotBlockOutput`](crate::output::PutSnapshotBlockOutput).
|
820 833 | #[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
|
821 834 | pub struct Builder {
|
822 - | pub(crate) block_size: ::std::option::Option<i32>,
|
823 - | pub(crate) expiry_time:
|
824 - | ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
825 - | pub(crate) volume_size: ::std::option::Option<i64>,
|
826 - | pub(crate) next_token: ::std::option::Option<::std::string::String>,
|
827 - | pub(crate) changed_blocks:
|
828 - | ::std::option::Option<::std::vec::Vec<crate::model::ChangedBlock>>,
|
835 + | pub(crate) checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
836 + | pub(crate) checksum: ::std::option::Option<::std::string::String>,
|
829 837 | }
|
830 838 | impl Builder {
|
831 - | /// <p>The size of the block.</p>
|
832 - | pub fn block_size(mut self, input: ::std::option::Option<i32>) -> Self {
|
833 - | self.block_size = input;
|
834 - | self
|
835 - | }
|
836 - | /// <p>The time when the <code>BlockToken</code> expires.</p>
|
837 - | pub fn expiry_time(
|
839 + | /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
|
840 + | pub fn checksum_algorithm(
|
838 841 | mut self,
|
839 - | input: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
842 + | input: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
840 843 | ) -> Self {
|
841 - | self.expiry_time = input;
|
842 - | self
|
843 - | }
|
844 - | /// <p>The size of the volume in GB.</p>
|
845 - | pub fn volume_size(mut self, input: ::std::option::Option<i64>) -> Self {
|
846 - | self.volume_size = input;
|
847 - | self
|
848 - | }
|
849 - | /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
|
850 - | pub fn next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
851 - | self.next_token = input;
|
844 + | self.checksum_algorithm = input;
|
852 845 | self
|
853 846 | }
|
854 - | /// <p>An array of objects containing information about the changed blocks.</p>
|
855 - | pub fn changed_blocks(
|
856 - | mut self,
|
857 - | input: ::std::option::Option<::std::vec::Vec<crate::model::ChangedBlock>>,
|
858 - | ) -> Self {
|
859 - | self.changed_blocks = input;
|
847 + | /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
|
848 + | pub fn checksum(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
849 + | self.checksum = input;
|
860 850 | self
|
861 851 | }
|
862 - | /// Consumes the builder and constructs a [`ListChangedBlocksOutput`](crate::output::ListChangedBlocksOutput).
|
863 - | pub fn build(self) -> crate::output::ListChangedBlocksOutput {
|
852 + | /// Consumes the builder and constructs a [`PutSnapshotBlockOutput`](crate::output::PutSnapshotBlockOutput).
|
853 + | pub fn build(self) -> crate::output::PutSnapshotBlockOutput {
|
864 854 | self.build_enforcing_required_and_enum_traits()
|
865 855 | }
|
866 - | fn build_enforcing_required_and_enum_traits(
|
867 - | self,
|
868 - | ) -> crate::output::ListChangedBlocksOutput {
|
869 - | crate::output::ListChangedBlocksOutput {
|
870 - | block_size: self.block_size,
|
871 - | expiry_time: self.expiry_time,
|
872 - | volume_size: self.volume_size,
|
873 - | next_token: self.next_token,
|
874 - | changed_blocks: self.changed_blocks,
|
856 + | fn build_enforcing_required_and_enum_traits(self) -> crate::output::PutSnapshotBlockOutput {
|
857 + | crate::output::PutSnapshotBlockOutput {
|
858 + | checksum_algorithm: self.checksum_algorithm,
|
859 + | checksum: self.checksum,
|
875 860 | }
|
876 861 | }
|
877 862 | }
|
878 863 | }
|
879 - | /// See [`GetSnapshotBlockOutput`](crate::output::GetSnapshotBlockOutput).
|
880 - | pub mod get_snapshot_block_output {
|
864 + | /// See [`StartSnapshotOutput`](crate::output::StartSnapshotOutput).
|
865 + | pub mod start_snapshot_output {
|
881 866 |
|
882 - | impl ::std::convert::From<Builder> for crate::output::GetSnapshotBlockOutput {
|
867 + | impl ::std::convert::From<Builder> for crate::output::StartSnapshotOutput {
|
883 868 | fn from(builder: Builder) -> Self {
|
884 869 | builder.build()
|
885 870 | }
|
886 871 | }
|
887 - | /// A builder for [`GetSnapshotBlockOutput`](crate::output::GetSnapshotBlockOutput).
|
872 + | /// A builder for [`StartSnapshotOutput`](crate::output::StartSnapshotOutput).
|
888 873 | #[derive(::std::clone::Clone, ::std::default::Default)]
|
889 874 | pub struct Builder {
|
890 - | pub(crate) data_length: ::std::option::Option<i32>,
|
891 - | pub(crate) checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
892 - | pub(crate) checksum: ::std::option::Option<::std::string::String>,
|
893 - | pub(crate) block_data:
|
894 - | ::std::option::Option<::aws_smithy_http_server_python::types::ByteStream>,
|
875 + | pub(crate) tags: ::std::option::Option<::std::vec::Vec<crate::model::Tag>>,
|
876 + | pub(crate) kms_key_arn: ::std::option::Option<::std::string::String>,
|
877 + | pub(crate) owner_id: ::std::option::Option<::std::string::String>,
|
878 + | pub(crate) volume_size: ::std::option::Option<i64>,
|
879 + | pub(crate) parent_snapshot_id: ::std::option::Option<::std::string::String>,
|
880 + | pub(crate) description: ::std::option::Option<::std::string::String>,
|
881 + | pub(crate) snapshot_id: ::std::option::Option<::std::string::String>,
|
882 + | pub(crate) block_size: ::std::option::Option<i32>,
|
883 + | pub(crate) start_time:
|
884 + | ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
885 + | pub(crate) status: ::std::option::Option<crate::model::Status>,
|
895 886 | }
|
896 887 | impl Builder {
|
897 - | /// <p>The size of the data in the block.</p>
|
898 - | pub fn data_length(mut self, input: ::std::option::Option<i32>) -> Self {
|
899 - | self.data_length = input;
|
900 - | self
|
901 - | }
|
902 - | /// <p>The algorithm used to generate the checksum for the block, such as SHA256.</p>
|
903 - | pub fn checksum_algorithm(
|
888 + | /// <p>The tags applied to the snapshot. You can specify up to 50 tags per snapshot. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html"> Tagging your Amazon EC2 resources</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
|
889 + | pub fn tags(
|
904 890 | mut self,
|
905 - | input: ::std::option::Option<crate::model::ChecksumAlgorithm>,
|
891 + | input: ::std::option::Option<::std::vec::Vec<crate::model::Tag>>,
|
906 892 | ) -> Self {
|
907 - | self.checksum_algorithm = input;
|
893 + | self.tags = input;
|
908 894 | self
|
909 895 | }
|
910 - | /// <p>The checksum generated for the block, which is Base64 encoded.</p>
|
911 - | pub fn checksum(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
912 - | self.checksum = input;
|
896 + | /// <p>The Amazon Resource Name (ARN) of the AWS Key Management Service (AWS KMS) customer master key (CMK) used to encrypt the snapshot.</p>
|
897 + | pub fn kms_key_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
898 + | self.kms_key_arn = input;
|
913 899 | self
|
914 900 | }
|
915 - | /// <p>The data content of the block.</p>
|
916 - | pub fn block_data(
|
917 - | mut self,
|
918 - | input: ::aws_smithy_http_server_python::types::ByteStream,
|
919 - | ) -> Self {
|
920 - | self.block_data = Some(input);
|
901 + | /// <p>The AWS account ID of the snapshot owner.</p>
|
902 + | pub fn owner_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
903 + | self.owner_id = input;
|
921 904 | self
|
922 905 | }
|
923 - | /// Consumes the builder and constructs a [`GetSnapshotBlockOutput`](crate::output::GetSnapshotBlockOutput).
|
924 - | pub fn build(self) -> crate::output::GetSnapshotBlockOutput {
|
925 - | self.build_enforcing_required_and_enum_traits()
|
926 - | }
|
927 - | fn build_enforcing_required_and_enum_traits(self) -> crate::output::GetSnapshotBlockOutput {
|
928 - | crate::output::GetSnapshotBlockOutput {
|
929 - | data_length: self.data_length,
|
930 - | checksum_algorithm: self.checksum_algorithm,
|
931 - | checksum: self.checksum,
|
932 - | block_data: self.block_data.unwrap_or_default(),
|
906 + | /// <p>The size of the volume, in GiB.</p>
|
907 + | pub fn volume_size(mut self, input: ::std::option::Option<i64>) -> Self {
|
908 + | self.volume_size = input;
|
909 + | self
|
933 910 | }
|
911 + | /// <p>The ID of the parent snapshot.</p>
|
912 + | pub fn parent_snapshot_id(
|
913 + | mut self,
|
914 + | input: ::std::option::Option<::std::string::String>,
|
915 + | ) -> Self {
|
916 + | self.parent_snapshot_id = input;
|
917 + | self
|
934 918 | }
|
919 + | /// <p>The description of the snapshot.</p>
|
920 + | pub fn description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
921 + | self.description = input;
|
922 + | self
|
935 923 | }
|
936 - | }
|
937 - | /// See [`CompleteSnapshotOutput`](crate::output::CompleteSnapshotOutput).
|
938 - | pub mod complete_snapshot_output {
|
939 - |
|
940 - | impl ::std::convert::From<Builder> for crate::output::CompleteSnapshotOutput {
|
941 - | fn from(builder: Builder) -> Self {
|
942 - | builder.build()
|
924 + | /// <p>The ID of the snapshot.</p>
|
925 + | pub fn snapshot_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
926 + | self.snapshot_id = input;
|
927 + | self
|
943 928 | }
|
929 + | /// <p>The size of the blocks in the snapshot, in bytes.</p>
|
930 + | pub fn block_size(mut self, input: ::std::option::Option<i32>) -> Self {
|
931 + | self.block_size = input;
|
932 + | self
|
944 933 | }
|
945 - | /// A builder for [`CompleteSnapshotOutput`](crate::output::CompleteSnapshotOutput).
|
946 - | #[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
|
947 - | pub struct Builder {
|
948 - | pub(crate) status: ::std::option::Option<crate::model::Status>,
|
934 + | /// <p>The timestamp when the snapshot was created.</p>
|
935 + | pub fn start_time(
|
936 + | mut self,
|
937 + | input: ::std::option::Option<::aws_smithy_http_server_python::types::DateTime>,
|
938 + | ) -> Self {
|
939 + | self.start_time = input;
|
940 + | self
|
949 941 | }
|
950 - | impl Builder {
|
951 942 | /// <p>The status of the snapshot.</p>
|
952 943 | pub fn status(mut self, input: ::std::option::Option<crate::model::Status>) -> Self {
|
953 944 | self.status = input;
|
954 945 | self
|
955 946 | }
|
956 - | /// Consumes the builder and constructs a [`CompleteSnapshotOutput`](crate::output::CompleteSnapshotOutput).
|
957 - | pub fn build(self) -> crate::output::CompleteSnapshotOutput {
|
947 + | /// Consumes the builder and constructs a [`StartSnapshotOutput`](crate::output::StartSnapshotOutput).
|
948 + | pub fn build(self) -> crate::output::StartSnapshotOutput {
|
958 949 | self.build_enforcing_required_and_enum_traits()
|
959 950 | }
|
960 - | fn build_enforcing_required_and_enum_traits(self) -> crate::output::CompleteSnapshotOutput {
|
961 - | crate::output::CompleteSnapshotOutput {
|
951 + | fn build_enforcing_required_and_enum_traits(self) -> crate::output::StartSnapshotOutput {
|
952 + | crate::output::StartSnapshotOutput {
|
953 + | tags: self.tags,
|
954 + | kms_key_arn: self.kms_key_arn,
|
955 + | owner_id: self.owner_id,
|
956 + | volume_size: self.volume_size,
|
957 + | parent_snapshot_id: self.parent_snapshot_id,
|
958 + | description: self.description,
|
959 + | snapshot_id: self.snapshot_id,
|
960 + | block_size: self.block_size,
|
961 + | start_time: self.start_time,
|
962 962 | status: self.status,
|
963 963 | }
|
964 964 | }
|
965 965 | }
|
966 966 | }
|