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
use serde::{Deserialize, Serialize}; /*
* Cloud DNS API
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: v1
*
* Generated by: https://openapi-generator.tech
*/
use crate::google_rest_apis::dns_v1::models;
/// Change : A Change represents a set of ResourceRecordSet additions and deletions applied atomically to a ManagedZone. ResourceRecordSets within a ManagedZone are modified by creating a new Change element in the Changes collection. In turn the Changes collection also records the past modifications to the ResourceRecordSets in a ManagedZone. The current state of the ManagedZone is the sum effect of applying all Change elements in the Changes collection in sequence.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct Change {
/// Which ResourceRecordSets to add?
#[serde(rename = "additions", skip_serializing_if = "Option::is_none")]
pub additions: Option<Vec<models::ResourceRecordSet>>,
/// Which ResourceRecordSets to remove? Must match existing data exactly.
#[serde(rename = "deletions", skip_serializing_if = "Option::is_none")]
pub deletions: Option<Vec<models::ResourceRecordSet>>,
/// Unique identifier for the resource; defined by the server (output only).
#[serde(rename = "id", skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// If the DNS queries for the zone will be served.
#[serde(rename = "isServing", skip_serializing_if = "Option::is_none")]
pub is_serving: Option<bool>,
#[serde(rename = "kind", skip_serializing_if = "Option::is_none")]
pub kind: Option<String>,
/// The time that this operation was started by the server (output only). This is in RFC3339 text format.
#[serde(rename = "startTime", skip_serializing_if = "Option::is_none")]
pub start_time: Option<String>,
/// Status of the operation (output only). A status of \"done\" means that the request to update the authoritative servers has been sent, but the servers might not be updated yet.
#[serde(rename = "status", skip_serializing_if = "Option::is_none")]
pub status: Option<Status>,
}
impl Change {
/// A Change represents a set of ResourceRecordSet additions and deletions applied atomically to a ManagedZone. ResourceRecordSets within a ManagedZone are modified by creating a new Change element in the Changes collection. In turn the Changes collection also records the past modifications to the ResourceRecordSets in a ManagedZone. The current state of the ManagedZone is the sum effect of applying all Change elements in the Changes collection in sequence.
pub fn new() -> Change {
Change {
additions: None,
deletions: None,
id: None,
is_serving: None,
kind: None,
start_time: None,
status: None,
}
}
}
/// Status of the operation (output only). A status of \"done\" means that the request to update the authoritative servers has been sent, but the servers might not be updated yet.
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Status {
#[serde(rename = "pending")]
Pending,
#[serde(rename = "done")]
Done,
}
impl Default for Status {
fn default() -> Status {
Self::Pending
}
}