net.tomp2p.p2p
Class ConnectionConfiguration

java.lang.Object
  extended by net.tomp2p.p2p.ConnectionConfiguration

public class ConnectionConfiguration
extends Object


Constructor Summary
ConnectionConfiguration()
           
 
Method Summary
 int getConnectTimeoutMillis()
           
 int getDiscoverTimeoutSec()
           
 int getIdleTCPMillis()
           
 int getIdleUDPMillis()
           
 int getMaxCreating()
           
 int getMaxOpenConnection()
           
 int getTrackerTimoutSeconds()
           
 boolean isBehindFirewall()
           
 boolean isDisableBind()
           
 boolean isForceStorageUDP()
           
 boolean isForceTrackerTCP()
           
 boolean isLimitTracker()
           
 void setBehindFirewall(boolean behindFirewall)
          By setting this flag, the peer assumes that it is behind a firewall and will announce itself as unreachable.
 void setConnectTimeoutMillis(int connectTimeouMillist)
           
 void setDisableBind(boolean disableBind)
           
 void setDiscoverTimeoutSec(int discoverTimeoutSec)
           
 void setForceStorageUDP(boolean forceStorageUDP)
           
 void setForceTrackerTCP(boolean forceTrackerTCP)
           
 void setIdleTCPMillis(int idleTCPMillis)
           
 void setIdleUDPMillis(int idleUDPMillis)
           
 void setLimitTracker(boolean limitTracker)
           
 void setMaxCreating(int maxCreating)
           
 void setMaxOpenConnection(int maxOpenConnection)
           
 void setTrackerTimoutSeconds(int trackerTimoutSeconds)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConnectionConfiguration

public ConnectionConfiguration()
Method Detail

setDiscoverTimeoutSec

public void setDiscoverTimeoutSec(int discoverTimeoutSec)

getDiscoverTimeoutSec

public int getDiscoverTimeoutSec()

setBehindFirewall

public void setBehindFirewall(boolean behindFirewall)
By setting this flag, the peer assumes that it is behind a firewall and will announce itself as unreachable. As soon as this peer receives an incoming message from its advertised address, the peer marks itself as reachable. To receive an incoming message, the peer has to call Peer#discover(net.tomp2p.peers.PeerAddress) to mark itself as reachable.

Parameters:
behindFirewall - If set to true, peer is assumed to be behind firewall and is unreable.

isBehindFirewall

public boolean isBehindFirewall()

getTrackerTimoutSeconds

public int getTrackerTimoutSeconds()

setTrackerTimoutSeconds

public void setTrackerTimoutSeconds(int trackerTimoutSeconds)

isDisableBind

public boolean isDisableBind()

setDisableBind

public void setDisableBind(boolean disableBind)

isLimitTracker

public boolean isLimitTracker()

setLimitTracker

public void setLimitTracker(boolean limitTracker)

getIdleTCPMillis

public int getIdleTCPMillis()

setIdleTCPMillis

public void setIdleTCPMillis(int idleTCPMillis)

getIdleUDPMillis

public int getIdleUDPMillis()

setIdleUDPMillis

public void setIdleUDPMillis(int idleUDPMillis)

getConnectTimeoutMillis

public int getConnectTimeoutMillis()

setConnectTimeoutMillis

public void setConnectTimeoutMillis(int connectTimeouMillist)

setMaxOpenConnection

public void setMaxOpenConnection(int maxOpenConnection)

getMaxOpenConnection

public int getMaxOpenConnection()

getMaxCreating

public int getMaxCreating()

setMaxCreating

public void setMaxCreating(int maxCreating)

isForceTrackerTCP

public boolean isForceTrackerTCP()

setForceTrackerTCP

public void setForceTrackerTCP(boolean forceTrackerTCP)

isForceStorageUDP

public boolean isForceStorageUDP()

setForceStorageUDP

public void setForceStorageUDP(boolean forceStorageUDP)


Copyright © 2013. All Rights Reserved.