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

com.pulumi.kubernetes.networking.v1.inputs.IPBlockPatchArgs Maven / Gradle / Ivy

There is a newer version: 4.19.0-alpha.1730750641
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.kubernetes.networking.v1.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * IPBlock describes a particular CIDR (Ex. "192.168.1.0/24","2001:db8::/64") that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The except entry describes CIDRs that should not be included within this rule.
 * 
 */
public final class IPBlockPatchArgs extends com.pulumi.resources.ResourceArgs {

    public static final IPBlockPatchArgs Empty = new IPBlockPatchArgs();

    /**
     * cidr is a string representing the IPBlock Valid examples are "192.168.1.0/24" or "2001:db8::/64"
     * 
     */
    @Import(name="cidr")
    private @Nullable Output cidr;

    /**
     * @return cidr is a string representing the IPBlock Valid examples are "192.168.1.0/24" or "2001:db8::/64"
     * 
     */
    public Optional> cidr() {
        return Optional.ofNullable(this.cidr);
    }

    /**
     * except is a slice of CIDRs that should not be included within an IPBlock Valid examples are "192.168.1.0/24" or "2001:db8::/64" Except values will be rejected if they are outside the cidr range
     * 
     */
    @Import(name="except")
    private @Nullable Output> except;

    /**
     * @return except is a slice of CIDRs that should not be included within an IPBlock Valid examples are "192.168.1.0/24" or "2001:db8::/64" Except values will be rejected if they are outside the cidr range
     * 
     */
    public Optional>> except() {
        return Optional.ofNullable(this.except);
    }

    private IPBlockPatchArgs() {}

    private IPBlockPatchArgs(IPBlockPatchArgs $) {
        this.cidr = $.cidr;
        this.except = $.except;
    }

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

    public static final class Builder {
        private IPBlockPatchArgs $;

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

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

        /**
         * @param cidr cidr is a string representing the IPBlock Valid examples are "192.168.1.0/24" or "2001:db8::/64"
         * 
         * @return builder
         * 
         */
        public Builder cidr(@Nullable Output cidr) {
            $.cidr = cidr;
            return this;
        }

        /**
         * @param cidr cidr is a string representing the IPBlock Valid examples are "192.168.1.0/24" or "2001:db8::/64"
         * 
         * @return builder
         * 
         */
        public Builder cidr(String cidr) {
            return cidr(Output.of(cidr));
        }

        /**
         * @param except except is a slice of CIDRs that should not be included within an IPBlock Valid examples are "192.168.1.0/24" or "2001:db8::/64" Except values will be rejected if they are outside the cidr range
         * 
         * @return builder
         * 
         */
        public Builder except(@Nullable Output> except) {
            $.except = except;
            return this;
        }

        /**
         * @param except except is a slice of CIDRs that should not be included within an IPBlock Valid examples are "192.168.1.0/24" or "2001:db8::/64" Except values will be rejected if they are outside the cidr range
         * 
         * @return builder
         * 
         */
        public Builder except(List except) {
            return except(Output.of(except));
        }

        /**
         * @param except except is a slice of CIDRs that should not be included within an IPBlock Valid examples are "192.168.1.0/24" or "2001:db8::/64" Except values will be rejected if they are outside the cidr range
         * 
         * @return builder
         * 
         */
        public Builder except(String... except) {
            return except(List.of(except));
        }

        public IPBlockPatchArgs build() {
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy