aws_sdk_cloudwatchlogs/operation/put_integration/
_put_integration_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, ::std::fmt::Debug)]
5pub struct PutIntegrationOutput {
6    /// <p>The name of the integration that you just created.</p>
7    pub integration_name: ::std::option::Option<::std::string::String>,
8    /// <p>The status of the integration that you just created.</p>
9    /// <p>After you create an integration, it takes a few minutes to complete. During this time, you'll see the status as <code>PROVISIONING</code>.</p>
10    pub integration_status: ::std::option::Option<crate::types::IntegrationStatus>,
11    _request_id: Option<String>,
12}
13impl PutIntegrationOutput {
14    /// <p>The name of the integration that you just created.</p>
15    pub fn integration_name(&self) -> ::std::option::Option<&str> {
16        self.integration_name.as_deref()
17    }
18    /// <p>The status of the integration that you just created.</p>
19    /// <p>After you create an integration, it takes a few minutes to complete. During this time, you'll see the status as <code>PROVISIONING</code>.</p>
20    pub fn integration_status(&self) -> ::std::option::Option<&crate::types::IntegrationStatus> {
21        self.integration_status.as_ref()
22    }
23}
24impl ::aws_types::request_id::RequestId for PutIntegrationOutput {
25    fn request_id(&self) -> Option<&str> {
26        self._request_id.as_deref()
27    }
28}
29impl PutIntegrationOutput {
30    /// Creates a new builder-style object to manufacture [`PutIntegrationOutput`](crate::operation::put_integration::PutIntegrationOutput).
31    pub fn builder() -> crate::operation::put_integration::builders::PutIntegrationOutputBuilder {
32        crate::operation::put_integration::builders::PutIntegrationOutputBuilder::default()
33    }
34}
35
36/// A builder for [`PutIntegrationOutput`](crate::operation::put_integration::PutIntegrationOutput).
37#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
38#[non_exhaustive]
39pub struct PutIntegrationOutputBuilder {
40    pub(crate) integration_name: ::std::option::Option<::std::string::String>,
41    pub(crate) integration_status: ::std::option::Option<crate::types::IntegrationStatus>,
42    _request_id: Option<String>,
43}
44impl PutIntegrationOutputBuilder {
45    /// <p>The name of the integration that you just created.</p>
46    pub fn integration_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
47        self.integration_name = ::std::option::Option::Some(input.into());
48        self
49    }
50    /// <p>The name of the integration that you just created.</p>
51    pub fn set_integration_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
52        self.integration_name = input;
53        self
54    }
55    /// <p>The name of the integration that you just created.</p>
56    pub fn get_integration_name(&self) -> &::std::option::Option<::std::string::String> {
57        &self.integration_name
58    }
59    /// <p>The status of the integration that you just created.</p>
60    /// <p>After you create an integration, it takes a few minutes to complete. During this time, you'll see the status as <code>PROVISIONING</code>.</p>
61    pub fn integration_status(mut self, input: crate::types::IntegrationStatus) -> Self {
62        self.integration_status = ::std::option::Option::Some(input);
63        self
64    }
65    /// <p>The status of the integration that you just created.</p>
66    /// <p>After you create an integration, it takes a few minutes to complete. During this time, you'll see the status as <code>PROVISIONING</code>.</p>
67    pub fn set_integration_status(mut self, input: ::std::option::Option<crate::types::IntegrationStatus>) -> Self {
68        self.integration_status = input;
69        self
70    }
71    /// <p>The status of the integration that you just created.</p>
72    /// <p>After you create an integration, it takes a few minutes to complete. During this time, you'll see the status as <code>PROVISIONING</code>.</p>
73    pub fn get_integration_status(&self) -> &::std::option::Option<crate::types::IntegrationStatus> {
74        &self.integration_status
75    }
76    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
77        self._request_id = Some(request_id.into());
78        self
79    }
80
81    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
82        self._request_id = request_id;
83        self
84    }
85    /// Consumes the builder and constructs a [`PutIntegrationOutput`](crate::operation::put_integration::PutIntegrationOutput).
86    pub fn build(self) -> crate::operation::put_integration::PutIntegrationOutput {
87        crate::operation::put_integration::PutIntegrationOutput {
88            integration_name: self.integration_name,
89            integration_status: self.integration_status,
90            _request_id: self._request_id,
91        }
92    }
93}