aws-sdk-workdocs 1.98.0

AWS SDK for Amazon WorkDocs
Documentation
// 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)]
pub struct GetResourcesInput {
    /// <p>The Amazon WorkDocs authentication token. Not required when using Amazon Web Services administrator credentials to access the API.</p>
    pub authentication_token: ::std::option::Option<::std::string::String>,
    /// <p>The user ID for the resource collection. This is a required field for accessing the API operation using IAM credentials.</p>
    pub user_id: ::std::option::Option<::std::string::String>,
    /// <p>The collection type.</p>
    pub collection_type: ::std::option::Option<crate::types::ResourceCollectionType>,
    /// <p>The maximum number of resources to return.</p>
    pub limit: ::std::option::Option<i32>,
    /// <p>The marker for the next set of results. This marker was received from a previous call.</p>
    pub marker: ::std::option::Option<::std::string::String>,
}
impl GetResourcesInput {
    /// <p>The Amazon WorkDocs authentication token. Not required when using Amazon Web Services administrator credentials to access the API.</p>
    pub fn authentication_token(&self) -> ::std::option::Option<&str> {
        self.authentication_token.as_deref()
    }
    /// <p>The user ID for the resource collection. This is a required field for accessing the API operation using IAM credentials.</p>
    pub fn user_id(&self) -> ::std::option::Option<&str> {
        self.user_id.as_deref()
    }
    /// <p>The collection type.</p>
    pub fn collection_type(&self) -> ::std::option::Option<&crate::types::ResourceCollectionType> {
        self.collection_type.as_ref()
    }
    /// <p>The maximum number of resources to return.</p>
    pub fn limit(&self) -> ::std::option::Option<i32> {
        self.limit
    }
    /// <p>The marker for the next set of results. This marker was received from a previous call.</p>
    pub fn marker(&self) -> ::std::option::Option<&str> {
        self.marker.as_deref()
    }
}
impl ::std::fmt::Debug for GetResourcesInput {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        let mut formatter = f.debug_struct("GetResourcesInput");
        formatter.field("authentication_token", &"*** Sensitive Data Redacted ***");
        formatter.field("user_id", &self.user_id);
        formatter.field("collection_type", &self.collection_type);
        formatter.field("limit", &self.limit);
        formatter.field("marker", &self.marker);
        formatter.finish()
    }
}
impl GetResourcesInput {
    /// Creates a new builder-style object to manufacture [`GetResourcesInput`](crate::operation::get_resources::GetResourcesInput).
    pub fn builder() -> crate::operation::get_resources::builders::GetResourcesInputBuilder {
        crate::operation::get_resources::builders::GetResourcesInputBuilder::default()
    }
}

/// A builder for [`GetResourcesInput`](crate::operation::get_resources::GetResourcesInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
#[non_exhaustive]
pub struct GetResourcesInputBuilder {
    pub(crate) authentication_token: ::std::option::Option<::std::string::String>,
    pub(crate) user_id: ::std::option::Option<::std::string::String>,
    pub(crate) collection_type: ::std::option::Option<crate::types::ResourceCollectionType>,
    pub(crate) limit: ::std::option::Option<i32>,
    pub(crate) marker: ::std::option::Option<::std::string::String>,
}
impl GetResourcesInputBuilder {
    /// <p>The Amazon WorkDocs authentication token. Not required when using Amazon Web Services administrator credentials to access the API.</p>
    pub fn authentication_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.authentication_token = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon WorkDocs authentication token. Not required when using Amazon Web Services administrator credentials to access the API.</p>
    pub fn set_authentication_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.authentication_token = input;
        self
    }
    /// <p>The Amazon WorkDocs authentication token. Not required when using Amazon Web Services administrator credentials to access the API.</p>
    pub fn get_authentication_token(&self) -> &::std::option::Option<::std::string::String> {
        &self.authentication_token
    }
    /// <p>The user ID for the resource collection. This is a required field for accessing the API operation using IAM credentials.</p>
    pub fn user_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.user_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The user ID for the resource collection. This is a required field for accessing the API operation using IAM credentials.</p>
    pub fn set_user_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.user_id = input;
        self
    }
    /// <p>The user ID for the resource collection. This is a required field for accessing the API operation using IAM credentials.</p>
    pub fn get_user_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.user_id
    }
    /// <p>The collection type.</p>
    pub fn collection_type(mut self, input: crate::types::ResourceCollectionType) -> Self {
        self.collection_type = ::std::option::Option::Some(input);
        self
    }
    /// <p>The collection type.</p>
    pub fn set_collection_type(mut self, input: ::std::option::Option<crate::types::ResourceCollectionType>) -> Self {
        self.collection_type = input;
        self
    }
    /// <p>The collection type.</p>
    pub fn get_collection_type(&self) -> &::std::option::Option<crate::types::ResourceCollectionType> {
        &self.collection_type
    }
    /// <p>The maximum number of resources to return.</p>
    pub fn limit(mut self, input: i32) -> Self {
        self.limit = ::std::option::Option::Some(input);
        self
    }
    /// <p>The maximum number of resources to return.</p>
    pub fn set_limit(mut self, input: ::std::option::Option<i32>) -> Self {
        self.limit = input;
        self
    }
    /// <p>The maximum number of resources to return.</p>
    pub fn get_limit(&self) -> &::std::option::Option<i32> {
        &self.limit
    }
    /// <p>The marker for the next set of results. This marker was received from a previous call.</p>
    pub fn marker(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.marker = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The marker for the next set of results. This marker was received from a previous call.</p>
    pub fn set_marker(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.marker = input;
        self
    }
    /// <p>The marker for the next set of results. This marker was received from a previous call.</p>
    pub fn get_marker(&self) -> &::std::option::Option<::std::string::String> {
        &self.marker
    }
    /// Consumes the builder and constructs a [`GetResourcesInput`](crate::operation::get_resources::GetResourcesInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::get_resources::GetResourcesInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::get_resources::GetResourcesInput {
            authentication_token: self.authentication_token,
            user_id: self.user_id,
            collection_type: self.collection_type,
            limit: self.limit,
            marker: self.marker,
        })
    }
}
impl ::std::fmt::Debug for GetResourcesInputBuilder {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        let mut formatter = f.debug_struct("GetResourcesInputBuilder");
        formatter.field("authentication_token", &"*** Sensitive Data Redacted ***");
        formatter.field("user_id", &self.user_id);
        formatter.field("collection_type", &self.collection_type);
        formatter.field("limit", &self.limit);
        formatter.field("marker", &self.marker);
        formatter.finish()
    }
}