* Routerconsole:

- Move common methods to new HelperBase class
      - Make reseed link a button
This commit is contained in:
zzz
2009-01-29 02:16:18 +00:00
parent 9d9d4093bc
commit 69e6393442
27 changed files with 63 additions and 351 deletions

View File

@@ -7,29 +7,12 @@ import java.io.Writer;
import net.i2p.router.RouterContext;
public class NetDbHelper {
private RouterContext _context;
private Writer _out;
public class NetDbHelper extends HelperBase {
private String _routerPrefix;
private boolean _full = false;
/**
* Configure this bean to query a particular router context
*
* @param contextId begging few characters of the routerHash, or null to pick
* the first one we come across.
*/
public void setContextId(String contextId) {
try {
_context = ContextHelper.getContext(contextId);
} catch (Throwable t) {
t.printStackTrace();
}
}
public NetDbHelper() {}
public void setWriter(Writer writer) { _out = writer; }
public void setRouter(String r) { _routerPrefix = r; }
public void setFull(String f) { _full = "1".equals(f); };