org.jgroups.demos
Class Draw
java.lang.Object
org.jgroups.demos.Draw
- All Implemented Interfaces:
- java.awt.event.ActionListener, ChannelListener, java.util.EventListener
- public class Draw
- extends java.lang.Object
- implements java.awt.event.ActionListener, ChannelListener
Shared whiteboard, each new instance joins the same group. Each instance chooses a random color,
mouse moves are broadcast to all group members, which then apply them to their canvas
- Author:
- Bela Ban, Oct 17 2001
Constructor Summary |
Draw(java.lang.String props,
boolean debug,
boolean cummulative,
boolean no_channel,
boolean jmx)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Draw
public Draw(java.lang.String props,
boolean debug,
boolean cummulative,
boolean no_channel,
boolean jmx)
throws java.lang.Exception
getGroupName
public java.lang.String getGroupName()
setGroupName
public void setGroupName(java.lang.String groupname)
main
public static void main(java.lang.String[] args)
go
public void go()
throws java.lang.Exception
- Throws:
java.lang.Exception
mainLoop
public void mainLoop()
clearPanel
public void clearPanel()
sendClearPanelMsg
public void sendClearPanelMsg()
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent e)
- Specified by:
actionPerformed
in interface java.awt.event.ActionListener
channelConnected
public void channelConnected(Channel channel)
- Specified by:
channelConnected
in interface ChannelListener
channelDisconnected
public void channelDisconnected(Channel channel)
- Specified by:
channelDisconnected
in interface ChannelListener
channelClosed
public void channelClosed(Channel channel)
- Specified by:
channelClosed
in interface ChannelListener
channelShunned
public void channelShunned()
- Specified by:
channelShunned
in interface ChannelListener
channelReconnected
public void channelReconnected(Address addr)
- Specified by:
channelReconnected
in interface ChannelListener
Copyright ? 1998-2005 Bela Ban. All Rights Reserved.