Interface IMqttServerSubscribeValidator


  • public interface IMqttServerSubscribeValidator
    mqtt 服务端,认证处理器
    Author:
    L.cm
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static org.slf4j.Logger logger  
    • Field Detail

      • logger

        static final org.slf4j.Logger logger
    • Method Detail

      • verifyTopicFilter

        default boolean verifyTopicFilter​(org.tio.core.ChannelContext context,
                                          String clientId,
                                          String topicFilter,
                                          br.com.anteros.mqtt.codec.MqttQoS qoS)
        校验订阅的 topicFilter
        Parameters:
        context - ChannelContext
        clientId - clientId
        topicFilter - topicFilter
        qoS - MqttQoS
        Returns:
        是否有权限
      • isValid

        boolean isValid​(org.tio.core.ChannelContext context,
                        String clientId,
                        String topicFilter,
                        br.com.anteros.mqtt.codec.MqttQoS qoS)
        是否可以订阅
        Parameters:
        context - ChannelContext
        clientId - 客户端 id
        topicFilter - 订阅 topic
        qoS - MqttQoS
        Returns:
        是否可以订阅