Changeset e122393 for apps


Ignore:
Timestamp:
Dec 23, 2018 11:08:50 AM (17 months ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
fa6a4ca1
Parents:
2d026d5
Message:

FormHandler?: move things around

Location:
apps/routerconsole/java/src/net/i2p/router/web
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • apps/routerconsole/java/src/net/i2p/router/web/FormHandler.java

    r2d026d5 re122393  
    11package net.i2p.router.web;
    22
     3import java.io.Writer;
    34import java.util.ArrayList;
    45import java.util.HashMap;
     
    3738    private boolean _processed;
    3839    private boolean _valid;
     40    protected Writer _out;
    3941   
    4042    public FormHandler() {
     
    112114
    113115    /**
     116     * @since 0.9.38
     117     */
     118    public void storeWriter(Writer out) { _out = out; }
     119
     120    /**
    114121     * The old nonces from the session
    115122     * @since 0.9.4
     
    121128   
    122129    /**
    123      * Override this to perform the final processing (in turn, adding formNotice
     130     * Implement this to perform the final processing (in turn, adding formNotice
    124131     * and formError messages, etc)
    125132     *
    126133     */
    127     protected void processForm() {}
     134    protected abstract void processForm();
    128135   
    129136    /**
  • apps/routerconsole/java/src/net/i2p/router/web/helpers/EventLogHelper.java

    r2d026d5 re122393  
    22
    33import java.io.IOException;
    4 import java.io.Writer;
    54import java.text.Collator;
    65import java.text.DateFormat;
     
    2524 */
    2625public class EventLogHelper extends FormHandler {
    27     protected Writer _out;
    2826    private long _from, _age;
    2927    //private long _to = Long.MAX_VALUE;
     
    6462    }
    6563
     64    protected void processForm() {}
     65
    6666    /** set the defaults after we have a context */
    6767    @Override
     
    7373    }
    7474   
    75     public void storeWriter(Writer out) { _out = out; }
    76 
    7775    public void setFrom(String s) {
    7876        try {
  • apps/routerconsole/java/src/net/i2p/router/web/helpers/GraphHelper.java

    r2d026d5 re122393  
    33import java.io.IOException;
    44import java.io.Serializable;
    5 import java.io.Writer;
    65import java.util.Comparator;
    76import java.util.HashMap;
     
    2625 */
    2726public class GraphHelper extends FormHandler {
    28     protected Writer _out;
    2927    private int _periodCount;
    3028    private boolean _showEvents;
     
    7472        return "<meta http-equiv=\"refresh\" content=\"" + (_refreshDelaySeconds - 3) + "\">";
    7573    }
    76 
    77     /**
    78      *  This was a HelperBase but now it's a FormHandler
    79      *  @since 0.8.2
    80      */
    81     public void storeWriter(Writer out) { _out = out; }
    8274
    8375    public void setPeriodCount(String str) {
Note: See TracChangeset for help on using the changeset viewer.