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

com.pulumi.azure.network.outputs.RouteTableRoute Maven / Gradle / Ivy

// *** 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.azure.network.outputs;

import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;

@CustomType
public final class RouteTableRoute {
    /**
     * @return The destination to which the route applies. Can be CIDR (such as `10.1.0.0/16`) or [Azure Service Tag](https://docs.microsoft.com/azure/virtual-network/service-tags-overview) (such as `ApiManagement`, `AzureBackup` or `AzureMonitor`) format.
     * 
     */
    private String addressPrefix;
    /**
     * @return The name of the route.
     * 
     */
    private String name;
    /**
     * @return Contains the IP address packets should be forwarded to. Next hop values are only allowed in routes where the next hop type is `VirtualAppliance`.
     * 
     */
    private @Nullable String nextHopInIpAddress;
    /**
     * @return The type of Azure hop the packet should be sent to. Possible values are `VirtualNetworkGateway`, `VnetLocal`, `Internet`, `VirtualAppliance` and `None`.
     * 
     */
    private String nextHopType;

    private RouteTableRoute() {}
    /**
     * @return The destination to which the route applies. Can be CIDR (such as `10.1.0.0/16`) or [Azure Service Tag](https://docs.microsoft.com/azure/virtual-network/service-tags-overview) (such as `ApiManagement`, `AzureBackup` or `AzureMonitor`) format.
     * 
     */
    public String addressPrefix() {
        return this.addressPrefix;
    }
    /**
     * @return The name of the route.
     * 
     */
    public String name() {
        return this.name;
    }
    /**
     * @return Contains 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 nextHopInIpAddress() {
        return Optional.ofNullable(this.nextHopInIpAddress);
    }
    /**
     * @return The type of Azure hop the packet should be sent to. Possible values are `VirtualNetworkGateway`, `VnetLocal`, `Internet`, `VirtualAppliance` and `None`.
     * 
     */
    public String nextHopType() {
        return this.nextHopType;
    }

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

    public static Builder builder(RouteTableRoute defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private String addressPrefix;
        private String name;
        private @Nullable String nextHopInIpAddress;
        private String nextHopType;
        public Builder() {}
        public Builder(RouteTableRoute defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.addressPrefix = defaults.addressPrefix;
    	      this.name = defaults.name;
    	      this.nextHopInIpAddress = defaults.nextHopInIpAddress;
    	      this.nextHopType = defaults.nextHopType;
        }

        @CustomType.Setter
        public Builder addressPrefix(String addressPrefix) {
            if (addressPrefix == null) {
              throw new MissingRequiredPropertyException("RouteTableRoute", "addressPrefix");
            }
            this.addressPrefix = addressPrefix;
            return this;
        }
        @CustomType.Setter
        public Builder name(String name) {
            if (name == null) {
              throw new MissingRequiredPropertyException("RouteTableRoute", "name");
            }
            this.name = name;
            return this;
        }
        @CustomType.Setter
        public Builder nextHopInIpAddress(@Nullable String nextHopInIpAddress) {

            this.nextHopInIpAddress = nextHopInIpAddress;
            return this;
        }
        @CustomType.Setter
        public Builder nextHopType(String nextHopType) {
            if (nextHopType == null) {
              throw new MissingRequiredPropertyException("RouteTableRoute", "nextHopType");
            }
            this.nextHopType = nextHopType;
            return this;
        }
        public RouteTableRoute build() {
            final var _resultValue = new RouteTableRoute();
            _resultValue.addressPrefix = addressPrefix;
            _resultValue.name = name;
            _resultValue.nextHopInIpAddress = nextHopInIpAddress;
            _resultValue.nextHopType = nextHopType;
            return _resultValue;
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy