// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.aws.dlm.inputs;

import com.pulumi.aws.dlm.inputs.LifecyclePolicyPolicyDetailsScheduleCreateRuleArgs;
import com.pulumi.aws.dlm.inputs.LifecyclePolicyPolicyDetailsScheduleCrossRegionCopyRuleArgs;
import com.pulumi.aws.dlm.inputs.LifecyclePolicyPolicyDetailsScheduleDeprecateRuleArgs;
import com.pulumi.aws.dlm.inputs.LifecyclePolicyPolicyDetailsScheduleFastRestoreRuleArgs;
import com.pulumi.aws.dlm.inputs.LifecyclePolicyPolicyDetailsScheduleRetainRuleArgs;
import com.pulumi.aws.dlm.inputs.LifecyclePolicyPolicyDetailsScheduleShareRuleArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.Boolean;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class LifecyclePolicyPolicyDetailsScheduleArgs extends com.pulumi.resources.ResourceArgs {

    public static final LifecyclePolicyPolicyDetailsScheduleArgs Empty = new LifecyclePolicyPolicyDetailsScheduleArgs();

    /**
     * Copy all user-defined tags on a source volume to snapshots of the volume created by this policy.
     * 
     */
    @Import(name="copyTags")
    private @Nullable Output<Boolean> copyTags;

    /**
     * @return Copy all user-defined tags on a source volume to snapshots of the volume created by this policy.
     * 
     */
    public Optional<Output<Boolean>> copyTags() {
        return Optional.ofNullable(this.copyTags);
    }

    /**
     * See the `create_rule` block. Max of 1 per schedule.
     * 
     */
    @Import(name="createRule", required=true)
    private Output<LifecyclePolicyPolicyDetailsScheduleCreateRuleArgs> createRule;

    /**
     * @return See the `create_rule` block. Max of 1 per schedule.
     * 
     */
    public Output<LifecyclePolicyPolicyDetailsScheduleCreateRuleArgs> createRule() {
        return this.createRule;
    }

    /**
     * See the `cross_region_copy_rule` block. Max of 3 per schedule.
     * 
     */
    @Import(name="crossRegionCopyRules")
    private @Nullable Output<List<LifecyclePolicyPolicyDetailsScheduleCrossRegionCopyRuleArgs>> crossRegionCopyRules;

    /**
     * @return See the `cross_region_copy_rule` block. Max of 3 per schedule.
     * 
     */
    public Optional<Output<List<LifecyclePolicyPolicyDetailsScheduleCrossRegionCopyRuleArgs>>> crossRegionCopyRules() {
        return Optional.ofNullable(this.crossRegionCopyRules);
    }

    /**
     * See the `deprecate_rule` block. Max of 1 per schedule.
     * 
     */
    @Import(name="deprecateRule")
    private @Nullable Output<LifecyclePolicyPolicyDetailsScheduleDeprecateRuleArgs> deprecateRule;

    /**
     * @return See the `deprecate_rule` block. Max of 1 per schedule.
     * 
     */
    public Optional<Output<LifecyclePolicyPolicyDetailsScheduleDeprecateRuleArgs>> deprecateRule() {
        return Optional.ofNullable(this.deprecateRule);
    }

    /**
     * See the `fast_restore_rule` block. Max of 1 per schedule.
     * 
     */
    @Import(name="fastRestoreRule")
    private @Nullable Output<LifecyclePolicyPolicyDetailsScheduleFastRestoreRuleArgs> fastRestoreRule;

    /**
     * @return See the `fast_restore_rule` block. Max of 1 per schedule.
     * 
     */
    public Optional<Output<LifecyclePolicyPolicyDetailsScheduleFastRestoreRuleArgs>> fastRestoreRule() {
        return Optional.ofNullable(this.fastRestoreRule);
    }

    /**
     * A descriptive name for the action.
     * 
     */
    @Import(name="name", required=true)
    private Output<String> name;

    /**
     * @return A descriptive name for the action.
     * 
     */
    public Output<String> name() {
        return this.name;
    }

    /**
     * Specifies the retention rule for cross-Region snapshot copies. See the `retain_rule` block. Max of 1 per action.
     * 
     */
    @Import(name="retainRule", required=true)
    private Output<LifecyclePolicyPolicyDetailsScheduleRetainRuleArgs> retainRule;

    /**
     * @return Specifies the retention rule for cross-Region snapshot copies. See the `retain_rule` block. Max of 1 per action.
     * 
     */
    public Output<LifecyclePolicyPolicyDetailsScheduleRetainRuleArgs> retainRule() {
        return this.retainRule;
    }

    /**
     * See the `share_rule` block. Max of 1 per schedule.
     * 
     */
    @Import(name="shareRule")
    private @Nullable Output<LifecyclePolicyPolicyDetailsScheduleShareRuleArgs> shareRule;

    /**
     * @return See the `share_rule` block. Max of 1 per schedule.
     * 
     */
    public Optional<Output<LifecyclePolicyPolicyDetailsScheduleShareRuleArgs>> shareRule() {
        return Optional.ofNullable(this.shareRule);
    }

    /**
     * A map of tag keys and their values. DLM lifecycle policies will already tag the snapshot with the tags on the volume. This configuration adds extra tags on top of these.
     * 
     */
    @Import(name="tagsToAdd")
    private @Nullable Output<Map<String,String>> tagsToAdd;

    /**
     * @return A map of tag keys and their values. DLM lifecycle policies will already tag the snapshot with the tags on the volume. This configuration adds extra tags on top of these.
     * 
     */
    public Optional<Output<Map<String,String>>> tagsToAdd() {
        return Optional.ofNullable(this.tagsToAdd);
    }

    /**
     * A map of tag keys and variable values, where the values are determined when the policy is executed. Only `$(instance-id)` or `$(timestamp)` are valid values. Can only be used when `resource_types` is `INSTANCE`.
     * 
     */
    @Import(name="variableTags")
    private @Nullable Output<Map<String,String>> variableTags;

    /**
     * @return A map of tag keys and variable values, where the values are determined when the policy is executed. Only `$(instance-id)` or `$(timestamp)` are valid values. Can only be used when `resource_types` is `INSTANCE`.
     * 
     */
    public Optional<Output<Map<String,String>>> variableTags() {
        return Optional.ofNullable(this.variableTags);
    }

    private LifecyclePolicyPolicyDetailsScheduleArgs() {}

    private LifecyclePolicyPolicyDetailsScheduleArgs(LifecyclePolicyPolicyDetailsScheduleArgs $) {
        this.copyTags = $.copyTags;
        this.createRule = $.createRule;
        this.crossRegionCopyRules = $.crossRegionCopyRules;
        this.deprecateRule = $.deprecateRule;
        this.fastRestoreRule = $.fastRestoreRule;
        this.name = $.name;
        this.retainRule = $.retainRule;
        this.shareRule = $.shareRule;
        this.tagsToAdd = $.tagsToAdd;
        this.variableTags = $.variableTags;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(LifecyclePolicyPolicyDetailsScheduleArgs defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private LifecyclePolicyPolicyDetailsScheduleArgs $;

        public Builder() {
            $ = new LifecyclePolicyPolicyDetailsScheduleArgs();
        }

        public Builder(LifecyclePolicyPolicyDetailsScheduleArgs defaults) {
            $ = new LifecyclePolicyPolicyDetailsScheduleArgs(Objects.requireNonNull(defaults));
        }

        /**
         * @param copyTags Copy all user-defined tags on a source volume to snapshots of the volume created by this policy.
         * 
         * @return builder
         * 
         */
        public Builder copyTags(@Nullable Output<Boolean> copyTags) {
            $.copyTags = copyTags;
            return this;
        }

        /**
         * @param copyTags Copy all user-defined tags on a source volume to snapshots of the volume created by this policy.
         * 
         * @return builder
         * 
         */
        public Builder copyTags(Boolean copyTags) {
            return copyTags(Output.of(copyTags));
        }

        /**
         * @param createRule See the `create_rule` block. Max of 1 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder createRule(Output<LifecyclePolicyPolicyDetailsScheduleCreateRuleArgs> createRule) {
            $.createRule = createRule;
            return this;
        }

        /**
         * @param createRule See the `create_rule` block. Max of 1 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder createRule(LifecyclePolicyPolicyDetailsScheduleCreateRuleArgs createRule) {
            return createRule(Output.of(createRule));
        }

        /**
         * @param crossRegionCopyRules See the `cross_region_copy_rule` block. Max of 3 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder crossRegionCopyRules(@Nullable Output<List<LifecyclePolicyPolicyDetailsScheduleCrossRegionCopyRuleArgs>> crossRegionCopyRules) {
            $.crossRegionCopyRules = crossRegionCopyRules;
            return this;
        }

        /**
         * @param crossRegionCopyRules See the `cross_region_copy_rule` block. Max of 3 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder crossRegionCopyRules(List<LifecyclePolicyPolicyDetailsScheduleCrossRegionCopyRuleArgs> crossRegionCopyRules) {
            return crossRegionCopyRules(Output.of(crossRegionCopyRules));
        }

        /**
         * @param crossRegionCopyRules See the `cross_region_copy_rule` block. Max of 3 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder crossRegionCopyRules(LifecyclePolicyPolicyDetailsScheduleCrossRegionCopyRuleArgs... crossRegionCopyRules) {
            return crossRegionCopyRules(List.of(crossRegionCopyRules));
        }

        /**
         * @param deprecateRule See the `deprecate_rule` block. Max of 1 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder deprecateRule(@Nullable Output<LifecyclePolicyPolicyDetailsScheduleDeprecateRuleArgs> deprecateRule) {
            $.deprecateRule = deprecateRule;
            return this;
        }

        /**
         * @param deprecateRule See the `deprecate_rule` block. Max of 1 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder deprecateRule(LifecyclePolicyPolicyDetailsScheduleDeprecateRuleArgs deprecateRule) {
            return deprecateRule(Output.of(deprecateRule));
        }

        /**
         * @param fastRestoreRule See the `fast_restore_rule` block. Max of 1 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder fastRestoreRule(@Nullable Output<LifecyclePolicyPolicyDetailsScheduleFastRestoreRuleArgs> fastRestoreRule) {
            $.fastRestoreRule = fastRestoreRule;
            return this;
        }

        /**
         * @param fastRestoreRule See the `fast_restore_rule` block. Max of 1 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder fastRestoreRule(LifecyclePolicyPolicyDetailsScheduleFastRestoreRuleArgs fastRestoreRule) {
            return fastRestoreRule(Output.of(fastRestoreRule));
        }

        /**
         * @param name A descriptive name for the action.
         * 
         * @return builder
         * 
         */
        public Builder name(Output<String> name) {
            $.name = name;
            return this;
        }

        /**
         * @param name A descriptive name for the action.
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param retainRule Specifies the retention rule for cross-Region snapshot copies. See the `retain_rule` block. Max of 1 per action.
         * 
         * @return builder
         * 
         */
        public Builder retainRule(Output<LifecyclePolicyPolicyDetailsScheduleRetainRuleArgs> retainRule) {
            $.retainRule = retainRule;
            return this;
        }

        /**
         * @param retainRule Specifies the retention rule for cross-Region snapshot copies. See the `retain_rule` block. Max of 1 per action.
         * 
         * @return builder
         * 
         */
        public Builder retainRule(LifecyclePolicyPolicyDetailsScheduleRetainRuleArgs retainRule) {
            return retainRule(Output.of(retainRule));
        }

        /**
         * @param shareRule See the `share_rule` block. Max of 1 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder shareRule(@Nullable Output<LifecyclePolicyPolicyDetailsScheduleShareRuleArgs> shareRule) {
            $.shareRule = shareRule;
            return this;
        }

        /**
         * @param shareRule See the `share_rule` block. Max of 1 per schedule.
         * 
         * @return builder
         * 
         */
        public Builder shareRule(LifecyclePolicyPolicyDetailsScheduleShareRuleArgs shareRule) {
            return shareRule(Output.of(shareRule));
        }

        /**
         * @param tagsToAdd A map of tag keys and their values. DLM lifecycle policies will already tag the snapshot with the tags on the volume. This configuration adds extra tags on top of these.
         * 
         * @return builder
         * 
         */
        public Builder tagsToAdd(@Nullable Output<Map<String,String>> tagsToAdd) {
            $.tagsToAdd = tagsToAdd;
            return this;
        }

        /**
         * @param tagsToAdd A map of tag keys and their values. DLM lifecycle policies will already tag the snapshot with the tags on the volume. This configuration adds extra tags on top of these.
         * 
         * @return builder
         * 
         */
        public Builder tagsToAdd(Map<String,String> tagsToAdd) {
            return tagsToAdd(Output.of(tagsToAdd));
        }

        /**
         * @param variableTags A map of tag keys and variable values, where the values are determined when the policy is executed. Only `$(instance-id)` or `$(timestamp)` are valid values. Can only be used when `resource_types` is `INSTANCE`.
         * 
         * @return builder
         * 
         */
        public Builder variableTags(@Nullable Output<Map<String,String>> variableTags) {
            $.variableTags = variableTags;
            return this;
        }

        /**
         * @param variableTags A map of tag keys and variable values, where the values are determined when the policy is executed. Only `$(instance-id)` or `$(timestamp)` are valid values. Can only be used when `resource_types` is `INSTANCE`.
         * 
         * @return builder
         * 
         */
        public Builder variableTags(Map<String,String> variableTags) {
            return variableTags(Output.of(variableTags));
        }

        public LifecyclePolicyPolicyDetailsScheduleArgs build() {
            $.createRule = Objects.requireNonNull($.createRule, "expected parameter 'createRule' to be non-null");
            $.name = Objects.requireNonNull($.name, "expected parameter 'name' to be non-null");
            $.retainRule = Objects.requireNonNull($.retainRule, "expected parameter 'retainRule' to be non-null");
            return $;
        }
    }

}
