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

com.pulumi.azurenative.kusto.ScriptArgs 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.kusto;

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.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class ScriptArgs extends com.pulumi.resources.ResourceArgs {

    public static final ScriptArgs Empty = new ScriptArgs();

    /**
     * The name of the Kusto cluster.
     * 
     */
    @Import(name="clusterName", required=true)
    private Output clusterName;

    /**
     * @return The name of the Kusto cluster.
     * 
     */
    public Output clusterName() {
        return this.clusterName;
    }

    /**
     * Flag that indicates whether to continue if one of the command fails.
     * 
     */
    @Import(name="continueOnErrors")
    private @Nullable Output continueOnErrors;

    /**
     * @return Flag that indicates whether to continue if one of the command fails.
     * 
     */
    public Optional> continueOnErrors() {
        return Optional.ofNullable(this.continueOnErrors);
    }

    /**
     * The name of the database in the Kusto cluster.
     * 
     */
    @Import(name="databaseName", required=true)
    private Output databaseName;

    /**
     * @return The name of the database in the Kusto cluster.
     * 
     */
    public Output databaseName() {
        return this.databaseName;
    }

    /**
     * A unique string. If changed the script will be applied again.
     * 
     */
    @Import(name="forceUpdateTag")
    private @Nullable Output forceUpdateTag;

    /**
     * @return A unique string. If changed the script will be applied again.
     * 
     */
    public Optional> forceUpdateTag() {
        return Optional.ofNullable(this.forceUpdateTag);
    }

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

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

    /**
     * The script content. This property should be used when the script is provide inline and not through file in a SA. Must not be used together with scriptUrl and scriptUrlSasToken properties.
     * 
     */
    @Import(name="scriptContent")
    private @Nullable Output scriptContent;

    /**
     * @return The script content. This property should be used when the script is provide inline and not through file in a SA. Must not be used together with scriptUrl and scriptUrlSasToken properties.
     * 
     */
    public Optional> scriptContent() {
        return Optional.ofNullable(this.scriptContent);
    }

    /**
     * The name of the Kusto database script.
     * 
     */
    @Import(name="scriptName")
    private @Nullable Output scriptName;

    /**
     * @return The name of the Kusto database script.
     * 
     */
    public Optional> scriptName() {
        return Optional.ofNullable(this.scriptName);
    }

    /**
     * The url to the KQL script blob file. Must not be used together with scriptContent property
     * 
     */
    @Import(name="scriptUrl")
    private @Nullable Output scriptUrl;

    /**
     * @return The url to the KQL script blob file. Must not be used together with scriptContent property
     * 
     */
    public Optional> scriptUrl() {
        return Optional.ofNullable(this.scriptUrl);
    }

    /**
     * The SaS token that provide read access to the file which contain the script. Must be provided when using scriptUrl property.
     * 
     */
    @Import(name="scriptUrlSasToken")
    private @Nullable Output scriptUrlSasToken;

    /**
     * @return The SaS token that provide read access to the file which contain the script. Must be provided when using scriptUrl property.
     * 
     */
    public Optional> scriptUrlSasToken() {
        return Optional.ofNullable(this.scriptUrlSasToken);
    }

    private ScriptArgs() {}

    private ScriptArgs(ScriptArgs $) {
        this.clusterName = $.clusterName;
        this.continueOnErrors = $.continueOnErrors;
        this.databaseName = $.databaseName;
        this.forceUpdateTag = $.forceUpdateTag;
        this.resourceGroupName = $.resourceGroupName;
        this.scriptContent = $.scriptContent;
        this.scriptName = $.scriptName;
        this.scriptUrl = $.scriptUrl;
        this.scriptUrlSasToken = $.scriptUrlSasToken;
    }

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

    public static final class Builder {
        private ScriptArgs $;

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

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

        /**
         * @param clusterName The name of the Kusto cluster.
         * 
         * @return builder
         * 
         */
        public Builder clusterName(Output clusterName) {
            $.clusterName = clusterName;
            return this;
        }

        /**
         * @param clusterName The name of the Kusto cluster.
         * 
         * @return builder
         * 
         */
        public Builder clusterName(String clusterName) {
            return clusterName(Output.of(clusterName));
        }

        /**
         * @param continueOnErrors Flag that indicates whether to continue if one of the command fails.
         * 
         * @return builder
         * 
         */
        public Builder continueOnErrors(@Nullable Output continueOnErrors) {
            $.continueOnErrors = continueOnErrors;
            return this;
        }

        /**
         * @param continueOnErrors Flag that indicates whether to continue if one of the command fails.
         * 
         * @return builder
         * 
         */
        public Builder continueOnErrors(Boolean continueOnErrors) {
            return continueOnErrors(Output.of(continueOnErrors));
        }

        /**
         * @param databaseName The name of the database in the Kusto cluster.
         * 
         * @return builder
         * 
         */
        public Builder databaseName(Output databaseName) {
            $.databaseName = databaseName;
            return this;
        }

        /**
         * @param databaseName The name of the database in the Kusto cluster.
         * 
         * @return builder
         * 
         */
        public Builder databaseName(String databaseName) {
            return databaseName(Output.of(databaseName));
        }

        /**
         * @param forceUpdateTag A unique string. If changed the script will be applied again.
         * 
         * @return builder
         * 
         */
        public Builder forceUpdateTag(@Nullable Output forceUpdateTag) {
            $.forceUpdateTag = forceUpdateTag;
            return this;
        }

        /**
         * @param forceUpdateTag A unique string. If changed the script will be applied again.
         * 
         * @return builder
         * 
         */
        public Builder forceUpdateTag(String forceUpdateTag) {
            return forceUpdateTag(Output.of(forceUpdateTag));
        }

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

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

        /**
         * @param scriptContent The script content. This property should be used when the script is provide inline and not through file in a SA. Must not be used together with scriptUrl and scriptUrlSasToken properties.
         * 
         * @return builder
         * 
         */
        public Builder scriptContent(@Nullable Output scriptContent) {
            $.scriptContent = scriptContent;
            return this;
        }

        /**
         * @param scriptContent The script content. This property should be used when the script is provide inline and not through file in a SA. Must not be used together with scriptUrl and scriptUrlSasToken properties.
         * 
         * @return builder
         * 
         */
        public Builder scriptContent(String scriptContent) {
            return scriptContent(Output.of(scriptContent));
        }

        /**
         * @param scriptName The name of the Kusto database script.
         * 
         * @return builder
         * 
         */
        public Builder scriptName(@Nullable Output scriptName) {
            $.scriptName = scriptName;
            return this;
        }

        /**
         * @param scriptName The name of the Kusto database script.
         * 
         * @return builder
         * 
         */
        public Builder scriptName(String scriptName) {
            return scriptName(Output.of(scriptName));
        }

        /**
         * @param scriptUrl The url to the KQL script blob file. Must not be used together with scriptContent property
         * 
         * @return builder
         * 
         */
        public Builder scriptUrl(@Nullable Output scriptUrl) {
            $.scriptUrl = scriptUrl;
            return this;
        }

        /**
         * @param scriptUrl The url to the KQL script blob file. Must not be used together with scriptContent property
         * 
         * @return builder
         * 
         */
        public Builder scriptUrl(String scriptUrl) {
            return scriptUrl(Output.of(scriptUrl));
        }

        /**
         * @param scriptUrlSasToken The SaS token that provide read access to the file which contain the script. Must be provided when using scriptUrl property.
         * 
         * @return builder
         * 
         */
        public Builder scriptUrlSasToken(@Nullable Output scriptUrlSasToken) {
            $.scriptUrlSasToken = scriptUrlSasToken;
            return this;
        }

        /**
         * @param scriptUrlSasToken The SaS token that provide read access to the file which contain the script. Must be provided when using scriptUrl property.
         * 
         * @return builder
         * 
         */
        public Builder scriptUrlSasToken(String scriptUrlSasToken) {
            return scriptUrlSasToken(Output.of(scriptUrlSasToken));
        }

        public ScriptArgs build() {
            if ($.clusterName == null) {
                throw new MissingRequiredPropertyException("ScriptArgs", "clusterName");
            }
            $.continueOnErrors = Codegen.booleanProp("continueOnErrors").output().arg($.continueOnErrors).def(false).getNullable();
            if ($.databaseName == null) {
                throw new MissingRequiredPropertyException("ScriptArgs", "databaseName");
            }
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("ScriptArgs", "resourceGroupName");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy