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

com.pulumi.azurenative.containerinstance.inputs.ResourceRequirementsArgs 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.containerinstance.inputs;

import com.pulumi.azurenative.containerinstance.inputs.ResourceLimitsArgs;
import com.pulumi.azurenative.containerinstance.inputs.ResourceRequestsArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * The resource requirements.
 * 
 */
public final class ResourceRequirementsArgs extends com.pulumi.resources.ResourceArgs {

    public static final ResourceRequirementsArgs Empty = new ResourceRequirementsArgs();

    /**
     * The resource limits of this container instance.
     * 
     */
    @Import(name="limits")
    private @Nullable Output limits;

    /**
     * @return The resource limits of this container instance.
     * 
     */
    public Optional> limits() {
        return Optional.ofNullable(this.limits);
    }

    /**
     * The resource requests of this container instance.
     * 
     */
    @Import(name="requests", required=true)
    private Output requests;

    /**
     * @return The resource requests of this container instance.
     * 
     */
    public Output requests() {
        return this.requests;
    }

    private ResourceRequirementsArgs() {}

    private ResourceRequirementsArgs(ResourceRequirementsArgs $) {
        this.limits = $.limits;
        this.requests = $.requests;
    }

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

    public static final class Builder {
        private ResourceRequirementsArgs $;

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

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

        /**
         * @param limits The resource limits of this container instance.
         * 
         * @return builder
         * 
         */
        public Builder limits(@Nullable Output limits) {
            $.limits = limits;
            return this;
        }

        /**
         * @param limits The resource limits of this container instance.
         * 
         * @return builder
         * 
         */
        public Builder limits(ResourceLimitsArgs limits) {
            return limits(Output.of(limits));
        }

        /**
         * @param requests The resource requests of this container instance.
         * 
         * @return builder
         * 
         */
        public Builder requests(Output requests) {
            $.requests = requests;
            return this;
        }

        /**
         * @param requests The resource requests of this container instance.
         * 
         * @return builder
         * 
         */
        public Builder requests(ResourceRequestsArgs requests) {
            return requests(Output.of(requests));
        }

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

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy