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

com.pulumi.azurenative.network.inputs.RouteArgs 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.network.inputs;

import com.pulumi.azurenative.network.enums.RouteNextHopType;
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.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * Route resource.
 * 
 */
public final class RouteArgs extends com.pulumi.resources.ResourceArgs {

    public static final RouteArgs Empty = new RouteArgs();

    /**
     * The destination CIDR to which the route applies.
     * 
     */
    @Import(name="addressPrefix")
    private @Nullable Output addressPrefix;

    /**
     * @return The destination CIDR to which the route applies.
     * 
     */
    public Optional> addressPrefix() {
        return Optional.ofNullable(this.addressPrefix);
    }

    /**
     * A unique read-only string that changes whenever the resource is updated.
     * 
     */
    @Import(name="etag")
    private @Nullable Output etag;

    /**
     * @return A unique read-only string that changes whenever the resource is updated.
     * 
     */
    public Optional> etag() {
        return Optional.ofNullable(this.etag);
    }

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

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

    /**
     * The name of the resource that is unique within a resource group. This name can be used to access the resource.
     * 
     */
    @Import(name="name")
    private @Nullable Output name;

    /**
     * @return The name of the resource that is unique within a resource group. This name can be used to access the resource.
     * 
     */
    public Optional> name() {
        return Optional.ofNullable(this.name);
    }

    /**
     * The IP address packets should be forwarded to. Next hop values are only allowed in routes where the next hop type is VirtualAppliance.
     * 
     */
    @Import(name="nextHopIpAddress")
    private @Nullable Output nextHopIpAddress;

    /**
     * @return The IP address packets should be forwarded to. Next hop values are only allowed in routes where the next hop type is VirtualAppliance.
     * 
     */
    public Optional> nextHopIpAddress() {
        return Optional.ofNullable(this.nextHopIpAddress);
    }

    /**
     * The type of Azure hop the packet should be sent to.
     * 
     */
    @Import(name="nextHopType", required=true)
    private Output> nextHopType;

    /**
     * @return The type of Azure hop the packet should be sent to.
     * 
     */
    public Output> nextHopType() {
        return this.nextHopType;
    }

    /**
     * The provisioning state of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
     * 
     */
    @Import(name="provisioningState")
    private @Nullable Output provisioningState;

    /**
     * @return The provisioning state of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
     * 
     */
    public Optional> provisioningState() {
        return Optional.ofNullable(this.provisioningState);
    }

    /**
     * The type of the resource.
     * 
     */
    @Import(name="type")
    private @Nullable Output type;

    /**
     * @return The type of the resource.
     * 
     */
    public Optional> type() {
        return Optional.ofNullable(this.type);
    }

    private RouteArgs() {}

    private RouteArgs(RouteArgs $) {
        this.addressPrefix = $.addressPrefix;
        this.etag = $.etag;
        this.id = $.id;
        this.name = $.name;
        this.nextHopIpAddress = $.nextHopIpAddress;
        this.nextHopType = $.nextHopType;
        this.provisioningState = $.provisioningState;
        this.type = $.type;
    }

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

    public static final class Builder {
        private RouteArgs $;

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

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

        /**
         * @param addressPrefix The destination CIDR to which the route applies.
         * 
         * @return builder
         * 
         */
        public Builder addressPrefix(@Nullable Output addressPrefix) {
            $.addressPrefix = addressPrefix;
            return this;
        }

        /**
         * @param addressPrefix The destination CIDR to which the route applies.
         * 
         * @return builder
         * 
         */
        public Builder addressPrefix(String addressPrefix) {
            return addressPrefix(Output.of(addressPrefix));
        }

        /**
         * @param etag A unique read-only string that changes whenever the resource is updated.
         * 
         * @return builder
         * 
         */
        public Builder etag(@Nullable Output etag) {
            $.etag = etag;
            return this;
        }

        /**
         * @param etag A unique read-only string that changes whenever the resource is updated.
         * 
         * @return builder
         * 
         */
        public Builder etag(String etag) {
            return etag(Output.of(etag));
        }

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

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

        /**
         * @param name The name of the resource that is unique within a resource group. This name can be used to access the resource.
         * 
         * @return builder
         * 
         */
        public Builder name(@Nullable Output name) {
            $.name = name;
            return this;
        }

        /**
         * @param name The name of the resource that is unique within a resource group. This name can be used to access the resource.
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param nextHopIpAddress The IP address packets should be forwarded to. Next hop values are only allowed in routes where the next hop type is VirtualAppliance.
         * 
         * @return builder
         * 
         */
        public Builder nextHopIpAddress(@Nullable Output nextHopIpAddress) {
            $.nextHopIpAddress = nextHopIpAddress;
            return this;
        }

        /**
         * @param nextHopIpAddress The IP address packets should be forwarded to. Next hop values are only allowed in routes where the next hop type is VirtualAppliance.
         * 
         * @return builder
         * 
         */
        public Builder nextHopIpAddress(String nextHopIpAddress) {
            return nextHopIpAddress(Output.of(nextHopIpAddress));
        }

        /**
         * @param nextHopType The type of Azure hop the packet should be sent to.
         * 
         * @return builder
         * 
         */
        public Builder nextHopType(Output> nextHopType) {
            $.nextHopType = nextHopType;
            return this;
        }

        /**
         * @param nextHopType The type of Azure hop the packet should be sent to.
         * 
         * @return builder
         * 
         */
        public Builder nextHopType(Either nextHopType) {
            return nextHopType(Output.of(nextHopType));
        }

        /**
         * @param nextHopType The type of Azure hop the packet should be sent to.
         * 
         * @return builder
         * 
         */
        public Builder nextHopType(String nextHopType) {
            return nextHopType(Either.ofLeft(nextHopType));
        }

        /**
         * @param nextHopType The type of Azure hop the packet should be sent to.
         * 
         * @return builder
         * 
         */
        public Builder nextHopType(RouteNextHopType nextHopType) {
            return nextHopType(Either.ofRight(nextHopType));
        }

        /**
         * @param provisioningState The provisioning state of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
         * 
         * @return builder
         * 
         */
        public Builder provisioningState(@Nullable Output provisioningState) {
            $.provisioningState = provisioningState;
            return this;
        }

        /**
         * @param provisioningState The provisioning state of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
         * 
         * @return builder
         * 
         */
        public Builder provisioningState(String provisioningState) {
            return provisioningState(Output.of(provisioningState));
        }

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

        /**
         * @param type The type of the resource.
         * 
         * @return builder
         * 
         */
        public Builder type(String type) {
            return type(Output.of(type));
        }

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

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy