org.limewire.lws.server
Class AbstractReceivesCommandsFromDispatcher
java.lang.Object
org.limewire.lws.server.AbstractReceivesCommandsFromDispatcher
- All Implemented Interfaces:
- LWSReceivesCommandsFromDispatcher
public abstract class AbstractReceivesCommandsFromDispatcher
- extends Object
- implements LWSReceivesCommandsFromDispatcher
This is what receives actual commands from an LWSDispatcherSupport.
This class abstract out the
#addConnectionListener(ConnectionListener adding,
#removeConnectionListener(ConnectionListener removing, and
#setConnected(boolean notifying of LWSConnectionListeners and
leaves subclasses responsible for implementing the
{@link ReceivesCommandsFromDispatcher#receiveCommand(String, java.util.Map command handling).
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractReceivesCommandsFromDispatcher
public AbstractReceivesCommandsFromDispatcher()
setConnected
public final void setConnected(boolean isConnected)
- Description copied from interface:
LWSReceivesCommandsFromDispatcher
- Called when we're connected from the server, and
this
should notify all the LWSConnectionListeners added by
LWSReceivesCommandsFromDispatcher.addConnectionListener(LWSConnectionListener).
- Specified by:
setConnected in interface LWSReceivesCommandsFromDispatcher
- Parameters:
isConnected - whether we're connected when a connection changes
addConnectionListener
public final boolean addConnectionListener(LWSConnectionListener lis)
- Description copied from interface:
LWSReceivesCommandsFromDispatcher
- Returns
true if lis was added as a listener,
false otherwise.
- Specified by:
addConnectionListener in interface LWSReceivesCommandsFromDispatcher
- Parameters:
lis - new listener
- Returns:
true if lis was added as a listener,
false otherwise.
removeConnectionListener
public final boolean removeConnectionListener(LWSConnectionListener lis)
- Description copied from interface:
LWSReceivesCommandsFromDispatcher
- Returns
true if lis was removed as a listener,
false otherwise.
- Specified by:
removeConnectionListener in interface LWSReceivesCommandsFromDispatcher
- Parameters:
lis - old listener
- Returns:
true if lis was removed as a listener,
false otherwise.
Copyright © 2009. All Rights Reserved.