aws-sdk-devopsagent 1.10.0

AWS SDK for AWS DevOps Agent Service
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p>Request structure for listing assets</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct ListAssetsInput {
    /// <p>The unique identifier for the agent space to list assets from</p>
    pub agent_space_id: ::std::option::Option<::std::string::String>,
    /// <p>Filter results to only assets of this type</p>
    pub asset_type: ::std::option::Option<::std::string::String>,
    /// <p>Filter results to only assets updated after this timestamp</p>
    pub updated_after: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>Filter results to only assets updated before this timestamp</p>
    pub updated_before: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>Pagination token from a previous response to retrieve the next page of results</p>
    pub next_token: ::std::option::Option<::std::string::String>,
    /// <p>The maximum number of results to return in a single response</p>
    pub max_results: ::std::option::Option<i32>,
}
impl ListAssetsInput {
    /// <p>The unique identifier for the agent space to list assets from</p>
    pub fn agent_space_id(&self) -> ::std::option::Option<&str> {
        self.agent_space_id.as_deref()
    }
    /// <p>Filter results to only assets of this type</p>
    pub fn asset_type(&self) -> ::std::option::Option<&str> {
        self.asset_type.as_deref()
    }
    /// <p>Filter results to only assets updated after this timestamp</p>
    pub fn updated_after(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.updated_after.as_ref()
    }
    /// <p>Filter results to only assets updated before this timestamp</p>
    pub fn updated_before(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.updated_before.as_ref()
    }
    /// <p>Pagination token from a previous response to retrieve the next page of results</p>
    pub fn next_token(&self) -> ::std::option::Option<&str> {
        self.next_token.as_deref()
    }
    /// <p>The maximum number of results to return in a single response</p>
    pub fn max_results(&self) -> ::std::option::Option<i32> {
        self.max_results
    }
}
impl ListAssetsInput {
    /// Creates a new builder-style object to manufacture [`ListAssetsInput`](crate::operation::list_assets::ListAssetsInput).
    pub fn builder() -> crate::operation::list_assets::builders::ListAssetsInputBuilder {
        crate::operation::list_assets::builders::ListAssetsInputBuilder::default()
    }
}

/// A builder for [`ListAssetsInput`](crate::operation::list_assets::ListAssetsInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct ListAssetsInputBuilder {
    pub(crate) agent_space_id: ::std::option::Option<::std::string::String>,
    pub(crate) asset_type: ::std::option::Option<::std::string::String>,
    pub(crate) updated_after: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) updated_before: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) next_token: ::std::option::Option<::std::string::String>,
    pub(crate) max_results: ::std::option::Option<i32>,
}
impl ListAssetsInputBuilder {
    /// <p>The unique identifier for the agent space to list assets from</p>
    /// This field is required.
    pub fn agent_space_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.agent_space_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The unique identifier for the agent space to list assets from</p>
    pub fn set_agent_space_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.agent_space_id = input;
        self
    }
    /// <p>The unique identifier for the agent space to list assets from</p>
    pub fn get_agent_space_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.agent_space_id
    }
    /// <p>Filter results to only assets of this type</p>
    pub fn asset_type(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.asset_type = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>Filter results to only assets of this type</p>
    pub fn set_asset_type(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.asset_type = input;
        self
    }
    /// <p>Filter results to only assets of this type</p>
    pub fn get_asset_type(&self) -> &::std::option::Option<::std::string::String> {
        &self.asset_type
    }
    /// <p>Filter results to only assets updated after this timestamp</p>
    pub fn updated_after(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.updated_after = ::std::option::Option::Some(input);
        self
    }
    /// <p>Filter results to only assets updated after this timestamp</p>
    pub fn set_updated_after(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.updated_after = input;
        self
    }
    /// <p>Filter results to only assets updated after this timestamp</p>
    pub fn get_updated_after(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.updated_after
    }
    /// <p>Filter results to only assets updated before this timestamp</p>
    pub fn updated_before(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.updated_before = ::std::option::Option::Some(input);
        self
    }
    /// <p>Filter results to only assets updated before this timestamp</p>
    pub fn set_updated_before(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.updated_before = input;
        self
    }
    /// <p>Filter results to only assets updated before this timestamp</p>
    pub fn get_updated_before(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.updated_before
    }
    /// <p>Pagination token from a previous response to retrieve the next page of results</p>
    pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.next_token = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>Pagination token from a previous response to retrieve the next page of results</p>
    pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.next_token = input;
        self
    }
    /// <p>Pagination token from a previous response to retrieve the next page of results</p>
    pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
        &self.next_token
    }
    /// <p>The maximum number of results to return in a single response</p>
    pub fn max_results(mut self, input: i32) -> Self {
        self.max_results = ::std::option::Option::Some(input);
        self
    }
    /// <p>The maximum number of results to return in a single response</p>
    pub fn set_max_results(mut self, input: ::std::option::Option<i32>) -> Self {
        self.max_results = input;
        self
    }
    /// <p>The maximum number of results to return in a single response</p>
    pub fn get_max_results(&self) -> &::std::option::Option<i32> {
        &self.max_results
    }
    /// Consumes the builder and constructs a [`ListAssetsInput`](crate::operation::list_assets::ListAssetsInput).
    pub fn build(self) -> ::std::result::Result<crate::operation::list_assets::ListAssetsInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::list_assets::ListAssetsInput {
            agent_space_id: self.agent_space_id,
            asset_type: self.asset_type,
            updated_after: self.updated_after,
            updated_before: self.updated_before,
            next_token: self.next_token,
            max_results: self.max_results,
        })
    }
}