diff --git a/src/javaeva/client/EvAClient.java b/src/javaeva/client/EvAClient.java index 8461d73b..d6e2a319 100644 --- a/src/javaeva/client/EvAClient.java +++ b/src/javaeva/client/EvAClient.java @@ -344,7 +344,7 @@ public class EvAClient implements RemoteStateListener, Serializable { xx.start(); } }; - m_actKillAllHosts = new ExtAction("Kill &all server", "Kill all server", + m_actKillAllHosts = new ExtAction("Kill &all servers", "Kill all servers", KeyStroke.getKeyStroke(KeyEvent.VK_K, Event.CTRL_MASK)) { public void actionPerformed(ActionEvent e) { logMessage(e.getActionCommand()); diff --git a/src/javaeva/gui/GenericObjectEditor.java b/src/javaeva/gui/GenericObjectEditor.java index 7e35016f..14d2a56b 100644 --- a/src/javaeva/gui/GenericObjectEditor.java +++ b/src/javaeva/gui/GenericObjectEditor.java @@ -721,7 +721,7 @@ public class GenericObjectEditor implements PropertyEditor { * appear possible given that the initialization string isn't supposed to * contain multiple statements. * - * @return the java source code initialisation string + * @return the java source code initialization string */ public String getJavaInitializationString() { return "new " + m_Object.getClass().getName() + "()"; diff --git a/src/javaeva/gui/PropertyDialog.java b/src/javaeva/gui/PropertyDialog.java index 79182276..231dded1 100644 --- a/src/javaeva/gui/PropertyDialog.java +++ b/src/javaeva/gui/PropertyDialog.java @@ -34,8 +34,8 @@ public class PropertyDialog extends JEFrame { /** * */ - public PropertyDialog (PropertyEditor Editor,String Title, int x, int y) { - super(EVAHELP.cutClassName (Editor.getValue().getClass().getName())); // that was the long class name !! + public PropertyDialog (PropertyEditor editor,String Title, int x, int y) { + super(getFrameNameFromEditor(editor)); // that was the long class name !! BasicResourceLoader loader = BasicResourceLoader.instance(); byte[] bytes = loader.getBytesFromResourceLocation(EvAClient.iconLocation); try { @@ -50,13 +50,27 @@ public class PropertyDialog extends JEFrame { } }); getContentPane().setLayout(new BorderLayout()); - m_Editor = Editor; - m_EditorComponent = Editor.getCustomEditor(); + m_Editor = editor; + m_EditorComponent = editor.getCustomEditor(); getContentPane().add(m_EditorComponent, BorderLayout.CENTER); pack(); setLocation(x, y); setVisible(true); } + + protected static String getFrameNameFromEditor(PropertyEditor editor) { + return EVAHELP.cutClassName(editor.getValue().getClass().getName()); + } + + /** + * Update the name of the dialogue from an editor instance. + * + * @param editor + */ + public void updateFrameTitle(PropertyEditor editor) { + setTitle(getFrameNameFromEditor(editor)); + } + /** * */ diff --git a/src/javaeva/gui/PropertyPanel.java b/src/javaeva/gui/PropertyPanel.java index ab9a2eab..36e9e8c5 100644 --- a/src/javaeva/gui/PropertyPanel.java +++ b/src/javaeva/gui/PropertyPanel.java @@ -48,8 +48,10 @@ public class PropertyPanel extends JPanel { int y = getLocationOnScreen().y; m_PropertyDialog = new PropertyDialog(m_PropertyEditor, EVAHELP.cutClassName(m_PropertyEditor.getClass().getName()) , x, y); } - else + else { + m_PropertyDialog.updateFrameTitle(m_PropertyEditor); m_PropertyDialog.setVisible(true); + } } } }); diff --git a/src/javaeva/server/go/operators/selection/SelectTournament.java b/src/javaeva/server/go/operators/selection/SelectTournament.java index be422d46..47dfa400 100644 --- a/src/javaeva/server/go/operators/selection/SelectTournament.java +++ b/src/javaeva/server/go/operators/selection/SelectTournament.java @@ -117,7 +117,7 @@ public class SelectTournament implements InterfaceSelection, java.io.Serializabl */ public String globalInfo() { return "The tournament selection compares the raw fitness of n individuals and takes the best." + - "This is a single objective selecting method, it will select in respect to a random criteria."; + "This is a single-objective method, it will select with respect to the first criterium in the multi-objective case."; } /** You can choose the tournament size. diff --git a/src/javaeva/server/go/populations/Population.java b/src/javaeva/server/go/populations/Population.java index eb57f8e8..a98f607f 100644 --- a/src/javaeva/server/go/populations/Population.java +++ b/src/javaeva/server/go/populations/Population.java @@ -204,7 +204,6 @@ public class Population extends ArrayList implements PopulationInterface, Clonea double curBestFitness = Double.POSITIVE_INFINITY; for (int i = 0; i < super.size(); i++) { - //System.out.println("Fitness " + i + " " + ((AbstractEAIndividual)super.get(i)).getFitness(0)); if ((!((AbstractEAIndividual)super.get(i)).violatesConstraint()) && (((AbstractEAIndividual)super.get(i)).getFitness(0) < curBestFitness)) { result = i; curBestFitness = ((AbstractEAIndividual)super.get(i)).getFitness(0); @@ -405,7 +404,7 @@ public class Population extends ArrayList implements PopulationInterface, Clonea * @return description */ public String globalInfo() { - return "A population stores all current soultions and is used to determine the optimizing progress."; + return "A population stores the individuals of a generation."; } /** This method allows you to set the population size diff --git a/src/javaeva/server/go/strategies/PopulationBasedIncrementalLearning.java b/src/javaeva/server/go/strategies/PopulationBasedIncrementalLearning.java index 713908ce..661d2dd6 100644 --- a/src/javaeva/server/go/strategies/PopulationBasedIncrementalLearning.java +++ b/src/javaeva/server/go/strategies/PopulationBasedIncrementalLearning.java @@ -172,7 +172,7 @@ public class PopulationBasedIncrementalLearning implements InterfaceOptimizer, j * @return description */ public String globalInfo() { - return "The Population based incremental learing is based on a statistical distribution of bit positions."; + return "The Population based incremental learning is based on a statistical distribution of bit positions. Please note: This optimizer requires a binary genotype!"; } /** This method will return a naming String * @return The name of the algorithm diff --git a/src/javaeva/server/modules/PBILParameters.java b/src/javaeva/server/modules/PBILParameters.java index abb76bff..4d2df48e 100644 --- a/src/javaeva/server/modules/PBILParameters.java +++ b/src/javaeva/server/modules/PBILParameters.java @@ -113,7 +113,7 @@ public class PBILParameters implements InterfaceGOParameters, Serializable { * @return description */ public String globalInfo() { - return "Please note: This optimizer requires a BitSet as genotype!!"; + return ((PopulationBasedIncrementalLearning)this.m_Optimizer).globalInfo(); } /** This methods allow you to set and get the Seed for the Random Number Generator.