Example #1
0
        public Mqtt(MQTTConnection connection)
        {
            _connection = connection;
            _topicMatcher = new MqttTopicMatcher();
            _handlers = new List<MqttHandler>();

            _connection.MqttMsgPublishReceived += OnConnectionOnMqttMsgPublishReceived;
        }
Example #2
0
        public Mqtt(MQTTConnection connection)
        {
            _connection   = connection;
            _topicMatcher = new MqttTopicMatcher();
            _handlers     = new List <MqttHandler>();

            _connection.MqttMsgPublishReceived += OnConnectionOnMqttMsgPublishReceived;
        }
Example #3
0
        public MqttRouter(IMqttClient connection)
        {
            _connection   = connection;
            _topicMatcher = new MqttTopicMatcher();
            _handlers     = new List <MqttHandler>();

            connection
            .MessageStream
            .Subscribe(msg => MqttMsgReceived(msg));
        }