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

com.pulumi.docker.inputs.ServiceTaskSpecResourcesArgs Maven / Gradle / Ivy

There is a newer version: 4.7.0-alpha.1705607229+34a07055
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.docker.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.docker.inputs.ServiceTaskSpecResourcesLimitsArgs;
import com.pulumi.docker.inputs.ServiceTaskSpecResourcesReservationArgs;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final ServiceTaskSpecResourcesArgs Empty = new ServiceTaskSpecResourcesArgs();

    /**
     * Describes the resources which can be advertised by a node and requested by a task
     * 
     */
    @Import(name="limits")
    private @Nullable Output limits;

    /**
     * @return Describes the resources which can be advertised by a node and requested by a task
     * 
     */
    public Optional> limits() {
        return Optional.ofNullable(this.limits);
    }

    /**
     * An object describing the resources which can be advertised by a node and requested by a task
     * 
     */
    @Import(name="reservation")
    private @Nullable Output reservation;

    /**
     * @return An object describing the resources which can be advertised by a node and requested by a task
     * 
     */
    public Optional> reservation() {
        return Optional.ofNullable(this.reservation);
    }

    private ServiceTaskSpecResourcesArgs() {}

    private ServiceTaskSpecResourcesArgs(ServiceTaskSpecResourcesArgs $) {
        this.limits = $.limits;
        this.reservation = $.reservation;
    }

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

    public static final class Builder {
        private ServiceTaskSpecResourcesArgs $;

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

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

        /**
         * @param limits Describes the resources which can be advertised by a node and requested by a task
         * 
         * @return builder
         * 
         */
        public Builder limits(@Nullable Output limits) {
            $.limits = limits;
            return this;
        }

        /**
         * @param limits Describes the resources which can be advertised by a node and requested by a task
         * 
         * @return builder
         * 
         */
        public Builder limits(ServiceTaskSpecResourcesLimitsArgs limits) {
            return limits(Output.of(limits));
        }

        /**
         * @param reservation An object describing the resources which can be advertised by a node and requested by a task
         * 
         * @return builder
         * 
         */
        public Builder reservation(@Nullable Output reservation) {
            $.reservation = reservation;
            return this;
        }

        /**
         * @param reservation An object describing the resources which can be advertised by a node and requested by a task
         * 
         * @return builder
         * 
         */
        public Builder reservation(ServiceTaskSpecResourcesReservationArgs reservation) {
            return reservation(Output.of(reservation));
        }

        public ServiceTaskSpecResourcesArgs build() {
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy