1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// <p>The <code>Status</code> and <code>TrackingNumber</code> information for an inbound or outbound shipment.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct Shipment {
/// <p>Status information for a shipment.</p>
pub status: ::std::option::Option<::std::string::String>,
/// <p>The tracking number for this job. Using this tracking number with your region's carrier's website, you can track a Snow device as the carrier transports it.</p>
/// <p>For India, the carrier is Amazon Logistics. For all other regions, UPS is the carrier.</p>
pub tracking_number: ::std::option::Option<::std::string::String>,
}
impl Shipment {
/// <p>Status information for a shipment.</p>
pub fn status(&self) -> ::std::option::Option<&str> {
self.status.as_deref()
}
/// <p>The tracking number for this job. Using this tracking number with your region's carrier's website, you can track a Snow device as the carrier transports it.</p>
/// <p>For India, the carrier is Amazon Logistics. For all other regions, UPS is the carrier.</p>
pub fn tracking_number(&self) -> ::std::option::Option<&str> {
self.tracking_number.as_deref()
}
}
impl Shipment {
/// Creates a new builder-style object to manufacture [`Shipment`](crate::types::Shipment).
pub fn builder() -> crate::types::builders::ShipmentBuilder {
crate::types::builders::ShipmentBuilder::default()
}
}
/// A builder for [`Shipment`](crate::types::Shipment).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct ShipmentBuilder {
pub(crate) status: ::std::option::Option<::std::string::String>,
pub(crate) tracking_number: ::std::option::Option<::std::string::String>,
}
impl ShipmentBuilder {
/// <p>Status information for a shipment.</p>
pub fn status(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.status = ::std::option::Option::Some(input.into());
self
}
/// <p>Status information for a shipment.</p>
pub fn set_status(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.status = input;
self
}
/// <p>Status information for a shipment.</p>
pub fn get_status(&self) -> &::std::option::Option<::std::string::String> {
&self.status
}
/// <p>The tracking number for this job. Using this tracking number with your region's carrier's website, you can track a Snow device as the carrier transports it.</p>
/// <p>For India, the carrier is Amazon Logistics. For all other regions, UPS is the carrier.</p>
pub fn tracking_number(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.tracking_number = ::std::option::Option::Some(input.into());
self
}
/// <p>The tracking number for this job. Using this tracking number with your region's carrier's website, you can track a Snow device as the carrier transports it.</p>
/// <p>For India, the carrier is Amazon Logistics. For all other regions, UPS is the carrier.</p>
pub fn set_tracking_number(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.tracking_number = input;
self
}
/// <p>The tracking number for this job. Using this tracking number with your region's carrier's website, you can track a Snow device as the carrier transports it.</p>
/// <p>For India, the carrier is Amazon Logistics. For all other regions, UPS is the carrier.</p>
pub fn get_tracking_number(&self) -> &::std::option::Option<::std::string::String> {
&self.tracking_number
}
/// Consumes the builder and constructs a [`Shipment`](crate::types::Shipment).
pub fn build(self) -> crate::types::Shipment {
crate::types::Shipment {
status: self.status,
tracking_number: self.tracking_number,
}
}
}