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

com.pulumi.azurenative.iotoperationsmq.inputs.MqttBridgeRemoteBrokerConnectionSpecArgs Maven / Gradle / Ivy

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

import com.pulumi.azurenative.iotoperationsmq.enums.MqttBridgeRemoteBrokerProtocol;
import com.pulumi.azurenative.iotoperationsmq.inputs.MqttBridgeRemoteBrokerAuthenticationMethodsArgs;
import com.pulumi.azurenative.iotoperationsmq.inputs.MqttBridgeRemoteBrokerConnectionTlsArgs;
import com.pulumi.core.Either;
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.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * MqttBridge RemoteBrokerConnectionSpec details
 * 
 */
public final class MqttBridgeRemoteBrokerConnectionSpecArgs extends com.pulumi.resources.ResourceArgs {

    public static final MqttBridgeRemoteBrokerConnectionSpecArgs Empty = new MqttBridgeRemoteBrokerConnectionSpecArgs();

    /**
     * The remote broker authentication methods. NOTE - Enum only one method is allowed to be passed.
     * 
     */
    @Import(name="authentication", required=true)
    private Output authentication;

    /**
     * @return The remote broker authentication methods. NOTE - Enum only one method is allowed to be passed.
     * 
     */
    public Output authentication() {
        return this.authentication;
    }

    /**
     * The endpoint of remote broker to connect to.
     * 
     */
    @Import(name="endpoint", required=true)
    private Output endpoint;

    /**
     * @return The endpoint of remote broker to connect to.
     * 
     */
    public Output endpoint() {
        return this.endpoint;
    }

    /**
     * Protocol for remote connection.
     * 
     */
    @Import(name="protocol")
    private @Nullable Output> protocol;

    /**
     * @return Protocol for remote connection.
     * 
     */
    public Optional>> protocol() {
        return Optional.ofNullable(this.protocol);
    }

    /**
     * TLS details for Remote broker Connection.
     * 
     */
    @Import(name="tls", required=true)
    private Output tls;

    /**
     * @return TLS details for Remote broker Connection.
     * 
     */
    public Output tls() {
        return this.tls;
    }

    private MqttBridgeRemoteBrokerConnectionSpecArgs() {}

    private MqttBridgeRemoteBrokerConnectionSpecArgs(MqttBridgeRemoteBrokerConnectionSpecArgs $) {
        this.authentication = $.authentication;
        this.endpoint = $.endpoint;
        this.protocol = $.protocol;
        this.tls = $.tls;
    }

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

    public static final class Builder {
        private MqttBridgeRemoteBrokerConnectionSpecArgs $;

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

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

        /**
         * @param authentication The remote broker authentication methods. NOTE - Enum only one method is allowed to be passed.
         * 
         * @return builder
         * 
         */
        public Builder authentication(Output authentication) {
            $.authentication = authentication;
            return this;
        }

        /**
         * @param authentication The remote broker authentication methods. NOTE - Enum only one method is allowed to be passed.
         * 
         * @return builder
         * 
         */
        public Builder authentication(MqttBridgeRemoteBrokerAuthenticationMethodsArgs authentication) {
            return authentication(Output.of(authentication));
        }

        /**
         * @param endpoint The endpoint of remote broker to connect to.
         * 
         * @return builder
         * 
         */
        public Builder endpoint(Output endpoint) {
            $.endpoint = endpoint;
            return this;
        }

        /**
         * @param endpoint The endpoint of remote broker to connect to.
         * 
         * @return builder
         * 
         */
        public Builder endpoint(String endpoint) {
            return endpoint(Output.of(endpoint));
        }

        /**
         * @param protocol Protocol for remote connection.
         * 
         * @return builder
         * 
         */
        public Builder protocol(@Nullable Output> protocol) {
            $.protocol = protocol;
            return this;
        }

        /**
         * @param protocol Protocol for remote connection.
         * 
         * @return builder
         * 
         */
        public Builder protocol(Either protocol) {
            return protocol(Output.of(protocol));
        }

        /**
         * @param protocol Protocol for remote connection.
         * 
         * @return builder
         * 
         */
        public Builder protocol(String protocol) {
            return protocol(Either.ofLeft(protocol));
        }

        /**
         * @param protocol Protocol for remote connection.
         * 
         * @return builder
         * 
         */
        public Builder protocol(MqttBridgeRemoteBrokerProtocol protocol) {
            return protocol(Either.ofRight(protocol));
        }

        /**
         * @param tls TLS details for Remote broker Connection.
         * 
         * @return builder
         * 
         */
        public Builder tls(Output tls) {
            $.tls = tls;
            return this;
        }

        /**
         * @param tls TLS details for Remote broker Connection.
         * 
         * @return builder
         * 
         */
        public Builder tls(MqttBridgeRemoteBrokerConnectionTlsArgs tls) {
            return tls(Output.of(tls));
        }

        public MqttBridgeRemoteBrokerConnectionSpecArgs build() {
            if ($.authentication == null) {
                throw new MissingRequiredPropertyException("MqttBridgeRemoteBrokerConnectionSpecArgs", "authentication");
            }
            if ($.endpoint == null) {
                throw new MissingRequiredPropertyException("MqttBridgeRemoteBrokerConnectionSpecArgs", "endpoint");
            }
            $.protocol = Codegen.stringProp("protocol").left(MqttBridgeRemoteBrokerProtocol.class).output().arg($.protocol).def("mqtt").getNullable();
            if ($.tls == null) {
                throw new MissingRequiredPropertyException("MqttBridgeRemoteBrokerConnectionSpecArgs", "tls");
            }
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy