aws_sdk_mgn/operation/start_replication/
_start_replication_output.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq)]
5pub struct StartReplicationOutput {
6    /// <p>Source server ID.</p>
7    pub source_server_id: ::std::option::Option<::std::string::String>,
8    /// <p>Source server ARN.</p>
9    pub arn: ::std::option::Option<::std::string::String>,
10    /// <p>Source server archived status.</p>
11    pub is_archived: ::std::option::Option<bool>,
12    /// <p>Source server Tags.</p>
13    pub tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
14    /// <p>Source server launched instance.</p>
15    pub launched_instance: ::std::option::Option<crate::types::LaunchedInstance>,
16    /// <p>Source server data replication info.</p>
17    pub data_replication_info: ::std::option::Option<crate::types::DataReplicationInfo>,
18    /// <p>Source server lifecycle state.</p>
19    pub life_cycle: ::std::option::Option<crate::types::LifeCycle>,
20    /// <p>Source server properties.</p>
21    pub source_properties: ::std::option::Option<crate::types::SourceProperties>,
22    /// <p>Source server replication type.</p>
23    pub replication_type: ::std::option::Option<crate::types::ReplicationType>,
24    /// <p>Source server vCenter client id.</p>
25    pub vcenter_client_id: ::std::option::Option<::std::string::String>,
26    /// <p>Source server application ID.</p>
27    pub application_id: ::std::option::Option<::std::string::String>,
28    /// <p>Source server user provided ID.</p>
29    pub user_provided_id: ::std::option::Option<::std::string::String>,
30    /// <p>Source server fqdn for action framework.</p>
31    pub fqdn_for_action_framework: ::std::option::Option<::std::string::String>,
32    /// <p>Source Server connector action.</p>
33    pub connector_action: ::std::option::Option<crate::types::SourceServerConnectorAction>,
34    _request_id: Option<String>,
35}
36impl StartReplicationOutput {
37    /// <p>Source server ID.</p>
38    pub fn source_server_id(&self) -> ::std::option::Option<&str> {
39        self.source_server_id.as_deref()
40    }
41    /// <p>Source server ARN.</p>
42    pub fn arn(&self) -> ::std::option::Option<&str> {
43        self.arn.as_deref()
44    }
45    /// <p>Source server archived status.</p>
46    pub fn is_archived(&self) -> ::std::option::Option<bool> {
47        self.is_archived
48    }
49    /// <p>Source server Tags.</p>
50    pub fn tags(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
51        self.tags.as_ref()
52    }
53    /// <p>Source server launched instance.</p>
54    pub fn launched_instance(&self) -> ::std::option::Option<&crate::types::LaunchedInstance> {
55        self.launched_instance.as_ref()
56    }
57    /// <p>Source server data replication info.</p>
58    pub fn data_replication_info(&self) -> ::std::option::Option<&crate::types::DataReplicationInfo> {
59        self.data_replication_info.as_ref()
60    }
61    /// <p>Source server lifecycle state.</p>
62    pub fn life_cycle(&self) -> ::std::option::Option<&crate::types::LifeCycle> {
63        self.life_cycle.as_ref()
64    }
65    /// <p>Source server properties.</p>
66    pub fn source_properties(&self) -> ::std::option::Option<&crate::types::SourceProperties> {
67        self.source_properties.as_ref()
68    }
69    /// <p>Source server replication type.</p>
70    pub fn replication_type(&self) -> ::std::option::Option<&crate::types::ReplicationType> {
71        self.replication_type.as_ref()
72    }
73    /// <p>Source server vCenter client id.</p>
74    pub fn vcenter_client_id(&self) -> ::std::option::Option<&str> {
75        self.vcenter_client_id.as_deref()
76    }
77    /// <p>Source server application ID.</p>
78    pub fn application_id(&self) -> ::std::option::Option<&str> {
79        self.application_id.as_deref()
80    }
81    /// <p>Source server user provided ID.</p>
82    pub fn user_provided_id(&self) -> ::std::option::Option<&str> {
83        self.user_provided_id.as_deref()
84    }
85    /// <p>Source server fqdn for action framework.</p>
86    pub fn fqdn_for_action_framework(&self) -> ::std::option::Option<&str> {
87        self.fqdn_for_action_framework.as_deref()
88    }
89    /// <p>Source Server connector action.</p>
90    pub fn connector_action(&self) -> ::std::option::Option<&crate::types::SourceServerConnectorAction> {
91        self.connector_action.as_ref()
92    }
93}
94impl ::std::fmt::Debug for StartReplicationOutput {
95    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
96        let mut formatter = f.debug_struct("StartReplicationOutput");
97        formatter.field("source_server_id", &self.source_server_id);
98        formatter.field("arn", &self.arn);
99        formatter.field("is_archived", &self.is_archived);
100        formatter.field("tags", &"*** Sensitive Data Redacted ***");
101        formatter.field("launched_instance", &self.launched_instance);
102        formatter.field("data_replication_info", &self.data_replication_info);
103        formatter.field("life_cycle", &self.life_cycle);
104        formatter.field("source_properties", &self.source_properties);
105        formatter.field("replication_type", &self.replication_type);
106        formatter.field("vcenter_client_id", &self.vcenter_client_id);
107        formatter.field("application_id", &self.application_id);
108        formatter.field("user_provided_id", &self.user_provided_id);
109        formatter.field("fqdn_for_action_framework", &self.fqdn_for_action_framework);
110        formatter.field("connector_action", &self.connector_action);
111        formatter.field("_request_id", &self._request_id);
112        formatter.finish()
113    }
114}
115impl ::aws_types::request_id::RequestId for StartReplicationOutput {
116    fn request_id(&self) -> Option<&str> {
117        self._request_id.as_deref()
118    }
119}
120impl StartReplicationOutput {
121    /// Creates a new builder-style object to manufacture [`StartReplicationOutput`](crate::operation::start_replication::StartReplicationOutput).
122    pub fn builder() -> crate::operation::start_replication::builders::StartReplicationOutputBuilder {
123        crate::operation::start_replication::builders::StartReplicationOutputBuilder::default()
124    }
125}
126
127/// A builder for [`StartReplicationOutput`](crate::operation::start_replication::StartReplicationOutput).
128#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
129#[non_exhaustive]
130pub struct StartReplicationOutputBuilder {
131    pub(crate) source_server_id: ::std::option::Option<::std::string::String>,
132    pub(crate) arn: ::std::option::Option<::std::string::String>,
133    pub(crate) is_archived: ::std::option::Option<bool>,
134    pub(crate) tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
135    pub(crate) launched_instance: ::std::option::Option<crate::types::LaunchedInstance>,
136    pub(crate) data_replication_info: ::std::option::Option<crate::types::DataReplicationInfo>,
137    pub(crate) life_cycle: ::std::option::Option<crate::types::LifeCycle>,
138    pub(crate) source_properties: ::std::option::Option<crate::types::SourceProperties>,
139    pub(crate) replication_type: ::std::option::Option<crate::types::ReplicationType>,
140    pub(crate) vcenter_client_id: ::std::option::Option<::std::string::String>,
141    pub(crate) application_id: ::std::option::Option<::std::string::String>,
142    pub(crate) user_provided_id: ::std::option::Option<::std::string::String>,
143    pub(crate) fqdn_for_action_framework: ::std::option::Option<::std::string::String>,
144    pub(crate) connector_action: ::std::option::Option<crate::types::SourceServerConnectorAction>,
145    _request_id: Option<String>,
146}
147impl StartReplicationOutputBuilder {
148    /// <p>Source server ID.</p>
149    pub fn source_server_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
150        self.source_server_id = ::std::option::Option::Some(input.into());
151        self
152    }
153    /// <p>Source server ID.</p>
154    pub fn set_source_server_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
155        self.source_server_id = input;
156        self
157    }
158    /// <p>Source server ID.</p>
159    pub fn get_source_server_id(&self) -> &::std::option::Option<::std::string::String> {
160        &self.source_server_id
161    }
162    /// <p>Source server ARN.</p>
163    pub fn arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
164        self.arn = ::std::option::Option::Some(input.into());
165        self
166    }
167    /// <p>Source server ARN.</p>
168    pub fn set_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
169        self.arn = input;
170        self
171    }
172    /// <p>Source server ARN.</p>
173    pub fn get_arn(&self) -> &::std::option::Option<::std::string::String> {
174        &self.arn
175    }
176    /// <p>Source server archived status.</p>
177    pub fn is_archived(mut self, input: bool) -> Self {
178        self.is_archived = ::std::option::Option::Some(input);
179        self
180    }
181    /// <p>Source server archived status.</p>
182    pub fn set_is_archived(mut self, input: ::std::option::Option<bool>) -> Self {
183        self.is_archived = input;
184        self
185    }
186    /// <p>Source server archived status.</p>
187    pub fn get_is_archived(&self) -> &::std::option::Option<bool> {
188        &self.is_archived
189    }
190    /// Adds a key-value pair to `tags`.
191    ///
192    /// To override the contents of this collection use [`set_tags`](Self::set_tags).
193    ///
194    /// <p>Source server Tags.</p>
195    pub fn tags(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
196        let mut hash_map = self.tags.unwrap_or_default();
197        hash_map.insert(k.into(), v.into());
198        self.tags = ::std::option::Option::Some(hash_map);
199        self
200    }
201    /// <p>Source server Tags.</p>
202    pub fn set_tags(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
203        self.tags = input;
204        self
205    }
206    /// <p>Source server Tags.</p>
207    pub fn get_tags(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
208        &self.tags
209    }
210    /// <p>Source server launched instance.</p>
211    pub fn launched_instance(mut self, input: crate::types::LaunchedInstance) -> Self {
212        self.launched_instance = ::std::option::Option::Some(input);
213        self
214    }
215    /// <p>Source server launched instance.</p>
216    pub fn set_launched_instance(mut self, input: ::std::option::Option<crate::types::LaunchedInstance>) -> Self {
217        self.launched_instance = input;
218        self
219    }
220    /// <p>Source server launched instance.</p>
221    pub fn get_launched_instance(&self) -> &::std::option::Option<crate::types::LaunchedInstance> {
222        &self.launched_instance
223    }
224    /// <p>Source server data replication info.</p>
225    pub fn data_replication_info(mut self, input: crate::types::DataReplicationInfo) -> Self {
226        self.data_replication_info = ::std::option::Option::Some(input);
227        self
228    }
229    /// <p>Source server data replication info.</p>
230    pub fn set_data_replication_info(mut self, input: ::std::option::Option<crate::types::DataReplicationInfo>) -> Self {
231        self.data_replication_info = input;
232        self
233    }
234    /// <p>Source server data replication info.</p>
235    pub fn get_data_replication_info(&self) -> &::std::option::Option<crate::types::DataReplicationInfo> {
236        &self.data_replication_info
237    }
238    /// <p>Source server lifecycle state.</p>
239    pub fn life_cycle(mut self, input: crate::types::LifeCycle) -> Self {
240        self.life_cycle = ::std::option::Option::Some(input);
241        self
242    }
243    /// <p>Source server lifecycle state.</p>
244    pub fn set_life_cycle(mut self, input: ::std::option::Option<crate::types::LifeCycle>) -> Self {
245        self.life_cycle = input;
246        self
247    }
248    /// <p>Source server lifecycle state.</p>
249    pub fn get_life_cycle(&self) -> &::std::option::Option<crate::types::LifeCycle> {
250        &self.life_cycle
251    }
252    /// <p>Source server properties.</p>
253    pub fn source_properties(mut self, input: crate::types::SourceProperties) -> Self {
254        self.source_properties = ::std::option::Option::Some(input);
255        self
256    }
257    /// <p>Source server properties.</p>
258    pub fn set_source_properties(mut self, input: ::std::option::Option<crate::types::SourceProperties>) -> Self {
259        self.source_properties = input;
260        self
261    }
262    /// <p>Source server properties.</p>
263    pub fn get_source_properties(&self) -> &::std::option::Option<crate::types::SourceProperties> {
264        &self.source_properties
265    }
266    /// <p>Source server replication type.</p>
267    pub fn replication_type(mut self, input: crate::types::ReplicationType) -> Self {
268        self.replication_type = ::std::option::Option::Some(input);
269        self
270    }
271    /// <p>Source server replication type.</p>
272    pub fn set_replication_type(mut self, input: ::std::option::Option<crate::types::ReplicationType>) -> Self {
273        self.replication_type = input;
274        self
275    }
276    /// <p>Source server replication type.</p>
277    pub fn get_replication_type(&self) -> &::std::option::Option<crate::types::ReplicationType> {
278        &self.replication_type
279    }
280    /// <p>Source server vCenter client id.</p>
281    pub fn vcenter_client_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
282        self.vcenter_client_id = ::std::option::Option::Some(input.into());
283        self
284    }
285    /// <p>Source server vCenter client id.</p>
286    pub fn set_vcenter_client_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
287        self.vcenter_client_id = input;
288        self
289    }
290    /// <p>Source server vCenter client id.</p>
291    pub fn get_vcenter_client_id(&self) -> &::std::option::Option<::std::string::String> {
292        &self.vcenter_client_id
293    }
294    /// <p>Source server application ID.</p>
295    pub fn application_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
296        self.application_id = ::std::option::Option::Some(input.into());
297        self
298    }
299    /// <p>Source server application ID.</p>
300    pub fn set_application_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
301        self.application_id = input;
302        self
303    }
304    /// <p>Source server application ID.</p>
305    pub fn get_application_id(&self) -> &::std::option::Option<::std::string::String> {
306        &self.application_id
307    }
308    /// <p>Source server user provided ID.</p>
309    pub fn user_provided_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
310        self.user_provided_id = ::std::option::Option::Some(input.into());
311        self
312    }
313    /// <p>Source server user provided ID.</p>
314    pub fn set_user_provided_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
315        self.user_provided_id = input;
316        self
317    }
318    /// <p>Source server user provided ID.</p>
319    pub fn get_user_provided_id(&self) -> &::std::option::Option<::std::string::String> {
320        &self.user_provided_id
321    }
322    /// <p>Source server fqdn for action framework.</p>
323    pub fn fqdn_for_action_framework(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
324        self.fqdn_for_action_framework = ::std::option::Option::Some(input.into());
325        self
326    }
327    /// <p>Source server fqdn for action framework.</p>
328    pub fn set_fqdn_for_action_framework(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
329        self.fqdn_for_action_framework = input;
330        self
331    }
332    /// <p>Source server fqdn for action framework.</p>
333    pub fn get_fqdn_for_action_framework(&self) -> &::std::option::Option<::std::string::String> {
334        &self.fqdn_for_action_framework
335    }
336    /// <p>Source Server connector action.</p>
337    pub fn connector_action(mut self, input: crate::types::SourceServerConnectorAction) -> Self {
338        self.connector_action = ::std::option::Option::Some(input);
339        self
340    }
341    /// <p>Source Server connector action.</p>
342    pub fn set_connector_action(mut self, input: ::std::option::Option<crate::types::SourceServerConnectorAction>) -> Self {
343        self.connector_action = input;
344        self
345    }
346    /// <p>Source Server connector action.</p>
347    pub fn get_connector_action(&self) -> &::std::option::Option<crate::types::SourceServerConnectorAction> {
348        &self.connector_action
349    }
350    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
351        self._request_id = Some(request_id.into());
352        self
353    }
354
355    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
356        self._request_id = request_id;
357        self
358    }
359    /// Consumes the builder and constructs a [`StartReplicationOutput`](crate::operation::start_replication::StartReplicationOutput).
360    pub fn build(self) -> crate::operation::start_replication::StartReplicationOutput {
361        crate::operation::start_replication::StartReplicationOutput {
362            source_server_id: self.source_server_id,
363            arn: self.arn,
364            is_archived: self.is_archived,
365            tags: self.tags,
366            launched_instance: self.launched_instance,
367            data_replication_info: self.data_replication_info,
368            life_cycle: self.life_cycle,
369            source_properties: self.source_properties,
370            replication_type: self.replication_type,
371            vcenter_client_id: self.vcenter_client_id,
372            application_id: self.application_id,
373            user_provided_id: self.user_provided_id,
374            fqdn_for_action_framework: self.fqdn_for_action_framework,
375            connector_action: self.connector_action,
376            _request_id: self._request_id,
377        }
378    }
379}
380impl ::std::fmt::Debug for StartReplicationOutputBuilder {
381    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
382        let mut formatter = f.debug_struct("StartReplicationOutputBuilder");
383        formatter.field("source_server_id", &self.source_server_id);
384        formatter.field("arn", &self.arn);
385        formatter.field("is_archived", &self.is_archived);
386        formatter.field("tags", &"*** Sensitive Data Redacted ***");
387        formatter.field("launched_instance", &self.launched_instance);
388        formatter.field("data_replication_info", &self.data_replication_info);
389        formatter.field("life_cycle", &self.life_cycle);
390        formatter.field("source_properties", &self.source_properties);
391        formatter.field("replication_type", &self.replication_type);
392        formatter.field("vcenter_client_id", &self.vcenter_client_id);
393        formatter.field("application_id", &self.application_id);
394        formatter.field("user_provided_id", &self.user_provided_id);
395        formatter.field("fqdn_for_action_framework", &self.fqdn_for_action_framework);
396        formatter.field("connector_action", &self.connector_action);
397        formatter.field("_request_id", &self._request_id);
398        formatter.finish()
399    }
400}