All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.github.inputs.RepositoryRulesetRulesRequiredStatusChecksArgs Maven / Gradle / Ivy

There is a newer version: 6.4.0-alpha.1731735876
Show newest version
// *** 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.github.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import com.pulumi.github.inputs.RepositoryRulesetRulesRequiredStatusChecksRequiredCheckArgs;
import java.lang.Boolean;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final RepositoryRulesetRulesRequiredStatusChecksArgs Empty = new RepositoryRulesetRulesRequiredStatusChecksArgs();

    /**
     * Status checks that are required. Several can be defined.
     * 
     */
    @Import(name="requiredChecks", required=true)
    private Output> requiredChecks;

    /**
     * @return Status checks that are required. Several can be defined.
     * 
     */
    public Output> requiredChecks() {
        return this.requiredChecks;
    }

    /**
     * Whether pull requests targeting a matching branch must be tested with the latest code. This setting will not take effect unless at least one status check is enabled. Defaults to `false`.
     * 
     */
    @Import(name="strictRequiredStatusChecksPolicy")
    private @Nullable Output strictRequiredStatusChecksPolicy;

    /**
     * @return Whether pull requests targeting a matching branch must be tested with the latest code. This setting will not take effect unless at least one status check is enabled. Defaults to `false`.
     * 
     */
    public Optional> strictRequiredStatusChecksPolicy() {
        return Optional.ofNullable(this.strictRequiredStatusChecksPolicy);
    }

    private RepositoryRulesetRulesRequiredStatusChecksArgs() {}

    private RepositoryRulesetRulesRequiredStatusChecksArgs(RepositoryRulesetRulesRequiredStatusChecksArgs $) {
        this.requiredChecks = $.requiredChecks;
        this.strictRequiredStatusChecksPolicy = $.strictRequiredStatusChecksPolicy;
    }

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

    public static final class Builder {
        private RepositoryRulesetRulesRequiredStatusChecksArgs $;

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

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

        /**
         * @param requiredChecks Status checks that are required. Several can be defined.
         * 
         * @return builder
         * 
         */
        public Builder requiredChecks(Output> requiredChecks) {
            $.requiredChecks = requiredChecks;
            return this;
        }

        /**
         * @param requiredChecks Status checks that are required. Several can be defined.
         * 
         * @return builder
         * 
         */
        public Builder requiredChecks(List requiredChecks) {
            return requiredChecks(Output.of(requiredChecks));
        }

        /**
         * @param requiredChecks Status checks that are required. Several can be defined.
         * 
         * @return builder
         * 
         */
        public Builder requiredChecks(RepositoryRulesetRulesRequiredStatusChecksRequiredCheckArgs... requiredChecks) {
            return requiredChecks(List.of(requiredChecks));
        }

        /**
         * @param strictRequiredStatusChecksPolicy Whether pull requests targeting a matching branch must be tested with the latest code. This setting will not take effect unless at least one status check is enabled. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder strictRequiredStatusChecksPolicy(@Nullable Output strictRequiredStatusChecksPolicy) {
            $.strictRequiredStatusChecksPolicy = strictRequiredStatusChecksPolicy;
            return this;
        }

        /**
         * @param strictRequiredStatusChecksPolicy Whether pull requests targeting a matching branch must be tested with the latest code. This setting will not take effect unless at least one status check is enabled. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder strictRequiredStatusChecksPolicy(Boolean strictRequiredStatusChecksPolicy) {
            return strictRequiredStatusChecksPolicy(Output.of(strictRequiredStatusChecksPolicy));
        }

        public RepositoryRulesetRulesRequiredStatusChecksArgs build() {
            if ($.requiredChecks == null) {
                throw new MissingRequiredPropertyException("RepositoryRulesetRulesRequiredStatusChecksArgs", "requiredChecks");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy