Saros
Distributed Collaborative Editing and Distributed Party Programming
|
Public Member Functions | |
boolean | isDirectConnectionAvailable () |
Collection< InetSocketAddress > | getPublicIpAddresses () |
Collection< InetSocketAddress > | discover (String stunAddress, int stunPort, int timeout) |
Static Public Attributes | |
static final int | DEFAULT_STUN_PORT = 3478 |
Collection<InetSocketAddress> de.fu_berlin.inf.dpp.net.stun.IStunService.discover | ( | String | stunAddress, |
int | stunPort, | ||
int | timeout | ||
) |
Starts a WAN (public / external) IP discovery of this system using STUN protocol RFC 5389 via UDP.
stunAddress | address of the STUN server |
stunPort | port of the STUN server, if 0 the default STUN port is used |
timeout | timeout in milliseconds before the discovery is aborted |
this method blocks until the discovery has finished or the timeout is exceeded
Implemented in de.fu_berlin.inf.dpp.net.stun.internal.StunServiceImpl.
Collection<InetSocketAddress> de.fu_berlin.inf.dpp.net.stun.IStunService.getPublicIpAddresses | ( | ) |
Returns the currently discovered public IP addresses. The collection will be empty if no discovery has performed yet, is still running or failed. The collection may also be incomplete if the discovery process has not finished for all network interfaces at the time this method is called.
Implemented in de.fu_berlin.inf.dpp.net.stun.internal.StunServiceImpl.
boolean de.fu_berlin.inf.dpp.net.stun.IStunService.isDirectConnectionAvailable | ( | ) |
Returns whether one of the available network interfaces is connected directly to the Internet.
true
if a network interfaces is connected directly to the Internet, false
otherwise or if no discovery was performed or is still running. Implemented in de.fu_berlin.inf.dpp.net.stun.internal.StunServiceImpl.
final int de.fu_berlin.inf.dpp.net.stun.IStunService.DEFAULT_STUN_PORT = 3478 [static] |