net.i2p.router
Class Shitlist

java.lang.Object
  extended by net.i2p.router.Shitlist

public class Shitlist
extends java.lang.Object

Routers are shitlisted only if none of our transports can talk to them or their signed router info is completely screwy. Individual transports manage their own unreachable lists and do not generally add to the overall shitlist.


Nested Class Summary
static class Shitlist.Entry
           
 
Field Summary
static long SHITLIST_CLEANER_START_DELAY
           
static long SHITLIST_DURATION_FOREVER
           
static long SHITLIST_DURATION_MAX
           
static long SHITLIST_DURATION_MS
           
static long SHITLIST_DURATION_PARTIAL
           
 
Constructor Summary
Shitlist(RouterContext context)
           
 
Method Summary
 java.util.Map<Hash,Shitlist.Entry> getEntries()
          for ShitlistRenderer in router console
 int getRouterCount()
           
 boolean isShitlisted(Hash peer)
           
 boolean isShitlisted(Hash peer, java.lang.String transport)
           
 boolean isShitlistedForever(Hash peer)
           
 void renderStatusHTML(java.io.Writer out)
          Deprecated. moved to router console
 boolean shitlistRouter(Hash peer)
           
 boolean shitlistRouter(Hash peer, java.lang.String reason)
           
 boolean shitlistRouter(Hash peer, java.lang.String reason, java.lang.String transport)
           
 boolean shitlistRouter(Hash peer, java.lang.String reason, java.lang.String transport, boolean forever)
           
 boolean shitlistRouter(java.lang.String reasonCode, Hash peer, java.lang.String reason)
          ick have to put the reasonCode in the front to avoid ambiguity
 boolean shitlistRouterForever(Hash peer, java.lang.String reason)
           
 boolean shitlistRouterForever(Hash peer, java.lang.String reason, java.lang.String reasonCode)
           
 void unshitlistRouter(Hash peer)
           
 void unshitlistRouter(Hash peer, java.lang.String transport)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SHITLIST_DURATION_MS

public static final long SHITLIST_DURATION_MS
See Also:
Constant Field Values

SHITLIST_DURATION_MAX

public static final long SHITLIST_DURATION_MAX
See Also:
Constant Field Values

SHITLIST_DURATION_PARTIAL

public static final long SHITLIST_DURATION_PARTIAL
See Also:
Constant Field Values

SHITLIST_DURATION_FOREVER

public static final long SHITLIST_DURATION_FOREVER
See Also:
Constant Field Values

SHITLIST_CLEANER_START_DELAY

public static final long SHITLIST_CLEANER_START_DELAY
See Also:
Constant Field Values
Constructor Detail

Shitlist

public Shitlist(RouterContext context)
Method Detail

getRouterCount

public int getRouterCount()

getEntries

public java.util.Map<Hash,Shitlist.Entry> getEntries()
for ShitlistRenderer in router console


shitlistRouter

public boolean shitlistRouter(Hash peer)

shitlistRouter

public boolean shitlistRouter(Hash peer,
                              java.lang.String reason)

shitlistRouter

public boolean shitlistRouter(java.lang.String reasonCode,
                              Hash peer,
                              java.lang.String reason)
ick have to put the reasonCode in the front to avoid ambiguity


shitlistRouter

public boolean shitlistRouter(Hash peer,
                              java.lang.String reason,
                              java.lang.String transport)

shitlistRouterForever

public boolean shitlistRouterForever(Hash peer,
                                     java.lang.String reason)

shitlistRouterForever

public boolean shitlistRouterForever(Hash peer,
                                     java.lang.String reason,
                                     java.lang.String reasonCode)

shitlistRouter

public boolean shitlistRouter(Hash peer,
                              java.lang.String reason,
                              java.lang.String transport,
                              boolean forever)

unshitlistRouter

public void unshitlistRouter(Hash peer)

unshitlistRouter

public void unshitlistRouter(Hash peer,
                             java.lang.String transport)

isShitlisted

public boolean isShitlisted(Hash peer)

isShitlisted

public boolean isShitlisted(Hash peer,
                            java.lang.String transport)

isShitlistedForever

public boolean isShitlistedForever(Hash peer)

renderStatusHTML

public void renderStatusHTML(java.io.Writer out)
                      throws java.io.IOException
Deprecated. moved to router console

Throws:
java.io.IOException