diff options
author | Eduardo Pedroni <ep625@york.ac.uk> | 2014-05-22 07:44:52 +0100 |
---|---|---|
committer | Eduardo Pedroni <ep625@york.ac.uk> | 2014-05-22 07:44:52 +0100 |
commit | 2b571f08d091dc062cedbb9816c29dcf0cbd4f12 (patch) | |
tree | 98505fe5fbd433eafe74a188f833b71a4627e08f /src/jcgp/backend/modules | |
parent | 9aac9892b5c827e70c4598e0e052d10aad40a2d9 (diff) |
Final commit, will release later today.
Diffstat (limited to 'src/jcgp/backend/modules')
-rw-r--r-- | src/jcgp/backend/modules/Module.java | 4 | ||||
-rw-r--r-- | src/jcgp/backend/modules/mutator/PointMutator.java | 2 | ||||
-rw-r--r-- | src/jcgp/backend/modules/problem/Problem.java | 3 | ||||
-rw-r--r-- | src/jcgp/backend/modules/problem/TestCaseProblem.java | 2 |
4 files changed, 5 insertions, 6 deletions
diff --git a/src/jcgp/backend/modules/Module.java b/src/jcgp/backend/modules/Module.java index a4d36c1..5dea93e 100644 --- a/src/jcgp/backend/modules/Module.java +++ b/src/jcgp/backend/modules/Module.java @@ -48,7 +48,7 @@ public abstract class Module { * * @return a list of generic parameters exposed by the module. */ - public final ArrayList<Parameter<?>> getLocalParameters() { + public ArrayList<Parameter<?>> getLocalParameters() { return localParameters; } @@ -62,7 +62,7 @@ public abstract class Module { * * @param newParameters the parameter(s) to add to the list. */ - protected final void registerParameters(Parameter<?>... newParameters) { + protected void registerParameters(Parameter<?>... newParameters) { for (int i = 0; i < newParameters.length; i++) { if (!localParameters.contains(newParameters[i])) { localParameters.add(newParameters[i]); diff --git a/src/jcgp/backend/modules/mutator/PointMutator.java b/src/jcgp/backend/modules/mutator/PointMutator.java index 6ba3e10..dd7aa7b 100644 --- a/src/jcgp/backend/modules/mutator/PointMutator.java +++ b/src/jcgp/backend/modules/mutator/PointMutator.java @@ -41,7 +41,7 @@ public abstract class PointMutator extends Mutator { // choose a random mutable Mutable mutable = chromosome.getRandomMutable(); - if (report.get()) getResources().report("[Mutator] Mutation " + i + " selected " + mutable); + if (report.get()) getResources().reportln("[Mutator] Mutation " + i + " selected " + mutable); // mutate a random gene mutable.mutate(); diff --git a/src/jcgp/backend/modules/problem/Problem.java b/src/jcgp/backend/modules/problem/Problem.java index 6785733..453e3a1 100644 --- a/src/jcgp/backend/modules/problem/Problem.java +++ b/src/jcgp/backend/modules/problem/Problem.java @@ -48,7 +48,7 @@ public abstract class Problem extends Module { * * @param resources a reference to the experiment's resources. */ - public Problem(Resources resources) { + protected Problem(Resources resources) { super(resources); maxFitness = new DoubleMonitor(0, "Max fitness"); @@ -72,7 +72,6 @@ public abstract class Problem extends Module { * if a GUI is in use. * * @param population the population to be evaluated. - * @param resources parameters and utilities for optional reference. */ public abstract void evaluate(Population population); diff --git a/src/jcgp/backend/modules/problem/TestCaseProblem.java b/src/jcgp/backend/modules/problem/TestCaseProblem.java index 964860c..82eb91a 100644 --- a/src/jcgp/backend/modules/problem/TestCaseProblem.java +++ b/src/jcgp/backend/modules/problem/TestCaseProblem.java @@ -71,7 +71,7 @@ public abstract class TestCaseProblem<T> extends Problem { * * @param resources a reference to the experiment's resources. */ - public TestCaseProblem(Resources resources) { + protected TestCaseProblem(Resources resources) { super(resources); testCases = FXCollections.observableArrayList(); } |