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

com.pulumi.snowflake.GrantPrivilegesToAccountRoleArgs Maven / Gradle / Ivy

There is a newer version: 1.0.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.snowflake;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import com.pulumi.snowflake.inputs.GrantPrivilegesToAccountRoleOnAccountObjectArgs;
import com.pulumi.snowflake.inputs.GrantPrivilegesToAccountRoleOnSchemaArgs;
import com.pulumi.snowflake.inputs.GrantPrivilegesToAccountRoleOnSchemaObjectArgs;
import java.lang.Boolean;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final GrantPrivilegesToAccountRoleArgs Empty = new GrantPrivilegesToAccountRoleArgs();

    /**
     * The fully qualified name of the account role to which privileges will be granted.
     * 
     */
    @Import(name="accountRoleName", required=true)
    private Output accountRoleName;

    /**
     * @return The fully qualified name of the account role to which privileges will be granted.
     * 
     */
    public Output accountRoleName() {
        return this.accountRoleName;
    }

    /**
     * Grant all privileges on the account role.
     * 
     */
    @Import(name="allPrivileges")
    private @Nullable Output allPrivileges;

    /**
     * @return Grant all privileges on the account role.
     * 
     */
    public Optional> allPrivileges() {
        return Optional.ofNullable(this.allPrivileges);
    }

    @Import(name="alwaysApply")
    private @Nullable Output alwaysApply;

    public Optional> alwaysApply() {
        return Optional.ofNullable(this.alwaysApply);
    }

    /**
     * This is a helper field and should not be set. Its main purpose is to help to achieve the functionality described by the always_apply field.
     * 
     */
    @Import(name="alwaysApplyTrigger")
    private @Nullable Output alwaysApplyTrigger;

    /**
     * @return This is a helper field and should not be set. Its main purpose is to help to achieve the functionality described by the always_apply field.
     * 
     */
    public Optional> alwaysApplyTrigger() {
        return Optional.ofNullable(this.alwaysApplyTrigger);
    }

    /**
     * If true, the privileges will be granted on the account.
     * 
     */
    @Import(name="onAccount")
    private @Nullable Output onAccount;

    /**
     * @return If true, the privileges will be granted on the account.
     * 
     */
    public Optional> onAccount() {
        return Optional.ofNullable(this.onAccount);
    }

    /**
     * Specifies the account object on which privileges will be granted
     * 
     */
    @Import(name="onAccountObject")
    private @Nullable Output onAccountObject;

    /**
     * @return Specifies the account object on which privileges will be granted
     * 
     */
    public Optional> onAccountObject() {
        return Optional.ofNullable(this.onAccountObject);
    }

    /**
     * Specifies the schema on which privileges will be granted.
     * 
     */
    @Import(name="onSchema")
    private @Nullable Output onSchema;

    /**
     * @return Specifies the schema on which privileges will be granted.
     * 
     */
    public Optional> onSchema() {
        return Optional.ofNullable(this.onSchema);
    }

    /**
     * Specifies the schema object on which privileges will be granted.
     * 
     */
    @Import(name="onSchemaObject")
    private @Nullable Output onSchemaObject;

    /**
     * @return Specifies the schema object on which privileges will be granted.
     * 
     */
    public Optional> onSchemaObject() {
        return Optional.ofNullable(this.onSchemaObject);
    }

    /**
     * The privileges to grant on the account role.
     * 
     */
    @Import(name="privileges")
    private @Nullable Output> privileges;

    /**
     * @return The privileges to grant on the account role.
     * 
     */
    public Optional>> privileges() {
        return Optional.ofNullable(this.privileges);
    }

    /**
     * Specifies whether the grantee can grant the privileges to other users.
     * 
     */
    @Import(name="withGrantOption")
    private @Nullable Output withGrantOption;

    /**
     * @return Specifies whether the grantee can grant the privileges to other users.
     * 
     */
    public Optional> withGrantOption() {
        return Optional.ofNullable(this.withGrantOption);
    }

    private GrantPrivilegesToAccountRoleArgs() {}

    private GrantPrivilegesToAccountRoleArgs(GrantPrivilegesToAccountRoleArgs $) {
        this.accountRoleName = $.accountRoleName;
        this.allPrivileges = $.allPrivileges;
        this.alwaysApply = $.alwaysApply;
        this.alwaysApplyTrigger = $.alwaysApplyTrigger;
        this.onAccount = $.onAccount;
        this.onAccountObject = $.onAccountObject;
        this.onSchema = $.onSchema;
        this.onSchemaObject = $.onSchemaObject;
        this.privileges = $.privileges;
        this.withGrantOption = $.withGrantOption;
    }

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

    public static final class Builder {
        private GrantPrivilegesToAccountRoleArgs $;

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

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

        /**
         * @param accountRoleName The fully qualified name of the account role to which privileges will be granted.
         * 
         * @return builder
         * 
         */
        public Builder accountRoleName(Output accountRoleName) {
            $.accountRoleName = accountRoleName;
            return this;
        }

        /**
         * @param accountRoleName The fully qualified name of the account role to which privileges will be granted.
         * 
         * @return builder
         * 
         */
        public Builder accountRoleName(String accountRoleName) {
            return accountRoleName(Output.of(accountRoleName));
        }

        /**
         * @param allPrivileges Grant all privileges on the account role.
         * 
         * @return builder
         * 
         */
        public Builder allPrivileges(@Nullable Output allPrivileges) {
            $.allPrivileges = allPrivileges;
            return this;
        }

        /**
         * @param allPrivileges Grant all privileges on the account role.
         * 
         * @return builder
         * 
         */
        public Builder allPrivileges(Boolean allPrivileges) {
            return allPrivileges(Output.of(allPrivileges));
        }

        public Builder alwaysApply(@Nullable Output alwaysApply) {
            $.alwaysApply = alwaysApply;
            return this;
        }

        public Builder alwaysApply(Boolean alwaysApply) {
            return alwaysApply(Output.of(alwaysApply));
        }

        /**
         * @param alwaysApplyTrigger This is a helper field and should not be set. Its main purpose is to help to achieve the functionality described by the always_apply field.
         * 
         * @return builder
         * 
         */
        public Builder alwaysApplyTrigger(@Nullable Output alwaysApplyTrigger) {
            $.alwaysApplyTrigger = alwaysApplyTrigger;
            return this;
        }

        /**
         * @param alwaysApplyTrigger This is a helper field and should not be set. Its main purpose is to help to achieve the functionality described by the always_apply field.
         * 
         * @return builder
         * 
         */
        public Builder alwaysApplyTrigger(String alwaysApplyTrigger) {
            return alwaysApplyTrigger(Output.of(alwaysApplyTrigger));
        }

        /**
         * @param onAccount If true, the privileges will be granted on the account.
         * 
         * @return builder
         * 
         */
        public Builder onAccount(@Nullable Output onAccount) {
            $.onAccount = onAccount;
            return this;
        }

        /**
         * @param onAccount If true, the privileges will be granted on the account.
         * 
         * @return builder
         * 
         */
        public Builder onAccount(Boolean onAccount) {
            return onAccount(Output.of(onAccount));
        }

        /**
         * @param onAccountObject Specifies the account object on which privileges will be granted
         * 
         * @return builder
         * 
         */
        public Builder onAccountObject(@Nullable Output onAccountObject) {
            $.onAccountObject = onAccountObject;
            return this;
        }

        /**
         * @param onAccountObject Specifies the account object on which privileges will be granted
         * 
         * @return builder
         * 
         */
        public Builder onAccountObject(GrantPrivilegesToAccountRoleOnAccountObjectArgs onAccountObject) {
            return onAccountObject(Output.of(onAccountObject));
        }

        /**
         * @param onSchema Specifies the schema on which privileges will be granted.
         * 
         * @return builder
         * 
         */
        public Builder onSchema(@Nullable Output onSchema) {
            $.onSchema = onSchema;
            return this;
        }

        /**
         * @param onSchema Specifies the schema on which privileges will be granted.
         * 
         * @return builder
         * 
         */
        public Builder onSchema(GrantPrivilegesToAccountRoleOnSchemaArgs onSchema) {
            return onSchema(Output.of(onSchema));
        }

        /**
         * @param onSchemaObject Specifies the schema object on which privileges will be granted.
         * 
         * @return builder
         * 
         */
        public Builder onSchemaObject(@Nullable Output onSchemaObject) {
            $.onSchemaObject = onSchemaObject;
            return this;
        }

        /**
         * @param onSchemaObject Specifies the schema object on which privileges will be granted.
         * 
         * @return builder
         * 
         */
        public Builder onSchemaObject(GrantPrivilegesToAccountRoleOnSchemaObjectArgs onSchemaObject) {
            return onSchemaObject(Output.of(onSchemaObject));
        }

        /**
         * @param privileges The privileges to grant on the account role.
         * 
         * @return builder
         * 
         */
        public Builder privileges(@Nullable Output> privileges) {
            $.privileges = privileges;
            return this;
        }

        /**
         * @param privileges The privileges to grant on the account role.
         * 
         * @return builder
         * 
         */
        public Builder privileges(List privileges) {
            return privileges(Output.of(privileges));
        }

        /**
         * @param privileges The privileges to grant on the account role.
         * 
         * @return builder
         * 
         */
        public Builder privileges(String... privileges) {
            return privileges(List.of(privileges));
        }

        /**
         * @param withGrantOption Specifies whether the grantee can grant the privileges to other users.
         * 
         * @return builder
         * 
         */
        public Builder withGrantOption(@Nullable Output withGrantOption) {
            $.withGrantOption = withGrantOption;
            return this;
        }

        /**
         * @param withGrantOption Specifies whether the grantee can grant the privileges to other users.
         * 
         * @return builder
         * 
         */
        public Builder withGrantOption(Boolean withGrantOption) {
            return withGrantOption(Output.of(withGrantOption));
        }

        public GrantPrivilegesToAccountRoleArgs build() {
            if ($.accountRoleName == null) {
                throw new MissingRequiredPropertyException("GrantPrivilegesToAccountRoleArgs", "accountRoleName");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy