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

com.pulumi.azurenative.sql.InstancePoolArgs Maven / Gradle / Ivy

There is a newer version: 2.78.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.sql;

import com.pulumi.azurenative.sql.enums.InstancePoolLicenseType;
import com.pulumi.azurenative.sql.inputs.SkuArgs;
import com.pulumi.core.Either;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Integer;
import java.lang.String;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final InstancePoolArgs Empty = new InstancePoolArgs();

    /**
     * The name of the instance pool to be created or updated.
     * 
     */
    @Import(name="instancePoolName")
    private @Nullable Output instancePoolName;

    /**
     * @return The name of the instance pool to be created or updated.
     * 
     */
    public Optional> instancePoolName() {
        return Optional.ofNullable(this.instancePoolName);
    }

    /**
     * The license type. Possible values are 'LicenseIncluded' (price for SQL license is included) and 'BasePrice' (without SQL license price).
     * 
     */
    @Import(name="licenseType", required=true)
    private Output> licenseType;

    /**
     * @return The license type. Possible values are 'LicenseIncluded' (price for SQL license is included) and 'BasePrice' (without SQL license price).
     * 
     */
    public Output> licenseType() {
        return this.licenseType;
    }

    /**
     * Resource location.
     * 
     */
    @Import(name="location")
    private @Nullable Output location;

    /**
     * @return Resource location.
     * 
     */
    public Optional> location() {
        return Optional.ofNullable(this.location);
    }

    /**
     * The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
     * 
     */
    @Import(name="resourceGroupName", required=true)
    private Output resourceGroupName;

    /**
     * @return The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
     * 
     */
    public Output resourceGroupName() {
        return this.resourceGroupName;
    }

    /**
     * The name and tier of the SKU.
     * 
     */
    @Import(name="sku")
    private @Nullable Output sku;

    /**
     * @return The name and tier of the SKU.
     * 
     */
    public Optional> sku() {
        return Optional.ofNullable(this.sku);
    }

    /**
     * Resource ID of the subnet to place this instance pool in.
     * 
     */
    @Import(name="subnetId", required=true)
    private Output subnetId;

    /**
     * @return Resource ID of the subnet to place this instance pool in.
     * 
     */
    public Output subnetId() {
        return this.subnetId;
    }

    /**
     * Resource tags.
     * 
     */
    @Import(name="tags")
    private @Nullable Output> tags;

    /**
     * @return Resource tags.
     * 
     */
    public Optional>> tags() {
        return Optional.ofNullable(this.tags);
    }

    /**
     * Count of vCores belonging to this instance pool.
     * 
     */
    @Import(name="vCores", required=true)
    private Output vCores;

    /**
     * @return Count of vCores belonging to this instance pool.
     * 
     */
    public Output vCores() {
        return this.vCores;
    }

    private InstancePoolArgs() {}

    private InstancePoolArgs(InstancePoolArgs $) {
        this.instancePoolName = $.instancePoolName;
        this.licenseType = $.licenseType;
        this.location = $.location;
        this.resourceGroupName = $.resourceGroupName;
        this.sku = $.sku;
        this.subnetId = $.subnetId;
        this.tags = $.tags;
        this.vCores = $.vCores;
    }

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

    public static final class Builder {
        private InstancePoolArgs $;

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

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

        /**
         * @param instancePoolName The name of the instance pool to be created or updated.
         * 
         * @return builder
         * 
         */
        public Builder instancePoolName(@Nullable Output instancePoolName) {
            $.instancePoolName = instancePoolName;
            return this;
        }

        /**
         * @param instancePoolName The name of the instance pool to be created or updated.
         * 
         * @return builder
         * 
         */
        public Builder instancePoolName(String instancePoolName) {
            return instancePoolName(Output.of(instancePoolName));
        }

        /**
         * @param licenseType The license type. Possible values are 'LicenseIncluded' (price for SQL license is included) and 'BasePrice' (without SQL license price).
         * 
         * @return builder
         * 
         */
        public Builder licenseType(Output> licenseType) {
            $.licenseType = licenseType;
            return this;
        }

        /**
         * @param licenseType The license type. Possible values are 'LicenseIncluded' (price for SQL license is included) and 'BasePrice' (without SQL license price).
         * 
         * @return builder
         * 
         */
        public Builder licenseType(Either licenseType) {
            return licenseType(Output.of(licenseType));
        }

        /**
         * @param licenseType The license type. Possible values are 'LicenseIncluded' (price for SQL license is included) and 'BasePrice' (without SQL license price).
         * 
         * @return builder
         * 
         */
        public Builder licenseType(String licenseType) {
            return licenseType(Either.ofLeft(licenseType));
        }

        /**
         * @param licenseType The license type. Possible values are 'LicenseIncluded' (price for SQL license is included) and 'BasePrice' (without SQL license price).
         * 
         * @return builder
         * 
         */
        public Builder licenseType(InstancePoolLicenseType licenseType) {
            return licenseType(Either.ofRight(licenseType));
        }

        /**
         * @param location Resource location.
         * 
         * @return builder
         * 
         */
        public Builder location(@Nullable Output location) {
            $.location = location;
            return this;
        }

        /**
         * @param location Resource location.
         * 
         * @return builder
         * 
         */
        public Builder location(String location) {
            return location(Output.of(location));
        }

        /**
         * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(Output resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param sku The name and tier of the SKU.
         * 
         * @return builder
         * 
         */
        public Builder sku(@Nullable Output sku) {
            $.sku = sku;
            return this;
        }

        /**
         * @param sku The name and tier of the SKU.
         * 
         * @return builder
         * 
         */
        public Builder sku(SkuArgs sku) {
            return sku(Output.of(sku));
        }

        /**
         * @param subnetId Resource ID of the subnet to place this instance pool in.
         * 
         * @return builder
         * 
         */
        public Builder subnetId(Output subnetId) {
            $.subnetId = subnetId;
            return this;
        }

        /**
         * @param subnetId Resource ID of the subnet to place this instance pool in.
         * 
         * @return builder
         * 
         */
        public Builder subnetId(String subnetId) {
            return subnetId(Output.of(subnetId));
        }

        /**
         * @param tags Resource tags.
         * 
         * @return builder
         * 
         */
        public Builder tags(@Nullable Output> tags) {
            $.tags = tags;
            return this;
        }

        /**
         * @param tags Resource tags.
         * 
         * @return builder
         * 
         */
        public Builder tags(Map tags) {
            return tags(Output.of(tags));
        }

        /**
         * @param vCores Count of vCores belonging to this instance pool.
         * 
         * @return builder
         * 
         */
        public Builder vCores(Output vCores) {
            $.vCores = vCores;
            return this;
        }

        /**
         * @param vCores Count of vCores belonging to this instance pool.
         * 
         * @return builder
         * 
         */
        public Builder vCores(Integer vCores) {
            return vCores(Output.of(vCores));
        }

        public InstancePoolArgs build() {
            if ($.licenseType == null) {
                throw new MissingRequiredPropertyException("InstancePoolArgs", "licenseType");
            }
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("InstancePoolArgs", "resourceGroupName");
            }
            if ($.subnetId == null) {
                throw new MissingRequiredPropertyException("InstancePoolArgs", "subnetId");
            }
            if ($.vCores == null) {
                throw new MissingRequiredPropertyException("InstancePoolArgs", "vCores");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy