aws-sdk-redshift 1.106.0

AWS SDK for Amazon Redshift
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, ::std::fmt::Debug)]
pub struct DescribeScheduledActionsInput {
    /// <p>The name of the scheduled action to retrieve.</p>
    pub scheduled_action_name: ::std::option::Option<::std::string::String>,
    /// <p>The type of the scheduled actions to retrieve.</p>
    pub target_action_type: ::std::option::Option<crate::types::ScheduledActionTypeValues>,
    /// <p>The start time in UTC of the scheduled actions to retrieve. Only active scheduled actions that have invocations after this time are retrieved.</p>
    pub start_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>The end time in UTC of the scheduled action to retrieve. Only active scheduled actions that have invocations before this time are retrieved.</p>
    pub end_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>If true, retrieve only active scheduled actions. If false, retrieve only disabled scheduled actions.</p>
    pub active: ::std::option::Option<bool>,
    /// <p>List of scheduled action filters.</p>
    pub filters: ::std::option::Option<::std::vec::Vec<crate::types::ScheduledActionFilter>>,
    /// <p>An optional parameter that specifies the starting point to return a set of response records. When the results of a <code>DescribeScheduledActions</code> request exceed the value specified in <code>MaxRecords</code>, Amazon Web Services returns a value in the <code>Marker</code> field of the response. You can retrieve the next set of response records by providing the returned marker value in the <code>Marker</code> parameter and retrying the request.</p>
    pub marker: ::std::option::Option<::std::string::String>,
    /// <p>The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified <code>MaxRecords</code> value, a value is returned in a <code>marker</code> field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.</p>
    /// <p>Default: <code>100</code></p>
    /// <p>Constraints: minimum 20, maximum 100.</p>
    pub max_records: ::std::option::Option<i32>,
}
impl DescribeScheduledActionsInput {
    /// <p>The name of the scheduled action to retrieve.</p>
    pub fn scheduled_action_name(&self) -> ::std::option::Option<&str> {
        self.scheduled_action_name.as_deref()
    }
    /// <p>The type of the scheduled actions to retrieve.</p>
    pub fn target_action_type(&self) -> ::std::option::Option<&crate::types::ScheduledActionTypeValues> {
        self.target_action_type.as_ref()
    }
    /// <p>The start time in UTC of the scheduled actions to retrieve. Only active scheduled actions that have invocations after this time are retrieved.</p>
    pub fn start_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.start_time.as_ref()
    }
    /// <p>The end time in UTC of the scheduled action to retrieve. Only active scheduled actions that have invocations before this time are retrieved.</p>
    pub fn end_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.end_time.as_ref()
    }
    /// <p>If true, retrieve only active scheduled actions. If false, retrieve only disabled scheduled actions.</p>
    pub fn active(&self) -> ::std::option::Option<bool> {
        self.active
    }
    /// <p>List of scheduled action filters.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.filters.is_none()`.
    pub fn filters(&self) -> &[crate::types::ScheduledActionFilter] {
        self.filters.as_deref().unwrap_or_default()
    }
    /// <p>An optional parameter that specifies the starting point to return a set of response records. When the results of a <code>DescribeScheduledActions</code> request exceed the value specified in <code>MaxRecords</code>, Amazon Web Services returns a value in the <code>Marker</code> field of the response. You can retrieve the next set of response records by providing the returned marker value in the <code>Marker</code> parameter and retrying the request.</p>
    pub fn marker(&self) -> ::std::option::Option<&str> {
        self.marker.as_deref()
    }
    /// <p>The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified <code>MaxRecords</code> value, a value is returned in a <code>marker</code> field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.</p>
    /// <p>Default: <code>100</code></p>
    /// <p>Constraints: minimum 20, maximum 100.</p>
    pub fn max_records(&self) -> ::std::option::Option<i32> {
        self.max_records
    }
}
impl DescribeScheduledActionsInput {
    /// Creates a new builder-style object to manufacture [`DescribeScheduledActionsInput`](crate::operation::describe_scheduled_actions::DescribeScheduledActionsInput).
    pub fn builder() -> crate::operation::describe_scheduled_actions::builders::DescribeScheduledActionsInputBuilder {
        crate::operation::describe_scheduled_actions::builders::DescribeScheduledActionsInputBuilder::default()
    }
}

/// A builder for [`DescribeScheduledActionsInput`](crate::operation::describe_scheduled_actions::DescribeScheduledActionsInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct DescribeScheduledActionsInputBuilder {
    pub(crate) scheduled_action_name: ::std::option::Option<::std::string::String>,
    pub(crate) target_action_type: ::std::option::Option<crate::types::ScheduledActionTypeValues>,
    pub(crate) start_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) end_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) active: ::std::option::Option<bool>,
    pub(crate) filters: ::std::option::Option<::std::vec::Vec<crate::types::ScheduledActionFilter>>,
    pub(crate) marker: ::std::option::Option<::std::string::String>,
    pub(crate) max_records: ::std::option::Option<i32>,
}
impl DescribeScheduledActionsInputBuilder {
    /// <p>The name of the scheduled action to retrieve.</p>
    pub fn scheduled_action_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.scheduled_action_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of the scheduled action to retrieve.</p>
    pub fn set_scheduled_action_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.scheduled_action_name = input;
        self
    }
    /// <p>The name of the scheduled action to retrieve.</p>
    pub fn get_scheduled_action_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.scheduled_action_name
    }
    /// <p>The type of the scheduled actions to retrieve.</p>
    pub fn target_action_type(mut self, input: crate::types::ScheduledActionTypeValues) -> Self {
        self.target_action_type = ::std::option::Option::Some(input);
        self
    }
    /// <p>The type of the scheduled actions to retrieve.</p>
    pub fn set_target_action_type(mut self, input: ::std::option::Option<crate::types::ScheduledActionTypeValues>) -> Self {
        self.target_action_type = input;
        self
    }
    /// <p>The type of the scheduled actions to retrieve.</p>
    pub fn get_target_action_type(&self) -> &::std::option::Option<crate::types::ScheduledActionTypeValues> {
        &self.target_action_type
    }
    /// <p>The start time in UTC of the scheduled actions to retrieve. Only active scheduled actions that have invocations after this time are retrieved.</p>
    pub fn start_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.start_time = ::std::option::Option::Some(input);
        self
    }
    /// <p>The start time in UTC of the scheduled actions to retrieve. Only active scheduled actions that have invocations after this time are retrieved.</p>
    pub fn set_start_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.start_time = input;
        self
    }
    /// <p>The start time in UTC of the scheduled actions to retrieve. Only active scheduled actions that have invocations after this time are retrieved.</p>
    pub fn get_start_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.start_time
    }
    /// <p>The end time in UTC of the scheduled action to retrieve. Only active scheduled actions that have invocations before this time are retrieved.</p>
    pub fn end_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.end_time = ::std::option::Option::Some(input);
        self
    }
    /// <p>The end time in UTC of the scheduled action to retrieve. Only active scheduled actions that have invocations before this time are retrieved.</p>
    pub fn set_end_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.end_time = input;
        self
    }
    /// <p>The end time in UTC of the scheduled action to retrieve. Only active scheduled actions that have invocations before this time are retrieved.</p>
    pub fn get_end_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.end_time
    }
    /// <p>If true, retrieve only active scheduled actions. If false, retrieve only disabled scheduled actions.</p>
    pub fn active(mut self, input: bool) -> Self {
        self.active = ::std::option::Option::Some(input);
        self
    }
    /// <p>If true, retrieve only active scheduled actions. If false, retrieve only disabled scheduled actions.</p>
    pub fn set_active(mut self, input: ::std::option::Option<bool>) -> Self {
        self.active = input;
        self
    }
    /// <p>If true, retrieve only active scheduled actions. If false, retrieve only disabled scheduled actions.</p>
    pub fn get_active(&self) -> &::std::option::Option<bool> {
        &self.active
    }
    /// Appends an item to `filters`.
    ///
    /// To override the contents of this collection use [`set_filters`](Self::set_filters).
    ///
    /// <p>List of scheduled action filters.</p>
    pub fn filters(mut self, input: crate::types::ScheduledActionFilter) -> Self {
        let mut v = self.filters.unwrap_or_default();
        v.push(input);
        self.filters = ::std::option::Option::Some(v);
        self
    }
    /// <p>List of scheduled action filters.</p>
    pub fn set_filters(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::ScheduledActionFilter>>) -> Self {
        self.filters = input;
        self
    }
    /// <p>List of scheduled action filters.</p>
    pub fn get_filters(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::ScheduledActionFilter>> {
        &self.filters
    }
    /// <p>An optional parameter that specifies the starting point to return a set of response records. When the results of a <code>DescribeScheduledActions</code> request exceed the value specified in <code>MaxRecords</code>, Amazon Web Services returns a value in the <code>Marker</code> field of the response. You can retrieve the next set of response records by providing the returned marker value in the <code>Marker</code> parameter and retrying the request.</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>An optional parameter that specifies the starting point to return a set of response records. When the results of a <code>DescribeScheduledActions</code> request exceed the value specified in <code>MaxRecords</code>, Amazon Web Services returns a value in the <code>Marker</code> field of the response. You can retrieve the next set of response records by providing the returned marker value in the <code>Marker</code> parameter and retrying the request.</p>
    pub fn set_marker(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.marker = input;
        self
    }
    /// <p>An optional parameter that specifies the starting point to return a set of response records. When the results of a <code>DescribeScheduledActions</code> request exceed the value specified in <code>MaxRecords</code>, Amazon Web Services returns a value in the <code>Marker</code> field of the response. You can retrieve the next set of response records by providing the returned marker value in the <code>Marker</code> parameter and retrying the request.</p>
    pub fn get_marker(&self) -> &::std::option::Option<::std::string::String> {
        &self.marker
    }
    /// <p>The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified <code>MaxRecords</code> value, a value is returned in a <code>marker</code> field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.</p>
    /// <p>Default: <code>100</code></p>
    /// <p>Constraints: minimum 20, maximum 100.</p>
    pub fn max_records(mut self, input: i32) -> Self {
        self.max_records = ::std::option::Option::Some(input);
        self
    }
    /// <p>The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified <code>MaxRecords</code> value, a value is returned in a <code>marker</code> field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.</p>
    /// <p>Default: <code>100</code></p>
    /// <p>Constraints: minimum 20, maximum 100.</p>
    pub fn set_max_records(mut self, input: ::std::option::Option<i32>) -> Self {
        self.max_records = input;
        self
    }
    /// <p>The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified <code>MaxRecords</code> value, a value is returned in a <code>marker</code> field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.</p>
    /// <p>Default: <code>100</code></p>
    /// <p>Constraints: minimum 20, maximum 100.</p>
    pub fn get_max_records(&self) -> &::std::option::Option<i32> {
        &self.max_records
    }
    /// Consumes the builder and constructs a [`DescribeScheduledActionsInput`](crate::operation::describe_scheduled_actions::DescribeScheduledActionsInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<
        crate::operation::describe_scheduled_actions::DescribeScheduledActionsInput,
        ::aws_smithy_types::error::operation::BuildError,
    > {
        ::std::result::Result::Ok(crate::operation::describe_scheduled_actions::DescribeScheduledActionsInput {
            scheduled_action_name: self.scheduled_action_name,
            target_action_type: self.target_action_type,
            start_time: self.start_time,
            end_time: self.end_time,
            active: self.active,
            filters: self.filters,
            marker: self.marker,
            max_records: self.max_records,
        })
    }
}