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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
use serde::{Deserialize, Serialize};
#[allow(unused_imports)]
use super::*;
/// The set of changes to make to the state of the modules, streams, and profiles on a managed instance
#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct ManageModuleStreamsOnManagedInstanceDetails {
/// Indicates if this operation is a dry run or if the operation should be committed. If set to true, the result of the operation will be evaluated but not committed. If set to false, the operation is committed to the managed instance. The default is false.
#[serde(skip_serializing_if = "Option::is_none")]
pub is_dry_run: Option<bool>,
/// The set of module streams to enable. If any streams of a module are already enabled, the service switches from the current stream to the new stream. Once complete, the streams will be in 'ENABLED' status.
#[serde(skip_serializing_if = "Option::is_none")]
pub enable: Option<Vec<ModuleStreamDetails>>,
/// The set of module streams to disable. Any profiles that are installed for the module stream will be removed as part of the operation. Once complete, the streams will be in 'DISABLED' status.
#[serde(skip_serializing_if = "Option::is_none")]
pub disable: Option<Vec<ModuleStreamDetails>>,
/// The set of module stream profiles to install. Any packages that are part of the profile are installed on the managed instance. Once complete, the profile will be in 'INSTALLED' status. The operation will return an error if you attempt to install a profile from a disabled stream, unless enabling the new module stream is included in this operation.
#[serde(skip_serializing_if = "Option::is_none")]
pub install: Option<Vec<ModuleStreamProfileDetails>>,
/// The set of module stream profiles to remove. Once complete, the profile will be in 'AVAILABLE' status. The status of packages within the profile after the operation is complete is defined by the package manager on the managed instance group.
#[serde(skip_serializing_if = "Option::is_none")]
pub remove: Option<Vec<ModuleStreamProfileDetails>>,
#[serde(skip_serializing_if = "Option::is_none")]
pub work_request_details: Option<WorkRequestDetails>,
}
impl ManageModuleStreamsOnManagedInstanceDetails {
/// Create a new ManageModuleStreamsOnManagedInstanceDetails
pub fn new() -> Self {
Self {
is_dry_run: None,
enable: None,
disable: None,
install: None,
remove: None,
work_request_details: None,
}
}
/// Set is_dry_run
pub fn set_is_dry_run(mut self, value: Option<bool>) -> Self {
self.is_dry_run = value;
self
}
/// Set enable
pub fn set_enable(mut self, value: Option<Vec<ModuleStreamDetails>>) -> Self {
self.enable = value;
self
}
/// Set disable
pub fn set_disable(mut self, value: Option<Vec<ModuleStreamDetails>>) -> Self {
self.disable = value;
self
}
/// Set install
pub fn set_install(mut self, value: Option<Vec<ModuleStreamProfileDetails>>) -> Self {
self.install = value;
self
}
/// Set remove
pub fn set_remove(mut self, value: Option<Vec<ModuleStreamProfileDetails>>) -> Self {
self.remove = value;
self
}
/// Set work_request_details
pub fn set_work_request_details(mut self, value: Option<WorkRequestDetails>) -> Self {
self.work_request_details = value;
self
}
/// Set is_dry_run (unwraps Option)
pub fn with_is_dry_run(mut self, value: bool) -> Self {
self.is_dry_run = Some(value);
self
}
/// Set enable (unwraps Option)
pub fn with_enable(mut self, value: Vec<ModuleStreamDetails>) -> Self {
self.enable = Some(value);
self
}
/// Set disable (unwraps Option)
pub fn with_disable(mut self, value: Vec<ModuleStreamDetails>) -> Self {
self.disable = Some(value);
self
}
/// Set install (unwraps Option)
pub fn with_install(mut self, value: Vec<ModuleStreamProfileDetails>) -> Self {
self.install = Some(value);
self
}
/// Set remove (unwraps Option)
pub fn with_remove(mut self, value: Vec<ModuleStreamProfileDetails>) -> Self {
self.remove = Some(value);
self
}
/// Set work_request_details (unwraps Option)
pub fn with_work_request_details(mut self, value: WorkRequestDetails) -> Self {
self.work_request_details = Some(value);
self
}
}
impl Default for ManageModuleStreamsOnManagedInstanceDetails {
fn default() -> Self {
Self::new()
}
}