JavaGroups
Class PullPushAdapter
java.lang.Object
|
+--JavaGroups.PullPushAdapter
- public class PullPushAdapter
- extends java.lang.Object
- implements java.lang.Runnable
Allows a client of Channel to be notified when messages have been received
instead of having to actively poll the channel for new messages. Typically used in the
client role (Receive()). As this class does not implement interface
Transport, but uses it for receiving messages, an underlying object
has to be used to send messages (e.g. the channel on which an object of this class relies).
| Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
PullPushAdapter
public PullPushAdapter(Transport transport)
PullPushAdapter
public PullPushAdapter(Transport transport,
MessageListener l)
PullPushAdapter
public PullPushAdapter(Transport transport,
MembershipListener ml)
PullPushAdapter
public PullPushAdapter(Transport transport,
MessageListener l,
MembershipListener ml)
Start
public void Start()
Stop
public void Stop()
SetListener
public void SetListener(MessageListener l)
SetMembershipListener
public void SetMembershipListener(MembershipListener ml)
run
public void run()
- Reentrant run(): message reception is serialized, then the listener is notified of the
message reception
- Specified by:
- run in interface java.lang.Runnable