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

com.pulumi.azurenative.blueprint.inputs.ParameterDefinitionArgs Maven / Gradle / Ivy

There is a newer version: 2.82.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.azurenative.blueprint.inputs;

import com.pulumi.azurenative.blueprint.enums.TemplateParameterType;
import com.pulumi.core.Either;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Object;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * Represent a parameter with constrains and metadata.
 * 
 */
public final class ParameterDefinitionArgs extends com.pulumi.resources.ResourceArgs {

    public static final ParameterDefinitionArgs Empty = new ParameterDefinitionArgs();

    /**
     * Array of allowed values for this parameter.
     * 
     */
    @Import(name="allowedValues")
    private @Nullable Output> allowedValues;

    /**
     * @return Array of allowed values for this parameter.
     * 
     */
    public Optional>> allowedValues() {
        return Optional.ofNullable(this.allowedValues);
    }

    /**
     * Default Value for this parameter.
     * 
     */
    @Import(name="defaultValue")
    private @Nullable Output defaultValue;

    /**
     * @return Default Value for this parameter.
     * 
     */
    public Optional> defaultValue() {
        return Optional.ofNullable(this.defaultValue);
    }

    /**
     * Description of this parameter/resourceGroup.
     * 
     */
    @Import(name="description")
    private @Nullable Output description;

    /**
     * @return Description of this parameter/resourceGroup.
     * 
     */
    public Optional> description() {
        return Optional.ofNullable(this.description);
    }

    /**
     * DisplayName of this parameter/resourceGroup.
     * 
     */
    @Import(name="displayName")
    private @Nullable Output displayName;

    /**
     * @return DisplayName of this parameter/resourceGroup.
     * 
     */
    public Optional> displayName() {
        return Optional.ofNullable(this.displayName);
    }

    /**
     * StrongType for UI to render rich experience during blueprint assignment. Supported strong types are resourceType, principalId and location.
     * 
     */
    @Import(name="strongType")
    private @Nullable Output strongType;

    /**
     * @return StrongType for UI to render rich experience during blueprint assignment. Supported strong types are resourceType, principalId and location.
     * 
     */
    public Optional> strongType() {
        return Optional.ofNullable(this.strongType);
    }

    /**
     * Allowed data types for Resource Manager template parameters.
     * 
     */
    @Import(name="type", required=true)
    private Output> type;

    /**
     * @return Allowed data types for Resource Manager template parameters.
     * 
     */
    public Output> type() {
        return this.type;
    }

    private ParameterDefinitionArgs() {}

    private ParameterDefinitionArgs(ParameterDefinitionArgs $) {
        this.allowedValues = $.allowedValues;
        this.defaultValue = $.defaultValue;
        this.description = $.description;
        this.displayName = $.displayName;
        this.strongType = $.strongType;
        this.type = $.type;
    }

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

    public static final class Builder {
        private ParameterDefinitionArgs $;

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

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

        /**
         * @param allowedValues Array of allowed values for this parameter.
         * 
         * @return builder
         * 
         */
        public Builder allowedValues(@Nullable Output> allowedValues) {
            $.allowedValues = allowedValues;
            return this;
        }

        /**
         * @param allowedValues Array of allowed values for this parameter.
         * 
         * @return builder
         * 
         */
        public Builder allowedValues(List allowedValues) {
            return allowedValues(Output.of(allowedValues));
        }

        /**
         * @param allowedValues Array of allowed values for this parameter.
         * 
         * @return builder
         * 
         */
        public Builder allowedValues(Object... allowedValues) {
            return allowedValues(List.of(allowedValues));
        }

        /**
         * @param defaultValue Default Value for this parameter.
         * 
         * @return builder
         * 
         */
        public Builder defaultValue(@Nullable Output defaultValue) {
            $.defaultValue = defaultValue;
            return this;
        }

        /**
         * @param defaultValue Default Value for this parameter.
         * 
         * @return builder
         * 
         */
        public Builder defaultValue(Object defaultValue) {
            return defaultValue(Output.of(defaultValue));
        }

        /**
         * @param description Description of this parameter/resourceGroup.
         * 
         * @return builder
         * 
         */
        public Builder description(@Nullable Output description) {
            $.description = description;
            return this;
        }

        /**
         * @param description Description of this parameter/resourceGroup.
         * 
         * @return builder
         * 
         */
        public Builder description(String description) {
            return description(Output.of(description));
        }

        /**
         * @param displayName DisplayName of this parameter/resourceGroup.
         * 
         * @return builder
         * 
         */
        public Builder displayName(@Nullable Output displayName) {
            $.displayName = displayName;
            return this;
        }

        /**
         * @param displayName DisplayName of this parameter/resourceGroup.
         * 
         * @return builder
         * 
         */
        public Builder displayName(String displayName) {
            return displayName(Output.of(displayName));
        }

        /**
         * @param strongType StrongType for UI to render rich experience during blueprint assignment. Supported strong types are resourceType, principalId and location.
         * 
         * @return builder
         * 
         */
        public Builder strongType(@Nullable Output strongType) {
            $.strongType = strongType;
            return this;
        }

        /**
         * @param strongType StrongType for UI to render rich experience during blueprint assignment. Supported strong types are resourceType, principalId and location.
         * 
         * @return builder
         * 
         */
        public Builder strongType(String strongType) {
            return strongType(Output.of(strongType));
        }

        /**
         * @param type Allowed data types for Resource Manager template parameters.
         * 
         * @return builder
         * 
         */
        public Builder type(Output> type) {
            $.type = type;
            return this;
        }

        /**
         * @param type Allowed data types for Resource Manager template parameters.
         * 
         * @return builder
         * 
         */
        public Builder type(Either type) {
            return type(Output.of(type));
        }

        /**
         * @param type Allowed data types for Resource Manager template parameters.
         * 
         * @return builder
         * 
         */
        public Builder type(String type) {
            return type(Either.ofLeft(type));
        }

        /**
         * @param type Allowed data types for Resource Manager template parameters.
         * 
         * @return builder
         * 
         */
        public Builder type(TemplateParameterType type) {
            return type(Either.ofRight(type));
        }

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

}