amazon_spapi/models/services/date_time_range.rs
1/*
2 * Selling Partner API for Services
3 *
4 * With the Services API, you can build applications that help service providers get and modify their service orders and manage their resources.
5 *
6 * The version of the OpenAPI document: v1
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// DateTimeRange : A range of time.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct DateTimeRange {
17 /// The beginning of the time range. Must be in UTC in [ISO 8601](https://developer-docs.amazon.com/sp-api/docs/iso-8601) format.
18 #[serde(rename = "startTime")]
19 pub start_time: String,
20 /// The end of the time range. Must be in UTC in [ISO 8601](https://developer-docs.amazon.com/sp-api/docs/iso-8601) format.
21 #[serde(rename = "endTime")]
22 pub end_time: String,
23}
24
25impl DateTimeRange {
26 /// A range of time.
27 pub fn new(start_time: String, end_time: String) -> DateTimeRange {
28 DateTimeRange {
29 start_time,
30 end_time,
31 }
32 }
33}
34