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
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p>Includes encryption-related information, such as the AWS KMS key used for encrypting data at rest and whether you want MSK to encrypt your data in transit.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct EncryptionInfo {
    /// <p>The data-volume encryption details.</p>
    pub encryption_at_rest: ::std::option::Option<crate::types::EncryptionAtRest>,
    /// <p>The details for encryption in transit.</p>
    pub encryption_in_transit: ::std::option::Option<crate::types::EncryptionInTransit>,
}
impl EncryptionInfo {
    /// <p>The data-volume encryption details.</p>
    pub fn encryption_at_rest(&self) -> ::std::option::Option<&crate::types::EncryptionAtRest> {
        self.encryption_at_rest.as_ref()
    }
    /// <p>The details for encryption in transit.</p>
    pub fn encryption_in_transit(&self) -> ::std::option::Option<&crate::types::EncryptionInTransit> {
        self.encryption_in_transit.as_ref()
    }
}
impl EncryptionInfo {
    /// Creates a new builder-style object to manufacture [`EncryptionInfo`](crate::types::EncryptionInfo).
    pub fn builder() -> crate::types::builders::EncryptionInfoBuilder {
        crate::types::builders::EncryptionInfoBuilder::default()
    }
}

/// A builder for [`EncryptionInfo`](crate::types::EncryptionInfo).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct EncryptionInfoBuilder {
    pub(crate) encryption_at_rest: ::std::option::Option<crate::types::EncryptionAtRest>,
    pub(crate) encryption_in_transit: ::std::option::Option<crate::types::EncryptionInTransit>,
}
impl EncryptionInfoBuilder {
    /// <p>The data-volume encryption details.</p>
    pub fn encryption_at_rest(mut self, input: crate::types::EncryptionAtRest) -> Self {
        self.encryption_at_rest = ::std::option::Option::Some(input);
        self
    }
    /// <p>The data-volume encryption details.</p>
    pub fn set_encryption_at_rest(mut self, input: ::std::option::Option<crate::types::EncryptionAtRest>) -> Self {
        self.encryption_at_rest = input;
        self
    }
    /// <p>The data-volume encryption details.</p>
    pub fn get_encryption_at_rest(&self) -> &::std::option::Option<crate::types::EncryptionAtRest> {
        &self.encryption_at_rest
    }
    /// <p>The details for encryption in transit.</p>
    pub fn encryption_in_transit(mut self, input: crate::types::EncryptionInTransit) -> Self {
        self.encryption_in_transit = ::std::option::Option::Some(input);
        self
    }
    /// <p>The details for encryption in transit.</p>
    pub fn set_encryption_in_transit(mut self, input: ::std::option::Option<crate::types::EncryptionInTransit>) -> Self {
        self.encryption_in_transit = input;
        self
    }
    /// <p>The details for encryption in transit.</p>
    pub fn get_encryption_in_transit(&self) -> &::std::option::Option<crate::types::EncryptionInTransit> {
        &self.encryption_in_transit
    }
    /// Consumes the builder and constructs a [`EncryptionInfo`](crate::types::EncryptionInfo).
    pub fn build(self) -> crate::types::EncryptionInfo {
        crate::types::EncryptionInfo {
            encryption_at_rest: self.encryption_at_rest,
            encryption_in_transit: self.encryption_in_transit,
        }
    }
}