Service
CommSystemFacadeImpl
, VMCommSystem
public abstract class CommSystemFacade extends java.lang.Object implements Service
修飾子とタイプ | クラス | 説明 |
---|---|---|
static class |
CommSystemFacade.Status |
Since the codes may change.
|
修飾子とタイプ | フィールド | 説明 |
---|---|---|
static short |
STATUS_DIFFERENT |
We are behind a symmetric NAT which will make our 'from' address look
differently when we talk to multiple people
|
static short |
STATUS_DISCONNECTED |
We have no network interface at all enabled transports
|
static short |
STATUS_HOSED |
Our detection system is broken (SSU bind port failed)
|
static short |
STATUS_IPV4_DISABLED_IPV6_FIREWALLED |
We have an IPv6 transport enabled and a public IPv6 address.
|
static short |
STATUS_IPV4_DISABLED_IPV6_OK |
We have an IPv6 transport enabled and a public IPv6 address.
|
static short |
STATUS_IPV4_DISABLED_IPV6_UNKNOWN |
We have an IPv6 transport enabled and a public IPv6 address.
|
static short |
STATUS_IPV4_FIREWALLED_IPV6_OK |
We have an IPv6 transport enabled and a public IPv6 address.
|
static short |
STATUS_IPV4_FIREWALLED_IPV6_UNKNOWN |
We have an IPv6 transport enabled and a public IPv6 address.
|
static short |
STATUS_IPV4_OK_IPV6_FIREWALLED |
We have an IPv6 transport enabled and a public IPv6 address.
|
static short |
STATUS_IPV4_OK_IPV6_UNKNOWN |
We have an IPv6 transport enabled and a public IPv6 address.
|
static short |
STATUS_IPV4_SNAT_IPV6_OK |
We are behind a symmetric NAT which will make our 'from' address look
differently when we talk to multiple people
We can receive unsolicited connections on IPv6.
|
static short |
STATUS_IPV4_SNAT_IPV6_UNKNOWN |
We are behind a symmetric NAT which will make our 'from' address look
differently when we talk to multiple people
We might be able to receive unsolicited connections on IPv6.
|
static short |
STATUS_IPV4_UNKNOWN_IPV6_FIREWALLED |
We have an IPv6 transport enabled and a public IPv6 address.
|
static short |
STATUS_IPV4_UNKNOWN_IPV6_OK |
We have an IPv6 transport enabled and a public IPv6 address.
|
static short |
STATUS_OK |
These must be increasing in "badness" (see TransportManager.java),
but UNKNOWN must be last.
|
static short |
STATUS_REJECT_UNSOLICITED |
We are able to talk to peers that we initiate communication with, but
cannot receive unsolicited connections, i.e.
|
static short |
STATUS_UNKNOWN |
Our reachability is unknown on all
|
コンストラクタ | 説明 |
---|---|
CommSystemFacade() |
修飾子とタイプ | メソッド | 説明 |
---|---|---|
int |
countActivePeers() |
How many peers are we currently connected to, that we have
sent a message to or received a message from in the last five minutes.
|
int |
countActiveSendPeers() |
How many peers are we currently connected to, that we have
sent a message to in the last minute.
|
java.util.List<RouterAddress> |
createAddresses() |
Create the list of RouterAddress structures based on the router's config
|
java.lang.String |
getCountry(Hash peer) |
|
java.lang.String |
getCountryName(java.lang.String code) |
|
DHSessionKeyBuilder.Factory |
getDHFactory() |
Hook for pluggable transport creation.
|
long |
getFramedAveragePeerClockSkew(int percentToInclude) |
Return framed average clock skew of connected peers in seconds, or null if we cannot answer.
|
byte[] |
getIP(Hash dest) |
|
java.lang.Long |
getMedianPeerClockSkew() |
Median clock skew of connected peers in seconds, or null if we cannot answer.
|
java.util.List<java.lang.String> |
getMostRecentErrorMessages() |
|
java.lang.String |
getOurCountry() |
|
short |
getReachabilityStatus() |
推奨されていません。
use getStatus()
|
CommSystemFacade.Status |
getStatus() |
Determine under what conditions we are remotely reachable.
|
java.util.SortedMap<java.lang.String,Transport> |
getTransports() |
|
boolean |
haveHighOutboundCapacity() |
|
boolean |
haveInboundCapacity(int pct) |
|
boolean |
haveOutboundCapacity(int pct) |
|
boolean |
isBacklogged(Hash peer) |
|
boolean |
isDummy() |
|
boolean |
isEstablished(Hash peer) |
|
boolean |
isInBadCountry() |
|
boolean |
isInBadCountry(Hash peer) |
|
boolean |
isInBadCountry(RouterInfo ri) |
|
void |
mayDisconnect(Hash peer) |
Tell the comm system that we may disconnect from this peer.
|
void |
notifyRemoveAddress(boolean ipv6) |
Tell other transports our address changed
|
void |
notifyRemoveAddress(RouterAddress address) |
Tell other transports our address changed
|
void |
notifyReplaceAddress(RouterAddress address) |
Tell other transports our address changed
|
abstract void |
processMessage(OutNetMessage msg) |
|
void |
queueLookup(byte[] ip) |
|
void |
recheckReachability() |
推奨されていません。
unused
|
void |
registerTransport(Transport t) |
Pluggable transport
|
java.lang.String |
renderPeerHTML(Hash peer) |
|
void |
renderStatusHTML(java.io.Writer out) |
|
void |
renderStatusHTML(java.io.Writer out,
java.lang.String urlBase,
int sortFlags) |
|
void |
unregisterTransport(Transport t) |
Pluggable transport
|
boolean |
wasUnreachable(Hash peer) |
public static final short STATUS_OK
public static final short STATUS_IPV4_OK_IPV6_UNKNOWN
public static final short STATUS_IPV4_OK_IPV6_FIREWALLED
public static final short STATUS_IPV4_UNKNOWN_IPV6_OK
public static final short STATUS_IPV4_FIREWALLED_IPV6_OK
public static final short STATUS_IPV4_DISABLED_IPV6_OK
public static final short STATUS_IPV4_SNAT_IPV6_OK
public static final short STATUS_DIFFERENT
public static final short STATUS_IPV4_SNAT_IPV6_UNKNOWN
public static final short STATUS_IPV4_FIREWALLED_IPV6_UNKNOWN
public static final short STATUS_REJECT_UNSOLICITED
public static final short STATUS_IPV4_UNKNOWN_IPV6_FIREWALLED
public static final short STATUS_IPV4_DISABLED_IPV6_UNKNOWN
public static final short STATUS_IPV4_DISABLED_IPV6_FIREWALLED
public static final short STATUS_DISCONNECTED
public static final short STATUS_HOSED
public static final short STATUS_UNKNOWN
public abstract void processMessage(OutNetMessage msg)
public void renderStatusHTML(java.io.Writer out, java.lang.String urlBase, int sortFlags) throws java.io.IOException
java.io.IOException
public void renderStatusHTML(java.io.Writer out) throws java.io.IOException
renderStatusHTML
インタフェース内 Service
java.io.IOException
public java.util.List<RouterAddress> createAddresses()
public int countActivePeers()
public int countActiveSendPeers()
public boolean haveInboundCapacity(int pct)
public boolean haveOutboundCapacity(int pct)
public boolean haveHighOutboundCapacity()
public java.util.List<java.lang.String> getMostRecentErrorMessages()
public java.lang.Long getMedianPeerClockSkew()
public long getFramedAveragePeerClockSkew(int percentToInclude)
@Deprecated public short getReachabilityStatus()
public CommSystemFacade.Status getStatus()
@Deprecated public void recheckReachability()
public boolean isBacklogged(Hash peer)
public boolean wasUnreachable(Hash peer)
public boolean isEstablished(Hash peer)
public byte[] getIP(Hash dest)
public void queueLookup(byte[] ip)
public void mayDisconnect(Hash peer)
public java.lang.String getOurCountry()
public boolean isInBadCountry()
public boolean isInBadCountry(Hash peer)
public boolean isInBadCountry(RouterInfo ri)
public java.lang.String getCountry(Hash peer)
public java.lang.String getCountryName(java.lang.String code)
public java.lang.String renderPeerHTML(Hash peer)
public java.util.SortedMap<java.lang.String,Transport> getTransports()
public boolean isDummy()
public void notifyReplaceAddress(RouterAddress address)
public void notifyRemoveAddress(RouterAddress address)
public void notifyRemoveAddress(boolean ipv6)
public void registerTransport(Transport t)
public void unregisterTransport(Transport t)
public DHSessionKeyBuilder.Factory getDHFactory()