aws_sdk_lightsail/operation/get_disks/
_get_disks_input.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 GetDisksInput {
6    /// <p>The token to advance to the next page of results from your request.</p>
7    /// <p>To get a page token, perform an initial <code>GetDisks</code> request. If your results are paginated, the response will return a next page token that you can specify as the page token in a subsequent request.</p>
8    pub page_token: ::std::option::Option<::std::string::String>,
9}
10impl GetDisksInput {
11    /// <p>The token to advance to the next page of results from your request.</p>
12    /// <p>To get a page token, perform an initial <code>GetDisks</code> request. If your results are paginated, the response will return a next page token that you can specify as the page token in a subsequent request.</p>
13    pub fn page_token(&self) -> ::std::option::Option<&str> {
14        self.page_token.as_deref()
15    }
16}
17impl GetDisksInput {
18    /// Creates a new builder-style object to manufacture [`GetDisksInput`](crate::operation::get_disks::GetDisksInput).
19    pub fn builder() -> crate::operation::get_disks::builders::GetDisksInputBuilder {
20        crate::operation::get_disks::builders::GetDisksInputBuilder::default()
21    }
22}
23
24/// A builder for [`GetDisksInput`](crate::operation::get_disks::GetDisksInput).
25#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
26#[non_exhaustive]
27pub struct GetDisksInputBuilder {
28    pub(crate) page_token: ::std::option::Option<::std::string::String>,
29}
30impl GetDisksInputBuilder {
31    /// <p>The token to advance to the next page of results from your request.</p>
32    /// <p>To get a page token, perform an initial <code>GetDisks</code> request. If your results are paginated, the response will return a next page token that you can specify as the page token in a subsequent request.</p>
33    pub fn page_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
34        self.page_token = ::std::option::Option::Some(input.into());
35        self
36    }
37    /// <p>The token to advance to the next page of results from your request.</p>
38    /// <p>To get a page token, perform an initial <code>GetDisks</code> request. If your results are paginated, the response will return a next page token that you can specify as the page token in a subsequent request.</p>
39    pub fn set_page_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
40        self.page_token = input;
41        self
42    }
43    /// <p>The token to advance to the next page of results from your request.</p>
44    /// <p>To get a page token, perform an initial <code>GetDisks</code> request. If your results are paginated, the response will return a next page token that you can specify as the page token in a subsequent request.</p>
45    pub fn get_page_token(&self) -> &::std::option::Option<::std::string::String> {
46        &self.page_token
47    }
48    /// Consumes the builder and constructs a [`GetDisksInput`](crate::operation::get_disks::GetDisksInput).
49    pub fn build(self) -> ::std::result::Result<crate::operation::get_disks::GetDisksInput, ::aws_smithy_types::error::operation::BuildError> {
50        ::std::result::Result::Ok(crate::operation::get_disks::GetDisksInput { page_token: self.page_token })
51    }
52}