com.hazelcast.core
Interface MessageListener<E>

Type Parameters:
E - message
All Superinterfaces:
EventListener
All Known Implementing Classes:
ClientConsoleApp, ConsoleApp

public interface MessageListener<E>
extends EventListener

Message listener for ITopic.


Method Summary
 void onMessage(Message<E> message)
          Invoked when a message is received for the added topic.
 

Method Detail

onMessage

void onMessage(Message<E> message)
Invoked when a message is received for the added topic. Note that topic guarantees message ordering. Therefore there is only one thread invoking onMessage. The user should not keep the thread busy, but preferably should dispatch it via an Executor. This will increase the performance of the topic.

Parameters:
message - the message that is received for the added topic


Copyright © 2015 Hazelcast, Inc.. All Rights Reserved.