LimeWire Consolidated API

com.limegroup.gnutella
Interface Acceptor

All Superinterfaces:
SocketProcessor
All Known Implementing Classes:
AcceptorImpl

public interface Acceptor
extends SocketProcessor


Method Summary
 boolean acceptedIncoming()
          Determines whether or not LimeWire has detected it is firewalled or not.
 void bindAndStartUpnp()
          tries to bind the serversocket and create UPnPMappings.
 byte[] getAddress(boolean preferForcedAddress)
          Returns this' address to use for ping replies, query replies, and pushes.
 byte[] getExternalAddress()
          Returns this' external address.
 long getIncomingExpireTime()
           
 int getPort(boolean checkForcedPort)
          Returns the port at which the Connection Manager listens for incoming connections
 long getTimeBetweenValidates()
           
 long getWaitTimeAfterRequests()
           
 boolean isAddressExternal()
          Returns whether or not our advertised IP address is the same as what remote peers believe it is.
 void resetLastConnectBackTime()
           
 void setAddress(InetAddress address)
           
 void setExternalAddress(InetAddress address)
          Sets the external address.
 void setListeningPort(int port)
           
 void shutdown()
          If we used UPnP Mappings this session, clean them up and revert any relevant settings.
 void start()
          Launches the port monitoring thread, MulticastService, and UDPService.
 
Methods inherited from interface com.limegroup.gnutella.SocketProcessor
processSocket, processSocket
 

Method Detail

setAddress

void setAddress(InetAddress address)

setExternalAddress

void setExternalAddress(InetAddress address)
Sets the external address.


bindAndStartUpnp

void bindAndStartUpnp()
tries to bind the serversocket and create UPnPMappings. call before running.


start

void start()
Launches the port monitoring thread, MulticastService, and UDPService.


isAddressExternal

boolean isAddressExternal()
Returns whether or not our advertised IP address is the same as what remote peers believe it is.


getExternalAddress

byte[] getExternalAddress()
Returns this' external address.


getAddress

byte[] getAddress(boolean preferForcedAddress)
Returns this' address to use for ping replies, query replies, and pushes.

Parameters:
preferForcedAddress - whether or not to prefer the forced address if the IP address is forced. If false, the forced IP address will never be returned If true, the forced IP address will only be returned if one is set.

getPort

int getPort(boolean checkForcedPort)
Returns the port at which the Connection Manager listens for incoming connections

Parameters:
checkForcedPort - if true returns the forced port if forcing an external address and port is enabled
Returns:
the listening port

setListeningPort

void setListeningPort(int port)
                      throws IOException
Throws:
IOException

acceptedIncoming

boolean acceptedIncoming()
Determines whether or not LimeWire has detected it is firewalled or not.


shutdown

void shutdown()
If we used UPnP Mappings this session, clean them up and revert any relevant settings.


getIncomingExpireTime

long getIncomingExpireTime()

getTimeBetweenValidates

long getTimeBetweenValidates()

getWaitTimeAfterRequests

long getWaitTimeAfterRequests()

resetLastConnectBackTime

void resetLastConnectBackTime()

LimeWire Consolidated API

Copyright © 2009. All Rights Reserved.