forked from I2P_Developers/i2p.i2p
/debug:
- Add container divs and styling markup - Add top navigation menu
This commit is contained in:
@ -730,13 +730,13 @@ public class KBucketSet<T extends SimpleDataStructure> {
|
||||
public void getEntries(SelectionCollector<T> collector) {
|
||||
throw new UnsupportedOperationException();
|
||||
}
|
||||
|
||||
|
||||
public void clear() {}
|
||||
|
||||
public boolean add(T peer) {
|
||||
throw new UnsupportedOperationException();
|
||||
}
|
||||
|
||||
|
||||
public boolean remove(T peer) {
|
||||
return false;
|
||||
}
|
||||
@ -765,6 +765,7 @@ public class KBucketSet<T extends SimpleDataStructure> {
|
||||
@Override
|
||||
public String toString() {
|
||||
StringBuilder buf = new StringBuilder(1024);
|
||||
buf.append("<div class=\"debug_container buckets\">");
|
||||
buf.append("<hr><b>Bucket set rooted on:</b> ").append(_us.toString())
|
||||
.append(" K=").append(BUCKET_SIZE)
|
||||
.append(" B=").append(B_VALUE)
|
||||
@ -779,6 +780,7 @@ public class KBucketSet<T extends SimpleDataStructure> {
|
||||
buf.append(b.toString()).append("<br>\n");
|
||||
}
|
||||
} finally { releaseReadLock(); }
|
||||
buf.append("</div>");
|
||||
return buf.toString();
|
||||
}
|
||||
}
|
||||
|
@ -179,7 +179,7 @@ public class PortMapper {
|
||||
*/
|
||||
public void renderStatusHTML(Writer out) throws IOException {
|
||||
List<String> services = new ArrayList<String>(_dir.keySet());
|
||||
out.write("<h2>Port Mapper</h2><table><tr><th>Service<th>Host<th>Port\n");
|
||||
out.write("<h2 id=\"debug_portmapper\">Port Mapper</h2><table id=\"portmapper\"><tr><th>Service<th>Host<th>Port\n");
|
||||
Collections.sort(services);
|
||||
for (String s : services) {
|
||||
InetSocketAddress ia = _dir.get(s);
|
||||
|
Reference in New Issue
Block a user