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

com.pulumi.azurenative.network.inputs.ActionArgs 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.RouteMapActionType;
import com.pulumi.azurenative.network.inputs.ParameterArgs;
import com.pulumi.core.Either;
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;


/**
 * Action to be taken on a route matching a RouteMap criterion.
 * 
 */
public final class ActionArgs extends com.pulumi.resources.ResourceArgs {

    public static final ActionArgs Empty = new ActionArgs();

    /**
     * List of parameters relevant to the action.For instance if type is drop then parameters has list of prefixes to be dropped.If type is add, parameters would have list of ASN numbers to be added
     * 
     */
    @Import(name="parameters")
    private @Nullable Output> parameters;

    /**
     * @return List of parameters relevant to the action.For instance if type is drop then parameters has list of prefixes to be dropped.If type is add, parameters would have list of ASN numbers to be added
     * 
     */
    public Optional>> parameters() {
        return Optional.ofNullable(this.parameters);
    }

    /**
     * Type of action to be taken. Supported types are 'Remove', 'Add', 'Replace', and 'Drop.'
     * 
     */
    @Import(name="type")
    private @Nullable Output> type;

    /**
     * @return Type of action to be taken. Supported types are 'Remove', 'Add', 'Replace', and 'Drop.'
     * 
     */
    public Optional>> type() {
        return Optional.ofNullable(this.type);
    }

    private ActionArgs() {}

    private ActionArgs(ActionArgs $) {
        this.parameters = $.parameters;
        this.type = $.type;
    }

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

    public static final class Builder {
        private ActionArgs $;

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

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

        /**
         * @param parameters List of parameters relevant to the action.For instance if type is drop then parameters has list of prefixes to be dropped.If type is add, parameters would have list of ASN numbers to be added
         * 
         * @return builder
         * 
         */
        public Builder parameters(@Nullable Output> parameters) {
            $.parameters = parameters;
            return this;
        }

        /**
         * @param parameters List of parameters relevant to the action.For instance if type is drop then parameters has list of prefixes to be dropped.If type is add, parameters would have list of ASN numbers to be added
         * 
         * @return builder
         * 
         */
        public Builder parameters(List parameters) {
            return parameters(Output.of(parameters));
        }

        /**
         * @param parameters List of parameters relevant to the action.For instance if type is drop then parameters has list of prefixes to be dropped.If type is add, parameters would have list of ASN numbers to be added
         * 
         * @return builder
         * 
         */
        public Builder parameters(ParameterArgs... parameters) {
            return parameters(List.of(parameters));
        }

        /**
         * @param type Type of action to be taken. Supported types are 'Remove', 'Add', 'Replace', and 'Drop.'
         * 
         * @return builder
         * 
         */
        public Builder type(@Nullable Output> type) {
            $.type = type;
            return this;
        }

        /**
         * @param type Type of action to be taken. Supported types are 'Remove', 'Add', 'Replace', and 'Drop.'
         * 
         * @return builder
         * 
         */
        public Builder type(Either type) {
            return type(Output.of(type));
        }

        /**
         * @param type Type of action to be taken. Supported types are 'Remove', 'Add', 'Replace', and 'Drop.'
         * 
         * @return builder
         * 
         */
        public Builder type(String type) {
            return type(Either.ofLeft(type));
        }

        /**
         * @param type Type of action to be taken. Supported types are 'Remove', 'Add', 'Replace', and 'Drop.'
         * 
         * @return builder
         * 
         */
        public Builder type(RouteMapActionType type) {
            return type(Either.ofRight(type));
        }

        public ActionArgs build() {
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy