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

com.pulumi.azurenative.containerstorage.PoolArgs 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.containerstorage;

import com.pulumi.azurenative.containerstorage.enums.ReclaimPolicy;
import com.pulumi.azurenative.containerstorage.enums.Zone;
import com.pulumi.azurenative.containerstorage.inputs.AssignmentArgs;
import com.pulumi.azurenative.containerstorage.inputs.PoolTypeArgs;
import com.pulumi.azurenative.containerstorage.inputs.ResourcesArgs;
import com.pulumi.core.Either;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
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 PoolArgs extends com.pulumi.resources.ResourceArgs {

    public static final PoolArgs Empty = new PoolArgs();

    /**
     * List of resources that should have access to the pool. Typically ARM references to AKS clusters or ACI Container Groups. For local and standard this must be a single reference. For ElasticSAN there can be many.
     * 
     */
    @Import(name="assignments")
    private @Nullable Output> assignments;

    /**
     * @return List of resources that should have access to the pool. Typically ARM references to AKS clusters or ACI Container Groups. For local and standard this must be a single reference. For ElasticSAN there can be many.
     * 
     */
    public Optional>> assignments() {
        return Optional.ofNullable(this.assignments);
    }

    /**
     * The geo-location where the resource lives
     * 
     */
    @Import(name="location")
    private @Nullable Output location;

    /**
     * @return The geo-location where the resource lives
     * 
     */
    public Optional> location() {
        return Optional.ofNullable(this.location);
    }

    /**
     * Pool Object
     * 
     */
    @Import(name="poolName")
    private @Nullable Output poolName;

    /**
     * @return Pool Object
     * 
     */
    public Optional> poolName() {
        return Optional.ofNullable(this.poolName);
    }

    /**
     * Type of the Pool: ephemeralDisk, azureDisk, or elasticsan.
     * 
     */
    @Import(name="poolType", required=true)
    private Output poolType;

    /**
     * @return Type of the Pool: ephemeralDisk, azureDisk, or elasticsan.
     * 
     */
    public Output poolType() {
        return this.poolType;
    }

    /**
     * ReclaimPolicy defines what happens to the backend storage when StoragePool is deleted
     * 
     */
    @Import(name="reclaimPolicy")
    private @Nullable Output> reclaimPolicy;

    /**
     * @return ReclaimPolicy defines what happens to the backend storage when StoragePool is deleted
     * 
     */
    public Optional>> reclaimPolicy() {
        return Optional.ofNullable(this.reclaimPolicy);
    }

    /**
     * The name of the resource group. The name is case insensitive.
     * 
     */
    @Import(name="resourceGroupName", required=true)
    private Output resourceGroupName;

    /**
     * @return The name of the resource group. The name is case insensitive.
     * 
     */
    public Output resourceGroupName() {
        return this.resourceGroupName;
    }

    /**
     * Resources represent the resources the pool should have.
     * 
     */
    @Import(name="resources")
    private @Nullable Output resources;

    /**
     * @return Resources represent the resources the pool should have.
     * 
     */
    public Optional> resources() {
        return Optional.ofNullable(this.resources);
    }

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

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

    /**
     * List of availability zones that resources can be created in.
     * 
     */
    @Import(name="zones")
    private @Nullable Output>> zones;

    /**
     * @return List of availability zones that resources can be created in.
     * 
     */
    public Optional>>> zones() {
        return Optional.ofNullable(this.zones);
    }

    private PoolArgs() {}

    private PoolArgs(PoolArgs $) {
        this.assignments = $.assignments;
        this.location = $.location;
        this.poolName = $.poolName;
        this.poolType = $.poolType;
        this.reclaimPolicy = $.reclaimPolicy;
        this.resourceGroupName = $.resourceGroupName;
        this.resources = $.resources;
        this.tags = $.tags;
        this.zones = $.zones;
    }

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

    public static final class Builder {
        private PoolArgs $;

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

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

        /**
         * @param assignments List of resources that should have access to the pool. Typically ARM references to AKS clusters or ACI Container Groups. For local and standard this must be a single reference. For ElasticSAN there can be many.
         * 
         * @return builder
         * 
         */
        public Builder assignments(@Nullable Output> assignments) {
            $.assignments = assignments;
            return this;
        }

        /**
         * @param assignments List of resources that should have access to the pool. Typically ARM references to AKS clusters or ACI Container Groups. For local and standard this must be a single reference. For ElasticSAN there can be many.
         * 
         * @return builder
         * 
         */
        public Builder assignments(List assignments) {
            return assignments(Output.of(assignments));
        }

        /**
         * @param assignments List of resources that should have access to the pool. Typically ARM references to AKS clusters or ACI Container Groups. For local and standard this must be a single reference. For ElasticSAN there can be many.
         * 
         * @return builder
         * 
         */
        public Builder assignments(AssignmentArgs... assignments) {
            return assignments(List.of(assignments));
        }

        /**
         * @param location The geo-location where the resource lives
         * 
         * @return builder
         * 
         */
        public Builder location(@Nullable Output location) {
            $.location = location;
            return this;
        }

        /**
         * @param location The geo-location where the resource lives
         * 
         * @return builder
         * 
         */
        public Builder location(String location) {
            return location(Output.of(location));
        }

        /**
         * @param poolName Pool Object
         * 
         * @return builder
         * 
         */
        public Builder poolName(@Nullable Output poolName) {
            $.poolName = poolName;
            return this;
        }

        /**
         * @param poolName Pool Object
         * 
         * @return builder
         * 
         */
        public Builder poolName(String poolName) {
            return poolName(Output.of(poolName));
        }

        /**
         * @param poolType Type of the Pool: ephemeralDisk, azureDisk, or elasticsan.
         * 
         * @return builder
         * 
         */
        public Builder poolType(Output poolType) {
            $.poolType = poolType;
            return this;
        }

        /**
         * @param poolType Type of the Pool: ephemeralDisk, azureDisk, or elasticsan.
         * 
         * @return builder
         * 
         */
        public Builder poolType(PoolTypeArgs poolType) {
            return poolType(Output.of(poolType));
        }

        /**
         * @param reclaimPolicy ReclaimPolicy defines what happens to the backend storage when StoragePool is deleted
         * 
         * @return builder
         * 
         */
        public Builder reclaimPolicy(@Nullable Output> reclaimPolicy) {
            $.reclaimPolicy = reclaimPolicy;
            return this;
        }

        /**
         * @param reclaimPolicy ReclaimPolicy defines what happens to the backend storage when StoragePool is deleted
         * 
         * @return builder
         * 
         */
        public Builder reclaimPolicy(Either reclaimPolicy) {
            return reclaimPolicy(Output.of(reclaimPolicy));
        }

        /**
         * @param reclaimPolicy ReclaimPolicy defines what happens to the backend storage when StoragePool is deleted
         * 
         * @return builder
         * 
         */
        public Builder reclaimPolicy(String reclaimPolicy) {
            return reclaimPolicy(Either.ofLeft(reclaimPolicy));
        }

        /**
         * @param reclaimPolicy ReclaimPolicy defines what happens to the backend storage when StoragePool is deleted
         * 
         * @return builder
         * 
         */
        public Builder reclaimPolicy(ReclaimPolicy reclaimPolicy) {
            return reclaimPolicy(Either.ofRight(reclaimPolicy));
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(Output resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param resources Resources represent the resources the pool should have.
         * 
         * @return builder
         * 
         */
        public Builder resources(@Nullable Output resources) {
            $.resources = resources;
            return this;
        }

        /**
         * @param resources Resources represent the resources the pool should have.
         * 
         * @return builder
         * 
         */
        public Builder resources(ResourcesArgs resources) {
            return resources(Output.of(resources));
        }

        /**
         * @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 zones List of availability zones that resources can be created in.
         * 
         * @return builder
         * 
         */
        public Builder zones(@Nullable Output>> zones) {
            $.zones = zones;
            return this;
        }

        /**
         * @param zones List of availability zones that resources can be created in.
         * 
         * @return builder
         * 
         */
        public Builder zones(List> zones) {
            return zones(Output.of(zones));
        }

        /**
         * @param zones List of availability zones that resources can be created in.
         * 
         * @return builder
         * 
         */
        public Builder zones(Either... zones) {
            return zones(List.of(zones));
        }

        public PoolArgs build() {
            if ($.poolType == null) {
                throw new MissingRequiredPropertyException("PoolArgs", "poolType");
            }
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("PoolArgs", "resourceGroupName");
            }
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy