Class InMemoryMqttMessageStore

    • Constructor Detail

      • InMemoryMqttMessageStore

        public InMemoryMqttMessageStore()
    • Method Detail

      • addWillMessage

        public boolean addWillMessage​(String clientId,
                                      br.com.anteros.mqtt.core.server.model.Message message)
        Description copied from interface: IMqttMessageStore
        存储 clientId 的遗嘱消息
        Specified by:
        addWillMessage in interface IMqttMessageStore
        Parameters:
        clientId - clientId
        message - message
        Returns:
        boolean
      • getWillMessage

        public br.com.anteros.mqtt.core.server.model.Message getWillMessage​(String clientId)
        Description copied from interface: IMqttMessageStore
        获取 will 消息
        Specified by:
        getWillMessage in interface IMqttMessageStore
        Parameters:
        clientId - clientId
        Returns:
        Message
      • addRetainMessage

        public boolean addRetainMessage​(String topic,
                                        br.com.anteros.mqtt.core.server.model.Message message)
        Description copied from interface: IMqttMessageStore
        存储 retain 消息
        Specified by:
        addRetainMessage in interface IMqttMessageStore
        Parameters:
        topic - topic
        message - message
        Returns:
        boolean
      • getRetainMessage

        public List<br.com.anteros.mqtt.core.server.model.Message> getRetainMessage​(String topicFilter)
        Description copied from interface: IMqttMessageStore
        获取所有 retain 消息
        Specified by:
        getRetainMessage in interface IMqttMessageStore
        Parameters:
        topicFilter - topicFilter
        Returns:
        Message