// *** 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.azure.relay;

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


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

    public static final HybridConnectionAuthorizationRuleArgs Empty = new HybridConnectionAuthorizationRuleArgs();

    /**
     * Name of the Azure Relay Hybrid Connection for which this Azure Relay Hybrid Connection Authorization Rule will be created. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
     * 
     */
    @Import(name="hybridConnectionName", required=true)
    private Output<String> hybridConnectionName;

    /**
     * @return Name of the Azure Relay Hybrid Connection for which this Azure Relay Hybrid Connection Authorization Rule will be created. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
     * 
     */
    public Output<String> hybridConnectionName() {
        return this.hybridConnectionName;
    }

    /**
     * Grants listen access to this Authorization Rule. Defaults to `false`.
     * 
     */
    @Import(name="listen")
    private @Nullable Output<Boolean> listen;

    /**
     * @return Grants listen access to this Authorization Rule. Defaults to `false`.
     * 
     */
    public Optional<Output<Boolean>> listen() {
        return Optional.ofNullable(this.listen);
    }

    /**
     * Grants manage access to this Authorization Rule. When this property is `true` - both `listen` and `send` must be set to `true` too. Defaults to `false`.
     * 
     */
    @Import(name="manage")
    private @Nullable Output<Boolean> manage;

    /**
     * @return Grants manage access to this Authorization Rule. When this property is `true` - both `listen` and `send` must be set to `true` too. Defaults to `false`.
     * 
     */
    public Optional<Output<Boolean>> manage() {
        return Optional.ofNullable(this.manage);
    }

    /**
     * The name which should be used for this Azure Relay Hybrid Connection Authorization Rule. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
     * 
     */
    @Import(name="name")
    private @Nullable Output<String> name;

    /**
     * @return The name which should be used for this Azure Relay Hybrid Connection Authorization Rule. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
     * 
     */
    public Optional<Output<String>> name() {
        return Optional.ofNullable(this.name);
    }

    /**
     * Name of the Azure Relay Namespace for which this Azure Relay Hybrid Connection Authorization Rule will be created. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
     * 
     */
    @Import(name="namespaceName", required=true)
    private Output<String> namespaceName;

    /**
     * @return Name of the Azure Relay Namespace for which this Azure Relay Hybrid Connection Authorization Rule will be created. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
     * 
     */
    public Output<String> namespaceName() {
        return this.namespaceName;
    }

    /**
     * The name of the Resource Group where the Azure Relay Hybrid Connection Authorization Rule should exist. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
     * 
     */
    @Import(name="resourceGroupName", required=true)
    private Output<String> resourceGroupName;

    /**
     * @return The name of the Resource Group where the Azure Relay Hybrid Connection Authorization Rule should exist. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
     * 
     */
    public Output<String> resourceGroupName() {
        return this.resourceGroupName;
    }

    /**
     * Grants send access to this Authorization Rule. Defaults to `false`.
     * 
     */
    @Import(name="send")
    private @Nullable Output<Boolean> send;

    /**
     * @return Grants send access to this Authorization Rule. Defaults to `false`.
     * 
     */
    public Optional<Output<Boolean>> send() {
        return Optional.ofNullable(this.send);
    }

    private HybridConnectionAuthorizationRuleArgs() {}

    private HybridConnectionAuthorizationRuleArgs(HybridConnectionAuthorizationRuleArgs $) {
        this.hybridConnectionName = $.hybridConnectionName;
        this.listen = $.listen;
        this.manage = $.manage;
        this.name = $.name;
        this.namespaceName = $.namespaceName;
        this.resourceGroupName = $.resourceGroupName;
        this.send = $.send;
    }

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

    public static final class Builder {
        private HybridConnectionAuthorizationRuleArgs $;

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

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

        /**
         * @param hybridConnectionName Name of the Azure Relay Hybrid Connection for which this Azure Relay Hybrid Connection Authorization Rule will be created. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
         * 
         * @return builder
         * 
         */
        public Builder hybridConnectionName(Output<String> hybridConnectionName) {
            $.hybridConnectionName = hybridConnectionName;
            return this;
        }

        /**
         * @param hybridConnectionName Name of the Azure Relay Hybrid Connection for which this Azure Relay Hybrid Connection Authorization Rule will be created. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
         * 
         * @return builder
         * 
         */
        public Builder hybridConnectionName(String hybridConnectionName) {
            return hybridConnectionName(Output.of(hybridConnectionName));
        }

        /**
         * @param listen Grants listen access to this Authorization Rule. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder listen(@Nullable Output<Boolean> listen) {
            $.listen = listen;
            return this;
        }

        /**
         * @param listen Grants listen access to this Authorization Rule. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder listen(Boolean listen) {
            return listen(Output.of(listen));
        }

        /**
         * @param manage Grants manage access to this Authorization Rule. When this property is `true` - both `listen` and `send` must be set to `true` too. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder manage(@Nullable Output<Boolean> manage) {
            $.manage = manage;
            return this;
        }

        /**
         * @param manage Grants manage access to this Authorization Rule. When this property is `true` - both `listen` and `send` must be set to `true` too. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder manage(Boolean manage) {
            return manage(Output.of(manage));
        }

        /**
         * @param name The name which should be used for this Azure Relay Hybrid Connection Authorization Rule. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
         * 
         * @return builder
         * 
         */
        public Builder name(@Nullable Output<String> name) {
            $.name = name;
            return this;
        }

        /**
         * @param name The name which should be used for this Azure Relay Hybrid Connection Authorization Rule. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param namespaceName Name of the Azure Relay Namespace for which this Azure Relay Hybrid Connection Authorization Rule will be created. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
         * 
         * @return builder
         * 
         */
        public Builder namespaceName(Output<String> namespaceName) {
            $.namespaceName = namespaceName;
            return this;
        }

        /**
         * @param namespaceName Name of the Azure Relay Namespace for which this Azure Relay Hybrid Connection Authorization Rule will be created. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
         * 
         * @return builder
         * 
         */
        public Builder namespaceName(String namespaceName) {
            return namespaceName(Output.of(namespaceName));
        }

        /**
         * @param resourceGroupName The name of the Resource Group where the Azure Relay Hybrid Connection Authorization Rule should exist. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(Output<String> resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the Resource Group where the Azure Relay Hybrid Connection Authorization Rule should exist. Changing this forces a new Azure Relay Hybrid Connection Authorization Rule to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param send Grants send access to this Authorization Rule. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder send(@Nullable Output<Boolean> send) {
            $.send = send;
            return this;
        }

        /**
         * @param send Grants send access to this Authorization Rule. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder send(Boolean send) {
            return send(Output.of(send));
        }

        public HybridConnectionAuthorizationRuleArgs build() {
            $.hybridConnectionName = Objects.requireNonNull($.hybridConnectionName, "expected parameter 'hybridConnectionName' to be non-null");
            $.namespaceName = Objects.requireNonNull($.namespaceName, "expected parameter 'namespaceName' to be non-null");
            $.resourceGroupName = Objects.requireNonNull($.resourceGroupName, "expected parameter 'resourceGroupName' to be non-null");
            return $;
        }
    }

}
