move TunnelPoolManager renderStatusHTML to routerconsole

This commit is contained in:
zzz
2009-10-17 23:49:59 +00:00
parent 011a32f741
commit 10b84418c3
5 changed files with 356 additions and 251 deletions

View File

@@ -9,13 +9,14 @@ public class TunnelHelper extends HelperBase {
public TunnelHelper() {}
public String getTunnelSummary() {
TunnelRenderer renderer = new TunnelRenderer(_context);
try {
if (_out != null) {
_context.tunnelManager().renderStatusHTML(_out);
renderer.renderStatusHTML(_out);
return "";
} else {
ByteArrayOutputStream baos = new ByteArrayOutputStream(32*1024);
_context.tunnelManager().renderStatusHTML(new OutputStreamWriter(baos));
renderer.renderStatusHTML(new OutputStreamWriter(baos));
return new String(baos.toByteArray());
}
} catch (IOException ioe) {