Beispiel #1
0
        /// <summary>
        ///     Initializes a new instance of the <see cref="MqttSubscribePayload" /> class.
        /// </summary>
        /// <param name="header">The header to use for the message.</param>
        /// <param name="variableHeader">The variable header to use for the message.</param>
        /// <param name="payloadStream">The payload stream.</param>
        public MqttSubscribePayload(MqttHeader header, MqttSubscribeVariableHeader variableHeader, Stream payloadStream)
        {
            this.header         = header;
            this.variableHeader = variableHeader;

            ReadFrom(payloadStream);
        }
        /// <summary>
        ///     Initializes a new instance of the <see cref="MqttSubscribeAckPayload" /> class.
        /// </summary>
        /// <param name="header">The header to use for the message.</param>
        /// <param name="variableHeader">The variable header to use for the message.</param>
        /// <param name="payloadStream">The payload stream.</param>
        public MqttSubscribeAckPayload(MqttHeader header, MqttSubscribeAckVariableHeader variableHeader,
                                       Stream payloadStream) {
            this.header = header;
            this.variableHeader = variableHeader;

            ReadFrom(payloadStream);
        }