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

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

import com.pulumi.azurenative.network.inputs.AddressSpaceArgs;
import com.pulumi.azurenative.network.inputs.DhcpOptionsArgs;
import com.pulumi.azurenative.network.inputs.ExtendedLocationArgs;
import com.pulumi.azurenative.network.inputs.SubResourceArgs;
import com.pulumi.azurenative.network.inputs.SubnetArgs;
import com.pulumi.azurenative.network.inputs.VirtualNetworkBgpCommunitiesArgs;
import com.pulumi.azurenative.network.inputs.VirtualNetworkEncryptionArgs;
import com.pulumi.azurenative.network.inputs.VirtualNetworkPeeringArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.core.internal.Codegen;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Boolean;
import java.lang.Integer;
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 VirtualNetworkArgs extends com.pulumi.resources.ResourceArgs {

    public static final VirtualNetworkArgs Empty = new VirtualNetworkArgs();

    /**
     * The AddressSpace that contains an array of IP address ranges that can be used by subnets.
     * 
     */
    @Import(name="addressSpace")
    private @Nullable Output addressSpace;

    /**
     * @return The AddressSpace that contains an array of IP address ranges that can be used by subnets.
     * 
     */
    public Optional> addressSpace() {
        return Optional.ofNullable(this.addressSpace);
    }

    /**
     * Bgp Communities sent over ExpressRoute with each route corresponding to a prefix in this VNET.
     * 
     */
    @Import(name="bgpCommunities")
    private @Nullable Output bgpCommunities;

    /**
     * @return Bgp Communities sent over ExpressRoute with each route corresponding to a prefix in this VNET.
     * 
     */
    public Optional> bgpCommunities() {
        return Optional.ofNullable(this.bgpCommunities);
    }

    /**
     * The DDoS protection plan associated with the virtual network.
     * 
     */
    @Import(name="ddosProtectionPlan")
    private @Nullable Output ddosProtectionPlan;

    /**
     * @return The DDoS protection plan associated with the virtual network.
     * 
     */
    public Optional> ddosProtectionPlan() {
        return Optional.ofNullable(this.ddosProtectionPlan);
    }

    /**
     * The dhcpOptions that contains an array of DNS servers available to VMs deployed in the virtual network.
     * 
     */
    @Import(name="dhcpOptions")
    private @Nullable Output dhcpOptions;

    /**
     * @return The dhcpOptions that contains an array of DNS servers available to VMs deployed in the virtual network.
     * 
     */
    public Optional> dhcpOptions() {
        return Optional.ofNullable(this.dhcpOptions);
    }

    /**
     * Indicates if DDoS protection is enabled for all the protected resources in the virtual network. It requires a DDoS protection plan associated with the resource.
     * 
     */
    @Import(name="enableDdosProtection")
    private @Nullable Output enableDdosProtection;

    /**
     * @return Indicates if DDoS protection is enabled for all the protected resources in the virtual network. It requires a DDoS protection plan associated with the resource.
     * 
     */
    public Optional> enableDdosProtection() {
        return Optional.ofNullable(this.enableDdosProtection);
    }

    /**
     * Indicates if VM protection is enabled for all the subnets in the virtual network.
     * 
     */
    @Import(name="enableVmProtection")
    private @Nullable Output enableVmProtection;

    /**
     * @return Indicates if VM protection is enabled for all the subnets in the virtual network.
     * 
     */
    public Optional> enableVmProtection() {
        return Optional.ofNullable(this.enableVmProtection);
    }

    /**
     * Indicates if encryption is enabled on virtual network and if VM without encryption is allowed in encrypted VNet.
     * 
     */
    @Import(name="encryption")
    private @Nullable Output encryption;

    /**
     * @return Indicates if encryption is enabled on virtual network and if VM without encryption is allowed in encrypted VNet.
     * 
     */
    public Optional> encryption() {
        return Optional.ofNullable(this.encryption);
    }

    /**
     * The extended location of the virtual network.
     * 
     */
    @Import(name="extendedLocation")
    private @Nullable Output extendedLocation;

    /**
     * @return The extended location of the virtual network.
     * 
     */
    public Optional> extendedLocation() {
        return Optional.ofNullable(this.extendedLocation);
    }

    /**
     * The FlowTimeout value (in minutes) for the Virtual Network
     * 
     */
    @Import(name="flowTimeoutInMinutes")
    private @Nullable Output flowTimeoutInMinutes;

    /**
     * @return The FlowTimeout value (in minutes) for the Virtual Network
     * 
     */
    public Optional> flowTimeoutInMinutes() {
        return Optional.ofNullable(this.flowTimeoutInMinutes);
    }

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

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

    /**
     * Array of IpAllocation which reference this VNET.
     * 
     */
    @Import(name="ipAllocations")
    private @Nullable Output> ipAllocations;

    /**
     * @return Array of IpAllocation which reference this VNET.
     * 
     */
    public Optional>> ipAllocations() {
        return Optional.ofNullable(this.ipAllocations);
    }

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

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

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

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

    /**
     * A list of subnets in a Virtual Network.
     * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
     * 
     */
    @Import(name="subnets")
    private @Nullable Output> subnets;

    /**
     * @return A list of subnets in a Virtual Network.
     * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
     * 
     */
    public Optional>> subnets() {
        return Optional.ofNullable(this.subnets);
    }

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

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

    /**
     * The name of the virtual network.
     * 
     */
    @Import(name="virtualNetworkName")
    private @Nullable Output virtualNetworkName;

    /**
     * @return The name of the virtual network.
     * 
     */
    public Optional> virtualNetworkName() {
        return Optional.ofNullable(this.virtualNetworkName);
    }

    /**
     * A list of peerings in a Virtual Network.
     * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
     * 
     */
    @Import(name="virtualNetworkPeerings")
    private @Nullable Output> virtualNetworkPeerings;

    /**
     * @return A list of peerings in a Virtual Network.
     * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
     * 
     */
    public Optional>> virtualNetworkPeerings() {
        return Optional.ofNullable(this.virtualNetworkPeerings);
    }

    private VirtualNetworkArgs() {}

    private VirtualNetworkArgs(VirtualNetworkArgs $) {
        this.addressSpace = $.addressSpace;
        this.bgpCommunities = $.bgpCommunities;
        this.ddosProtectionPlan = $.ddosProtectionPlan;
        this.dhcpOptions = $.dhcpOptions;
        this.enableDdosProtection = $.enableDdosProtection;
        this.enableVmProtection = $.enableVmProtection;
        this.encryption = $.encryption;
        this.extendedLocation = $.extendedLocation;
        this.flowTimeoutInMinutes = $.flowTimeoutInMinutes;
        this.id = $.id;
        this.ipAllocations = $.ipAllocations;
        this.location = $.location;
        this.resourceGroupName = $.resourceGroupName;
        this.subnets = $.subnets;
        this.tags = $.tags;
        this.virtualNetworkName = $.virtualNetworkName;
        this.virtualNetworkPeerings = $.virtualNetworkPeerings;
    }

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

    public static final class Builder {
        private VirtualNetworkArgs $;

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

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

        /**
         * @param addressSpace The AddressSpace that contains an array of IP address ranges that can be used by subnets.
         * 
         * @return builder
         * 
         */
        public Builder addressSpace(@Nullable Output addressSpace) {
            $.addressSpace = addressSpace;
            return this;
        }

        /**
         * @param addressSpace The AddressSpace that contains an array of IP address ranges that can be used by subnets.
         * 
         * @return builder
         * 
         */
        public Builder addressSpace(AddressSpaceArgs addressSpace) {
            return addressSpace(Output.of(addressSpace));
        }

        /**
         * @param bgpCommunities Bgp Communities sent over ExpressRoute with each route corresponding to a prefix in this VNET.
         * 
         * @return builder
         * 
         */
        public Builder bgpCommunities(@Nullable Output bgpCommunities) {
            $.bgpCommunities = bgpCommunities;
            return this;
        }

        /**
         * @param bgpCommunities Bgp Communities sent over ExpressRoute with each route corresponding to a prefix in this VNET.
         * 
         * @return builder
         * 
         */
        public Builder bgpCommunities(VirtualNetworkBgpCommunitiesArgs bgpCommunities) {
            return bgpCommunities(Output.of(bgpCommunities));
        }

        /**
         * @param ddosProtectionPlan The DDoS protection plan associated with the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder ddosProtectionPlan(@Nullable Output ddosProtectionPlan) {
            $.ddosProtectionPlan = ddosProtectionPlan;
            return this;
        }

        /**
         * @param ddosProtectionPlan The DDoS protection plan associated with the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder ddosProtectionPlan(SubResourceArgs ddosProtectionPlan) {
            return ddosProtectionPlan(Output.of(ddosProtectionPlan));
        }

        /**
         * @param dhcpOptions The dhcpOptions that contains an array of DNS servers available to VMs deployed in the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder dhcpOptions(@Nullable Output dhcpOptions) {
            $.dhcpOptions = dhcpOptions;
            return this;
        }

        /**
         * @param dhcpOptions The dhcpOptions that contains an array of DNS servers available to VMs deployed in the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder dhcpOptions(DhcpOptionsArgs dhcpOptions) {
            return dhcpOptions(Output.of(dhcpOptions));
        }

        /**
         * @param enableDdosProtection Indicates if DDoS protection is enabled for all the protected resources in the virtual network. It requires a DDoS protection plan associated with the resource.
         * 
         * @return builder
         * 
         */
        public Builder enableDdosProtection(@Nullable Output enableDdosProtection) {
            $.enableDdosProtection = enableDdosProtection;
            return this;
        }

        /**
         * @param enableDdosProtection Indicates if DDoS protection is enabled for all the protected resources in the virtual network. It requires a DDoS protection plan associated with the resource.
         * 
         * @return builder
         * 
         */
        public Builder enableDdosProtection(Boolean enableDdosProtection) {
            return enableDdosProtection(Output.of(enableDdosProtection));
        }

        /**
         * @param enableVmProtection Indicates if VM protection is enabled for all the subnets in the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder enableVmProtection(@Nullable Output enableVmProtection) {
            $.enableVmProtection = enableVmProtection;
            return this;
        }

        /**
         * @param enableVmProtection Indicates if VM protection is enabled for all the subnets in the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder enableVmProtection(Boolean enableVmProtection) {
            return enableVmProtection(Output.of(enableVmProtection));
        }

        /**
         * @param encryption Indicates if encryption is enabled on virtual network and if VM without encryption is allowed in encrypted VNet.
         * 
         * @return builder
         * 
         */
        public Builder encryption(@Nullable Output encryption) {
            $.encryption = encryption;
            return this;
        }

        /**
         * @param encryption Indicates if encryption is enabled on virtual network and if VM without encryption is allowed in encrypted VNet.
         * 
         * @return builder
         * 
         */
        public Builder encryption(VirtualNetworkEncryptionArgs encryption) {
            return encryption(Output.of(encryption));
        }

        /**
         * @param extendedLocation The extended location of the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder extendedLocation(@Nullable Output extendedLocation) {
            $.extendedLocation = extendedLocation;
            return this;
        }

        /**
         * @param extendedLocation The extended location of the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder extendedLocation(ExtendedLocationArgs extendedLocation) {
            return extendedLocation(Output.of(extendedLocation));
        }

        /**
         * @param flowTimeoutInMinutes The FlowTimeout value (in minutes) for the Virtual Network
         * 
         * @return builder
         * 
         */
        public Builder flowTimeoutInMinutes(@Nullable Output flowTimeoutInMinutes) {
            $.flowTimeoutInMinutes = flowTimeoutInMinutes;
            return this;
        }

        /**
         * @param flowTimeoutInMinutes The FlowTimeout value (in minutes) for the Virtual Network
         * 
         * @return builder
         * 
         */
        public Builder flowTimeoutInMinutes(Integer flowTimeoutInMinutes) {
            return flowTimeoutInMinutes(Output.of(flowTimeoutInMinutes));
        }

        /**
         * @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 ipAllocations Array of IpAllocation which reference this VNET.
         * 
         * @return builder
         * 
         */
        public Builder ipAllocations(@Nullable Output> ipAllocations) {
            $.ipAllocations = ipAllocations;
            return this;
        }

        /**
         * @param ipAllocations Array of IpAllocation which reference this VNET.
         * 
         * @return builder
         * 
         */
        public Builder ipAllocations(List ipAllocations) {
            return ipAllocations(Output.of(ipAllocations));
        }

        /**
         * @param ipAllocations Array of IpAllocation which reference this VNET.
         * 
         * @return builder
         * 
         */
        public Builder ipAllocations(SubResourceArgs... ipAllocations) {
            return ipAllocations(List.of(ipAllocations));
        }

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

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

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

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

        /**
         * @param subnets A list of subnets in a Virtual Network.
         * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
         * 
         * @return builder
         * 
         */
        public Builder subnets(@Nullable Output> subnets) {
            $.subnets = subnets;
            return this;
        }

        /**
         * @param subnets A list of subnets in a Virtual Network.
         * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
         * 
         * @return builder
         * 
         */
        public Builder subnets(List subnets) {
            return subnets(Output.of(subnets));
        }

        /**
         * @param subnets A list of subnets in a Virtual Network.
         * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
         * 
         * @return builder
         * 
         */
        public Builder subnets(SubnetArgs... subnets) {
            return subnets(List.of(subnets));
        }

        /**
         * @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 virtualNetworkName The name of the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder virtualNetworkName(@Nullable Output virtualNetworkName) {
            $.virtualNetworkName = virtualNetworkName;
            return this;
        }

        /**
         * @param virtualNetworkName The name of the virtual network.
         * 
         * @return builder
         * 
         */
        public Builder virtualNetworkName(String virtualNetworkName) {
            return virtualNetworkName(Output.of(virtualNetworkName));
        }

        /**
         * @param virtualNetworkPeerings A list of peerings in a Virtual Network.
         * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
         * 
         * @return builder
         * 
         */
        public Builder virtualNetworkPeerings(@Nullable Output> virtualNetworkPeerings) {
            $.virtualNetworkPeerings = virtualNetworkPeerings;
            return this;
        }

        /**
         * @param virtualNetworkPeerings A list of peerings in a Virtual Network.
         * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
         * 
         * @return builder
         * 
         */
        public Builder virtualNetworkPeerings(List virtualNetworkPeerings) {
            return virtualNetworkPeerings(Output.of(virtualNetworkPeerings));
        }

        /**
         * @param virtualNetworkPeerings A list of peerings in a Virtual Network.
         * These are also available as standalone resources. Do not mix inline and standalone resource as they will conflict with each other, leading to resources deletion.
         * 
         * @return builder
         * 
         */
        public Builder virtualNetworkPeerings(VirtualNetworkPeeringArgs... virtualNetworkPeerings) {
            return virtualNetworkPeerings(List.of(virtualNetworkPeerings));
        }

        public VirtualNetworkArgs build() {
            $.enableDdosProtection = Codegen.booleanProp("enableDdosProtection").output().arg($.enableDdosProtection).def(false).getNullable();
            $.enableVmProtection = Codegen.booleanProp("enableVmProtection").output().arg($.enableVmProtection).def(false).getNullable();
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("VirtualNetworkArgs", "resourceGroupName");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy