aws_sdk_wellarchitected/operation/get_lens/
_get_lens_input.rs

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
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct GetLensInput {
    /// <p>The alias of the lens.</p>
    /// <p>For Amazon Web Services official lenses, this is either the lens alias, such as <code>serverless</code>, or the lens ARN, such as <code>arn:aws:wellarchitected:us-east-1::lens/serverless</code>. Note that some operations (such as ExportLens and CreateLensShare) are not permitted on Amazon Web Services official lenses.</p>
    /// <p>For custom lenses, this is the lens ARN, such as <code>arn:aws:wellarchitected:us-west-2:123456789012:lens/0123456789abcdef01234567890abcdef</code>.</p>
    /// <p>Each lens is identified by its <code>LensSummary$LensAlias</code>.</p>
    pub lens_alias: ::std::option::Option<::std::string::String>,
    /// <p>The lens version to be retrieved.</p>
    pub lens_version: ::std::option::Option<::std::string::String>,
}
impl GetLensInput {
    /// <p>The alias of the lens.</p>
    /// <p>For Amazon Web Services official lenses, this is either the lens alias, such as <code>serverless</code>, or the lens ARN, such as <code>arn:aws:wellarchitected:us-east-1::lens/serverless</code>. Note that some operations (such as ExportLens and CreateLensShare) are not permitted on Amazon Web Services official lenses.</p>
    /// <p>For custom lenses, this is the lens ARN, such as <code>arn:aws:wellarchitected:us-west-2:123456789012:lens/0123456789abcdef01234567890abcdef</code>.</p>
    /// <p>Each lens is identified by its <code>LensSummary$LensAlias</code>.</p>
    pub fn lens_alias(&self) -> ::std::option::Option<&str> {
        self.lens_alias.as_deref()
    }
    /// <p>The lens version to be retrieved.</p>
    pub fn lens_version(&self) -> ::std::option::Option<&str> {
        self.lens_version.as_deref()
    }
}
impl GetLensInput {
    /// Creates a new builder-style object to manufacture [`GetLensInput`](crate::operation::get_lens::GetLensInput).
    pub fn builder() -> crate::operation::get_lens::builders::GetLensInputBuilder {
        crate::operation::get_lens::builders::GetLensInputBuilder::default()
    }
}

/// A builder for [`GetLensInput`](crate::operation::get_lens::GetLensInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetLensInputBuilder {
    pub(crate) lens_alias: ::std::option::Option<::std::string::String>,
    pub(crate) lens_version: ::std::option::Option<::std::string::String>,
}
impl GetLensInputBuilder {
    /// <p>The alias of the lens.</p>
    /// <p>For Amazon Web Services official lenses, this is either the lens alias, such as <code>serverless</code>, or the lens ARN, such as <code>arn:aws:wellarchitected:us-east-1::lens/serverless</code>. Note that some operations (such as ExportLens and CreateLensShare) are not permitted on Amazon Web Services official lenses.</p>
    /// <p>For custom lenses, this is the lens ARN, such as <code>arn:aws:wellarchitected:us-west-2:123456789012:lens/0123456789abcdef01234567890abcdef</code>.</p>
    /// <p>Each lens is identified by its <code>LensSummary$LensAlias</code>.</p>
    /// This field is required.
    pub fn lens_alias(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.lens_alias = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The alias of the lens.</p>
    /// <p>For Amazon Web Services official lenses, this is either the lens alias, such as <code>serverless</code>, or the lens ARN, such as <code>arn:aws:wellarchitected:us-east-1::lens/serverless</code>. Note that some operations (such as ExportLens and CreateLensShare) are not permitted on Amazon Web Services official lenses.</p>
    /// <p>For custom lenses, this is the lens ARN, such as <code>arn:aws:wellarchitected:us-west-2:123456789012:lens/0123456789abcdef01234567890abcdef</code>.</p>
    /// <p>Each lens is identified by its <code>LensSummary$LensAlias</code>.</p>
    pub fn set_lens_alias(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.lens_alias = input;
        self
    }
    /// <p>The alias of the lens.</p>
    /// <p>For Amazon Web Services official lenses, this is either the lens alias, such as <code>serverless</code>, or the lens ARN, such as <code>arn:aws:wellarchitected:us-east-1::lens/serverless</code>. Note that some operations (such as ExportLens and CreateLensShare) are not permitted on Amazon Web Services official lenses.</p>
    /// <p>For custom lenses, this is the lens ARN, such as <code>arn:aws:wellarchitected:us-west-2:123456789012:lens/0123456789abcdef01234567890abcdef</code>.</p>
    /// <p>Each lens is identified by its <code>LensSummary$LensAlias</code>.</p>
    pub fn get_lens_alias(&self) -> &::std::option::Option<::std::string::String> {
        &self.lens_alias
    }
    /// <p>The lens version to be retrieved.</p>
    pub fn lens_version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.lens_version = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The lens version to be retrieved.</p>
    pub fn set_lens_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.lens_version = input;
        self
    }
    /// <p>The lens version to be retrieved.</p>
    pub fn get_lens_version(&self) -> &::std::option::Option<::std::string::String> {
        &self.lens_version
    }
    /// Consumes the builder and constructs a [`GetLensInput`](crate::operation::get_lens::GetLensInput).
    pub fn build(self) -> ::std::result::Result<crate::operation::get_lens::GetLensInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::get_lens::GetLensInput {
            lens_alias: self.lens_alias,
            lens_version: self.lens_version,
        })
    }
}