diff options
Diffstat (limited to 'src/jcgp/backend/resources/Resources.java')
-rw-r--r-- | src/jcgp/backend/resources/Resources.java | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/jcgp/backend/resources/Resources.java b/src/jcgp/backend/resources/Resources.java index c83fa35..0bf1ee1 100644 --- a/src/jcgp/backend/resources/Resources.java +++ b/src/jcgp/backend/resources/Resources.java @@ -21,7 +21,7 @@ import jcgp.backend.resources.parameters.ParameterStatus; public class Resources { protected IntegerParameter rows, columns, inputs, outputs, populationSize, levelsBack, currentGeneration, generations, currentRun, runs, - arity, seed, report; + arity, seed, reportInterval; protected Random numberGenerator = new Random(); protected FunctionSet functionSet; @@ -124,10 +124,10 @@ public class Resources { } /** - * @return the report + * @return the report interval */ - public int report() { - return report.get(); + public int reportInterval() { + return reportInterval.get(); } private void createBaseParameters() { @@ -273,7 +273,7 @@ public class Resources { }); numberGenerator.setSeed(seed.get()); - report = new IntegerParameter(1, "Report", false, false) { + reportInterval = new IntegerParameter(1, "Report interval", false, false) { @Override public void validate(Number newValue) { if (newValue.intValue() > generations.get()) { @@ -325,8 +325,8 @@ public class Resources { * These are affected by parameter report */ public void reportln(String s) { - if (report.get() > 0) { - if (currentGeneration.get() % report.get() == 0) { + if (reportInterval.get() > 0) { + if (currentGeneration.get() % reportInterval.get() == 0) { System.out.println(s); if (console != null) { console.println(s); @@ -336,8 +336,8 @@ public class Resources { } public void report(String s) { - if (report.get() > 0) { - if (currentGeneration.get() % report.get() == 0) { + if (reportInterval.get() > 0) { + if (currentGeneration.get() % reportInterval.get() == 0) { System.out.print(s); if (console != null) { console.print(s); |