/*
 * Here comes the text of your license
 * Each line should be prefixed with  * 
 */

package nars.plugin.mental;

import nars.core.EventEmitter;
import nars.core.NAR;
import nars.core.Parameters;
import nars.core.Plugin;

/**
 *
 * @author tc
 */
public class RuntimeNARSettings implements Plugin {

    NAR n=null;
    @Override
    public boolean setEnabled(NAR n, boolean enabled) {
        this.n=n;
        return true;
    }

    public boolean isImmediateEternalization() {
        return Parameters.IMMEDIATE_ETERNALIZATION;
    }
    public void setImmediateEternalization(boolean val) {
        Parameters.IMMEDIATE_ETERNALIZATION=val;
    }
    
    public double getDuration() {
        return n.param.duration.get();
    }
    public void setDuration(double val) {
        n.param.duration.set((int) val);
    }
    
    public double getTemporalInductionPriority() {
        return Parameters.TEMPORAL_INDUCTION_CHAIN_SAMPLES;
    }
    public void setTemporalInductionPriority(double val) {
        Parameters.TEMPORAL_INDUCTION_CHAIN_SAMPLES=(int) val;
    }
    
    public double getEvidentalHorizon() {
        return Parameters.HORIZON;
    }
    public void setEvidentalHorizon(double val) {
        Parameters.HORIZON=(float) val;
    }
    
}

@@ -1260,10 +1260,730 @@
  %7D%0A    %0A
+    public boolean isInductionOnSucceedingEvents() %7B%0A        return Parameters.TEMPORAL_INDUCTION_ON_SUCCEEDING_EVENTS;%0A    %7D%0A    public void setInductionOnSucceedingEvents(boolean val) %7B%0A        Parameters.TEMPORAL_INDUCTION_ON_SUCCEEDING_EVENTS=val;%0A    %7D%0A    %0A    public double getInductionChainSamples() %7B%0A        return Parameters.TEMPORAL_INDUCTION_CHAIN_SAMPLES;%0A    %7D%0A    public void setInductionChainSamples(double val) %7B%0A        Parameters.TEMPORAL_INDUCTION_CHAIN_SAMPLES=(int) val;%0A    %7D%0A    %0A    public double getInductionSamples() %7B%0A        return Parameters.TEMPORAL_INDUCTION_SAMPLES;%0A    %7D%0A    public void setInductionSamples(double val) %7B%0A        Parameters.TEMPORAL_INDUCTION_SAMPLES=(int) val;%0A    %7D%0A
 %7D%0A

allow to change perception in RuntimeNARSettings plugin, for example it can be set back to 1.6.1 way of handling it. (if also PerceptionAccel is unloaded)