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

com.pulumi.azurenative.datafactory.inputs.ChainingTriggerArgs Maven / Gradle / Ivy

There is a newer version: 2.72.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.datafactory.inputs;

import com.pulumi.azurenative.datafactory.inputs.PipelineReferenceArgs;
import com.pulumi.azurenative.datafactory.inputs.TriggerPipelineReferenceArgs;
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.Object;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * Trigger that allows the referenced pipeline to depend on other pipeline runs based on runDimension Name/Value pairs. Upstream pipelines should declare the same runDimension Name and their runs should have the values for those runDimensions. The referenced pipeline run would be triggered if the values for the runDimension match for all upstream pipeline runs.
 * 
 */
public final class ChainingTriggerArgs extends com.pulumi.resources.ResourceArgs {

    public static final ChainingTriggerArgs Empty = new ChainingTriggerArgs();

    /**
     * List of tags that can be used for describing the trigger.
     * 
     */
    @Import(name="annotations")
    private @Nullable Output> annotations;

    /**
     * @return List of tags that can be used for describing the trigger.
     * 
     */
    public Optional>> annotations() {
        return Optional.ofNullable(this.annotations);
    }

    /**
     * Upstream Pipelines.
     * 
     */
    @Import(name="dependsOn", required=true)
    private Output> dependsOn;

    /**
     * @return Upstream Pipelines.
     * 
     */
    public Output> dependsOn() {
        return this.dependsOn;
    }

    /**
     * Trigger description.
     * 
     */
    @Import(name="description")
    private @Nullable Output description;

    /**
     * @return Trigger description.
     * 
     */
    public Optional> description() {
        return Optional.ofNullable(this.description);
    }

    /**
     * Pipeline for which runs are created when all upstream pipelines complete successfully.
     * 
     */
    @Import(name="pipeline", required=true)
    private Output pipeline;

    /**
     * @return Pipeline for which runs are created when all upstream pipelines complete successfully.
     * 
     */
    public Output pipeline() {
        return this.pipeline;
    }

    /**
     * Run Dimension property that needs to be emitted by upstream pipelines.
     * 
     */
    @Import(name="runDimension", required=true)
    private Output runDimension;

    /**
     * @return Run Dimension property that needs to be emitted by upstream pipelines.
     * 
     */
    public Output runDimension() {
        return this.runDimension;
    }

    /**
     * Trigger type.
     * Expected value is 'ChainingTrigger'.
     * 
     */
    @Import(name="type", required=true)
    private Output type;

    /**
     * @return Trigger type.
     * Expected value is 'ChainingTrigger'.
     * 
     */
    public Output type() {
        return this.type;
    }

    private ChainingTriggerArgs() {}

    private ChainingTriggerArgs(ChainingTriggerArgs $) {
        this.annotations = $.annotations;
        this.dependsOn = $.dependsOn;
        this.description = $.description;
        this.pipeline = $.pipeline;
        this.runDimension = $.runDimension;
        this.type = $.type;
    }

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

    public static final class Builder {
        private ChainingTriggerArgs $;

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

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

        /**
         * @param annotations List of tags that can be used for describing the trigger.
         * 
         * @return builder
         * 
         */
        public Builder annotations(@Nullable Output> annotations) {
            $.annotations = annotations;
            return this;
        }

        /**
         * @param annotations List of tags that can be used for describing the trigger.
         * 
         * @return builder
         * 
         */
        public Builder annotations(List annotations) {
            return annotations(Output.of(annotations));
        }

        /**
         * @param annotations List of tags that can be used for describing the trigger.
         * 
         * @return builder
         * 
         */
        public Builder annotations(Object... annotations) {
            return annotations(List.of(annotations));
        }

        /**
         * @param dependsOn Upstream Pipelines.
         * 
         * @return builder
         * 
         */
        public Builder dependsOn(Output> dependsOn) {
            $.dependsOn = dependsOn;
            return this;
        }

        /**
         * @param dependsOn Upstream Pipelines.
         * 
         * @return builder
         * 
         */
        public Builder dependsOn(List dependsOn) {
            return dependsOn(Output.of(dependsOn));
        }

        /**
         * @param dependsOn Upstream Pipelines.
         * 
         * @return builder
         * 
         */
        public Builder dependsOn(PipelineReferenceArgs... dependsOn) {
            return dependsOn(List.of(dependsOn));
        }

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

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

        /**
         * @param pipeline Pipeline for which runs are created when all upstream pipelines complete successfully.
         * 
         * @return builder
         * 
         */
        public Builder pipeline(Output pipeline) {
            $.pipeline = pipeline;
            return this;
        }

        /**
         * @param pipeline Pipeline for which runs are created when all upstream pipelines complete successfully.
         * 
         * @return builder
         * 
         */
        public Builder pipeline(TriggerPipelineReferenceArgs pipeline) {
            return pipeline(Output.of(pipeline));
        }

        /**
         * @param runDimension Run Dimension property that needs to be emitted by upstream pipelines.
         * 
         * @return builder
         * 
         */
        public Builder runDimension(Output runDimension) {
            $.runDimension = runDimension;
            return this;
        }

        /**
         * @param runDimension Run Dimension property that needs to be emitted by upstream pipelines.
         * 
         * @return builder
         * 
         */
        public Builder runDimension(String runDimension) {
            return runDimension(Output.of(runDimension));
        }

        /**
         * @param type Trigger type.
         * Expected value is 'ChainingTrigger'.
         * 
         * @return builder
         * 
         */
        public Builder type(Output type) {
            $.type = type;
            return this;
        }

        /**
         * @param type Trigger type.
         * Expected value is 'ChainingTrigger'.
         * 
         * @return builder
         * 
         */
        public Builder type(String type) {
            return type(Output.of(type));
        }

        public ChainingTriggerArgs build() {
            if ($.dependsOn == null) {
                throw new MissingRequiredPropertyException("ChainingTriggerArgs", "dependsOn");
            }
            if ($.pipeline == null) {
                throw new MissingRequiredPropertyException("ChainingTriggerArgs", "pipeline");
            }
            if ($.runDimension == null) {
                throw new MissingRequiredPropertyException("ChainingTriggerArgs", "runDimension");
            }
            $.type = Codegen.stringProp("type").output().arg($.type).require();
            return $;
        }
    }

}