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

com.pulumi.digitalocean.inputs.SpacesBucketCorsConfigurationState Maven / Gradle / Ivy

There is a newer version: 4.35.0
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.digitalocean.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.digitalocean.inputs.SpacesBucketCorsConfigurationCorsRuleArgs;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final SpacesBucketCorsConfigurationState Empty = new SpacesBucketCorsConfigurationState();

    /**
     * The name of the bucket to which to apply the CORS configuration.
     * 
     */
    @Import(name="bucket")
    private @Nullable Output bucket;

    /**
     * @return The name of the bucket to which to apply the CORS configuration.
     * 
     */
    public Optional> bucket() {
        return Optional.ofNullable(this.bucket);
    }

    /**
     * Set of origins and methods (cross-origin access that you want to allow). See below. You can configure up to 100 rules.
     * 
     */
    @Import(name="corsRules")
    private @Nullable Output> corsRules;

    /**
     * @return Set of origins and methods (cross-origin access that you want to allow). See below. You can configure up to 100 rules.
     * 
     */
    public Optional>> corsRules() {
        return Optional.ofNullable(this.corsRules);
    }

    /**
     * The region where the bucket resides.
     * 
     */
    @Import(name="region")
    private @Nullable Output region;

    /**
     * @return The region where the bucket resides.
     * 
     */
    public Optional> region() {
        return Optional.ofNullable(this.region);
    }

    private SpacesBucketCorsConfigurationState() {}

    private SpacesBucketCorsConfigurationState(SpacesBucketCorsConfigurationState $) {
        this.bucket = $.bucket;
        this.corsRules = $.corsRules;
        this.region = $.region;
    }

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

    public static final class Builder {
        private SpacesBucketCorsConfigurationState $;

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

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

        /**
         * @param bucket The name of the bucket to which to apply the CORS configuration.
         * 
         * @return builder
         * 
         */
        public Builder bucket(@Nullable Output bucket) {
            $.bucket = bucket;
            return this;
        }

        /**
         * @param bucket The name of the bucket to which to apply the CORS configuration.
         * 
         * @return builder
         * 
         */
        public Builder bucket(String bucket) {
            return bucket(Output.of(bucket));
        }

        /**
         * @param corsRules Set of origins and methods (cross-origin access that you want to allow). See below. You can configure up to 100 rules.
         * 
         * @return builder
         * 
         */
        public Builder corsRules(@Nullable Output> corsRules) {
            $.corsRules = corsRules;
            return this;
        }

        /**
         * @param corsRules Set of origins and methods (cross-origin access that you want to allow). See below. You can configure up to 100 rules.
         * 
         * @return builder
         * 
         */
        public Builder corsRules(List corsRules) {
            return corsRules(Output.of(corsRules));
        }

        /**
         * @param corsRules Set of origins and methods (cross-origin access that you want to allow). See below. You can configure up to 100 rules.
         * 
         * @return builder
         * 
         */
        public Builder corsRules(SpacesBucketCorsConfigurationCorsRuleArgs... corsRules) {
            return corsRules(List.of(corsRules));
        }

        /**
         * @param region The region where the bucket resides.
         * 
         * @return builder
         * 
         */
        public Builder region(@Nullable Output region) {
            $.region = region;
            return this;
        }

        /**
         * @param region The region where the bucket resides.
         * 
         * @return builder
         * 
         */
        public Builder region(String region) {
            return region(Output.of(region));
        }

        public SpacesBucketCorsConfigurationState build() {
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy