Show / Hide Table of Contents

    Class BrokerOptionsBuilderAddMockedMqttExtensions

    Adds the AddMockedMqtt method to the IBrokerOptionsBuilder.

    Inheritance
    object
    BrokerOptionsBuilderAddMockedMqttExtensions
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Microsoft.Extensions.DependencyInjection
    Assembly: Silverback.Integration.MQTT.Testing.dll
    Syntax
    public static class BrokerOptionsBuilderAddMockedMqttExtensions

    Methods

    | Improve this doc View source

    AddMockedMqtt(IBrokerOptionsBuilder, Action<IMockedMqttOptionsBuilder>?)

    Registers Apache Mqtt as message broker but replaces the MQTT connectivity based on MQTTnet with a mocked in-memory message broker that more or less replicates the MQTT broker behavior.

    Declaration
    public static IBrokerOptionsBuilder AddMockedMqtt(this IBrokerOptionsBuilder brokerOptionsBuilder, Action<IMockedMqttOptionsBuilder>? optionsAction = null)
    Parameters
    Type Name Description
    IBrokerOptionsBuilder brokerOptionsBuilder

    The IBrokerOptionsBuilder that references the IServiceCollection to add the services to.

    Action<IMockedMqttOptionsBuilder> optionsAction

    Configures the mock options.

    Returns
    Type Description
    IBrokerOptionsBuilder

    The IBrokerOptionsBuilder so that additional calls can be chained.

    • Improve this doc
    • View source
    GitHub E-Mail
    ↑ Back to top © 2020 Sergio Aquilini