From: <hee...@us...> - 2009-10-08 08:00:58
|
Revision: 1881 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=1881&view=rev Author: heeroyuy Date: 2009-10-08 08:00:41 +0000 (Thu, 08 Oct 2009) Log Message: ----------- -started to implement new options in option panel Modified Paths: -------------- trunk/src/dl-learner/org/dllearner/tools/protege/OptionPanel.java Modified: trunk/src/dl-learner/org/dllearner/tools/protege/OptionPanel.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/protege/OptionPanel.java 2009-10-07 15:21:39 UTC (rev 1880) +++ trunk/src/dl-learner/org/dllearner/tools/protege/OptionPanel.java 2009-10-08 08:00:41 UTC (rev 1881) @@ -22,8 +22,11 @@ import java.awt.BorderLayout; import java.awt.GridLayout; +import javax.swing.JCheckBox; +import javax.swing.JComboBox; import javax.swing.JLabel; import javax.swing.JPanel; +import javax.swing.JRadioButton; import javax.swing.JSlider; /** * This Class is responsible for the Options of the DL-Learner. @@ -34,14 +37,42 @@ private static final long serialVersionUID = 2190682281812478244L; + private final JLabel minAccuracyLabel; private final JLabel maxExecutionTimeLabel; private final JLabel nrOfConceptsLabel; + private JLabel owlRadioButtonLabel; + private JLabel elProfileButtonLabel; + private JLabel allBoxLabel; + private JLabel someBoxLabel; + private JLabel notBoxLabel; + private JLabel valueBoxLabel; + private JLabel moreBoxLabel; + private JLabel lessBoxLabel; + private final JSlider minAccuracy; private final JSlider maxExecutionTime; private final JSlider nrOfConcepts; + + private JRadioButton owlRadioButton; + private JRadioButton elProfileButton; + + private JCheckBox allBox; + private JCheckBox someBox; + private JCheckBox notBox; + private JCheckBox valueBox; + private JCheckBox lessBox; + private JCheckBox moreBox; + + private JComboBox countLessBox; + private JComboBox countMoreBox; + + private JPanel profilePanel; + private JPanel radioBoxPanel; + private JPanel checkBoxPanel; private JPanel labelPanel; private JPanel sliderPanel; + private double accuracy; /** * Constructor for the Option Panel. @@ -52,9 +83,24 @@ labelPanel.setLayout(new GridLayout(0, 1)); sliderPanel = new JPanel(); sliderPanel.setLayout(new GridLayout(0, 1)); + profilePanel = new JPanel(); + profilePanel.setLayout(new GridLayout(0, 1)); + radioBoxPanel = new JPanel(); + radioBoxPanel.setLayout(new GridLayout(1, 4)); + checkBoxPanel = new JPanel(); + checkBoxPanel.setLayout(new GridLayout(1, 14)); + minAccuracyLabel = new JLabel("noise in %: "); maxExecutionTimeLabel = new JLabel("maximum execution time: "); nrOfConceptsLabel = new JLabel("max. number of results: "); + owlRadioButtonLabel = new JLabel("OWL 2"); + elProfileButtonLabel = new JLabel("EL Profile"); + allBoxLabel = new JLabel("all"); + someBoxLabel = new JLabel("some"); + notBoxLabel = new JLabel("not"); + valueBoxLabel = new JLabel("value"); + lessBoxLabel = new JLabel("<=x with max.:"); + moreBoxLabel = new JLabel(">=x with max.:"); minAccuracy = new JSlider(0, 50, 5); minAccuracy.setPaintTicks(true); @@ -75,7 +121,47 @@ nrOfConcepts.setMajorTickSpacing(2); nrOfConcepts.setMinorTickSpacing(1); nrOfConcepts.setPaintLabels(true); - + + owlRadioButton = new JRadioButton(); + elProfileButton = new JRadioButton(); + owlRadioButton.setEnabled(true); + + allBox = new JCheckBox(); + someBox = new JCheckBox(); + notBox = new JCheckBox(); + valueBox = new JCheckBox(); + lessBox = new JCheckBox(); + moreBox = new JCheckBox(); + + countLessBox = new JComboBox(); + countLessBox.setEditable(false); + countMoreBox = new JComboBox(); + countMoreBox.setEditable(false); + + checkBoxPanel.add(allBox); + checkBoxPanel.add(allBoxLabel); + checkBoxPanel.add(someBox); + checkBoxPanel.add(someBoxLabel); + checkBoxPanel.add(notBox); + checkBoxPanel.add(notBoxLabel); + checkBoxPanel.add(valueBox); + checkBoxPanel.add(valueBoxLabel); + checkBoxPanel.add(lessBox); + checkBoxPanel.add(lessBoxLabel); + checkBoxPanel.add(countLessBox); + checkBoxPanel.add(moreBox); + checkBoxPanel.add(moreBoxLabel); + checkBoxPanel.add(countMoreBox); + + + radioBoxPanel.add(owlRadioButton); + radioBoxPanel.add(owlRadioButtonLabel); + radioBoxPanel.add(elProfileButton); + radioBoxPanel.add(elProfileButtonLabel); + + profilePanel.add(radioBoxPanel); + profilePanel.add(checkBoxPanel); + labelPanel.add(minAccuracyLabel); labelPanel.add(maxExecutionTimeLabel); labelPanel.add(nrOfConceptsLabel); @@ -83,6 +169,8 @@ sliderPanel.add(minAccuracy); sliderPanel.add(maxExecutionTime); sliderPanel.add(nrOfConcepts); + + add(BorderLayout.SOUTH, profilePanel); add(BorderLayout.WEST, labelPanel); add(BorderLayout.CENTER, sliderPanel); } @@ -112,5 +200,89 @@ public int getNrOfConcepts() { return nrOfConcepts.getValue(); } + + public void setOwlRadioButton(JRadioButton owlRadioButton) { + this.owlRadioButton = owlRadioButton; + } + + public JRadioButton getOwlRadioButton() { + return owlRadioButton; + } + + public void setElProfileButton(JRadioButton elProfileButton) { + this.elProfileButton = elProfileButton; + } + + public JRadioButton getElProfileButton() { + return elProfileButton; + } + + public void setAllBox(JCheckBox allBox) { + this.allBox = allBox; + } + + public JCheckBox getAllBox() { + return allBox; + } + + public void setSomeBox(JCheckBox someBox) { + this.someBox = someBox; + } + + public JCheckBox getSomeBox() { + return someBox; + } + + public void setNotBox(JCheckBox notBox) { + this.notBox = notBox; + } + + public JCheckBox getNotBox() { + return notBox; + } + + public void setValueBox(JCheckBox valueBox) { + this.valueBox = valueBox; + } + + public JCheckBox getValueBox() { + return valueBox; + } + + public void setLessBox(JCheckBox lessBox) { + this.lessBox = lessBox; + } + + public JCheckBox getLessBox() { + return lessBox; + } + + public JPanel getProfilePanel() { + return profilePanel; + } + + public void setCountLessBox(JComboBox countLessBox) { + this.countLessBox = countLessBox; + } + + public JComboBox getCountLessBox() { + return countLessBox; + } + + public void setCountMoreBox(JComboBox countMoreBox) { + this.countMoreBox = countMoreBox; + } + + public JComboBox getCountMoreBox() { + return countMoreBox; + } + + public void setMoreBox(JCheckBox moreBox) { + this.moreBox = moreBox; + } + + public JCheckBox getMoreBox() { + return moreBox; + } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |