Skip to main content

aws_sdk_drs/types/
_licensing.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>Configuration of a machine's license.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct Licensing {
7    /// <p>Whether to enable "Bring your own license" or not.</p>
8    pub os_byol: ::std::option::Option<bool>,
9}
10impl Licensing {
11    /// <p>Whether to enable "Bring your own license" or not.</p>
12    pub fn os_byol(&self) -> ::std::option::Option<bool> {
13        self.os_byol
14    }
15}
16impl Licensing {
17    /// Creates a new builder-style object to manufacture [`Licensing`](crate::types::Licensing).
18    pub fn builder() -> crate::types::builders::LicensingBuilder {
19        crate::types::builders::LicensingBuilder::default()
20    }
21}
22
23/// A builder for [`Licensing`](crate::types::Licensing).
24#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
25#[non_exhaustive]
26pub struct LicensingBuilder {
27    pub(crate) os_byol: ::std::option::Option<bool>,
28}
29impl LicensingBuilder {
30    /// <p>Whether to enable "Bring your own license" or not.</p>
31    pub fn os_byol(mut self, input: bool) -> Self {
32        self.os_byol = ::std::option::Option::Some(input);
33        self
34    }
35    /// <p>Whether to enable "Bring your own license" or not.</p>
36    pub fn set_os_byol(mut self, input: ::std::option::Option<bool>) -> Self {
37        self.os_byol = input;
38        self
39    }
40    /// <p>Whether to enable "Bring your own license" or not.</p>
41    pub fn get_os_byol(&self) -> &::std::option::Option<bool> {
42        &self.os_byol
43    }
44    /// Consumes the builder and constructs a [`Licensing`](crate::types::Licensing).
45    pub fn build(self) -> crate::types::Licensing {
46        crate::types::Licensing { os_byol: self.os_byol }
47    }
48}