From: <lor...@us...> - 2009-09-10 15:19:03
|
Revision: 1841 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=1841&view=rev Author: lorenz_b Date: 2009-09-10 15:18:56 +0000 (Thu, 10 Sep 2009) Log Message: ----------- fixed bug when loading from recent Modified Paths: -------------- trunk/src/dl-learner/org/dllearner/tools/ore/RecentManager.java trunk/src/dl-learner/org/dllearner/tools/ore/explanation/laconic/LaconicExplanationGenerator.java trunk/src/dl-learner/org/dllearner/tools/ore/recent.txt trunk/src/dl-learner/org/dllearner/tools/ore/ui/MetricsPanel.java trunk/src/dl-learner/org/dllearner/tools/ore/ui/wizard/Wizard.java trunk/src/dl-learner/org/dllearner/tools/ore/ui/wizard/descriptors/KnowledgeSourcePanelDescriptor.java Added Paths: ----------- trunk/src/dl-learner/org/dllearner/tools/ore/PelletBug.java trunk/src/dl-learner/org/dllearner/tools/ore/Sparql.java trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton.java trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton2.java trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton3.java Added: trunk/src/dl-learner/org/dllearner/tools/ore/PelletBug.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/PelletBug.java (rev 0) +++ trunk/src/dl-learner/org/dllearner/tools/ore/PelletBug.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -0,0 +1,50 @@ +package org.dllearner.tools.ore; + +import java.net.URI; +import java.util.Collections; + +import org.mindswap.pellet.owlapi.PelletReasonerFactory; +import org.mindswap.pellet.owlapi.Reasoner; +import org.semanticweb.owl.apibinding.OWLManager; +import org.semanticweb.owl.model.OWLClass; +import org.semanticweb.owl.model.OWLDataFactory; +import org.semanticweb.owl.model.OWLDataProperty; +import org.semanticweb.owl.model.OWLDataPropertyDomainAxiom; +import org.semanticweb.owl.model.OWLDataRange; +import org.semanticweb.owl.model.OWLDataSomeRestriction; +import org.semanticweb.owl.model.OWLOntology; +import org.semanticweb.owl.model.OWLOntologyCreationException; +import org.semanticweb.owl.model.OWLOntologyManager; +import org.semanticweb.owl.model.OWLSubClassAxiom; + +import com.clarkparsia.explanation.PelletExplanation; + +public class PelletBug { + public static void main(String[] args) throws OWLOntologyCreationException { + String file = "http://protege.stanford.edu/plugins/owl/owl-library/koala.owl"; + String NS = "http://protege.stanford.edu/plugins/owl/owl-library/koala.owl"; + OWLOntologyManager manager = OWLManager.createOWLOntologyManager(); + OWLDataFactory factory = manager.getOWLDataFactory(); + OWLOntology ontology = manager.loadOntology(URI.create(file)); + Reasoner reasoner = new PelletReasonerFactory().createReasoner(manager); + reasoner.loadOntology(ontology); + + + OWLDataProperty property = factory.getOWLDataProperty(URI.create(NS + "#isHardWorking")); + OWLClass domain = factory.getOWLClass(URI.create(NS + "#Animal")); + OWLDataPropertyDomainAxiom axiom = factory.getOWLDataPropertyDomainAxiom(property, domain); + + PelletExplanation expGen = new PelletExplanation(manager, Collections.singleton(ontology)); + System.out.println(reasoner.isEntailed(axiom)); + +// System.out.println(expGen.getEntailmentExplanations(axiom)); +// +// OWLDataRange range = factory.getTopDataType(); +// OWLDataSomeRestriction dataSome = factory.getOWLDataSomeRestriction(property, range); +// OWLSubClassAxiom subClass = factory.getOWLSubClassAxiom(dataSome, domain); +// +// System.out.println(reasoner.isEntailed(subClass)); +// System.out.println(expGen.getEntailmentExplanations(subClass)); + + } +} Modified: trunk/src/dl-learner/org/dllearner/tools/ore/RecentManager.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/RecentManager.java 2009-09-10 11:37:40 UTC (rev 1840) +++ trunk/src/dl-learner/org/dllearner/tools/ore/RecentManager.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -39,8 +39,6 @@ } public List<URI> getURIs(){ - uriList.clear(); - deserialize(); return uriList; } @@ -62,7 +60,7 @@ } @SuppressWarnings("unchecked") - private void deserialize() { + public void deserialize() { try { FileInputStream fileStream = new FileInputStream(file); ObjectInputStream inputStream = new ObjectInputStream( @@ -77,7 +75,7 @@ inputStream.close(); } } catch (IOException e) { - e.printStackTrace(); + System.err.println("Can't read recent successfully opened URIs. Starting with empty list."); } catch (ClassNotFoundException e) { e.printStackTrace(); } Added: trunk/src/dl-learner/org/dllearner/tools/ore/Sparql.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/Sparql.java (rev 0) +++ trunk/src/dl-learner/org/dllearner/tools/ore/Sparql.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -0,0 +1,24 @@ +package org.dllearner.tools.ore; + +import java.net.MalformedURLException; +import java.net.URL; + +import org.dllearner.kb.sparql.SPARQLTasks; +import org.dllearner.kb.sparql.SparqlEndpoint; + +public class Sparql { + + /** + * @param args + * @throws MalformedURLException + */ + public static void main(String[] args) throws MalformedURLException { + URL url = new URL("http://dbpedia.org/sparql"); + SPARQLTasks task = new SPARQLTasks(SparqlEndpoint.getEndpointDBpedia());//new SparqlEndpoint(url)); + + String queryString = "SELECT DISTINCT ?class WHERE {?class rdf:type owl:Class ." + + "?class rdfs:label ?label . FILTER(regex(?label, \"City\")) }"; + System.out.println(task.queryAsSet(queryString, "class")); + } + +} Modified: trunk/src/dl-learner/org/dllearner/tools/ore/explanation/laconic/LaconicExplanationGenerator.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/explanation/laconic/LaconicExplanationGenerator.java 2009-09-10 11:37:40 UTC (rev 1840) +++ trunk/src/dl-learner/org/dllearner/tools/ore/explanation/laconic/LaconicExplanationGenerator.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -6,9 +6,12 @@ import java.util.HashSet; import java.util.Map; import java.util.Set; +import java.util.logging.Level; +import java.util.logging.Logger; import org.dllearner.tools.ore.explanation.Explanation; import org.dllearner.tools.ore.explanation.ExplanationException; +import org.dllearner.tools.ore.explanation.HSTExplanationGenerator; import org.dllearner.tools.ore.explanation.PelletExplanationGenerator; import org.mindswap.pellet.owlapi.PelletReasonerFactory; import org.semanticweb.owl.apibinding.OWLManager; @@ -25,6 +28,9 @@ import org.semanticweb.owl.model.OWLOntologyManager; import org.semanticweb.owl.model.OWLSubClassAxiom; +import com.clarkparsia.explanation.util.ExplanationProgressMonitor; +import com.clarkparsia.explanation.util.SilentExplanationProgressMonitor; + /* * This class computes laconic explanations for a given entailment. The algorithm is adapted from the paper * 'Laconic and Precise Justifications in OWL' from Matthew Horridge, Bijan Parsia and Ulrike Sattler. @@ -40,6 +46,11 @@ private Set<Explanation> allPreviouslyFoundExplanations; private OPlus oPlus; + public static final Logger log = Logger.getLogger(LaconicExplanationGenerator.class + .getName()); + + private ExplanationProgressMonitor progressMonitor = new SilentExplanationProgressMonitor(); + public LaconicExplanationGenerator(OWLOntologyManager manager, OWLReasonerFactory reasonerFactory, Set<OWLOntology> ontologies) { @@ -82,6 +93,11 @@ return lastRegularExplanations; } + public void setProgressMonitor(ExplanationProgressMonitor mon){ + this.progressMonitor = mon; + pelletExplanation.setProgressMonitor(progressMonitor); + } + /** * Computes the precise explanations * @param entailment @@ -89,15 +105,15 @@ * @return * @throws OWLException */ - public Set<Explanation> computePreciseJusts(OWLAxiom entailment, int limit) + private Set<Explanation> computePreciseJusts(OWLAxiom entailment, int limit) throws OWLException { Set<Explanation> regularExplanations = pelletExplanation .getExplanations((OWLAxiom) entailment); - System.out.println(new StringBuilder().append( - "Got regular justifications: ").append(regularExplanations.size()) - .toString()); + if (log.isLoggable(Level.CONFIG)){ + log.config("Found " + regularExplanations.size() + " regular explanations"); + } lastRegularExplanations.clear(); lastRegularExplanations.addAll(regularExplanations); allPreviouslyFoundExplanations = new HashSet<Explanation>(); @@ -105,11 +121,13 @@ Set<Explanation> nonLaconicExplanations = new HashSet<Explanation>(); Set<Explanation> laconicExplanations = new HashSet<Explanation>(); Set<OWLAxiom> axiomsInPreviousOntology = new HashSet<OWLAxiom>(); - long counter = 0L; + for (;;) { - counter++; - System.out.println(new StringBuilder().append("Count ").append( - counter).toString()); + if (progressMonitor.isCancelled()) { + return laconicExplanations; + } + + Set<OWLAxiom> unionOfAllExplanations = new HashSet<OWLAxiom>(); for (Explanation expl : allPreviouslyFoundExplanations) { unionOfAllExplanations.addAll(expl.getAxioms()); @@ -129,8 +147,9 @@ if (extendedOntology.getLogicalAxioms().equals( axiomsInPreviousOntology)) { - System.out - .println("\t ***** No change in ontology. Early termination."); + if (log.isLoggable(Level.CONFIG)){ + log.config(""); + } break; } // man2.saveOntology(extendedOnt, @@ -283,7 +302,7 @@ throws ExplanationException { Set<Explanation> explanations; try { - explanations = computePreciseJusts(entailment, 2147483647); + explanations = computePreciseJusts(entailment, Integer.MAX_VALUE); } catch (OWLException e) { throw new ExplanationException(e); } @@ -292,6 +311,8 @@ public Set<Explanation> getExplanations(OWLAxiom entailment, int limit) throws ExplanationException { + if (log.isLoggable(Level.CONFIG)) + log.config("Get " + (limit == Integer.MAX_VALUE ? "all" : limit) + " explanation(s) for: " + entailment); Set<Explanation> explanations; try { explanations = computePreciseJusts(entailment, limit); Modified: trunk/src/dl-learner/org/dllearner/tools/ore/recent.txt =================================================================== (Binary files differ) Modified: trunk/src/dl-learner/org/dllearner/tools/ore/ui/MetricsPanel.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/ui/MetricsPanel.java 2009-09-10 11:37:40 UTC (rev 1840) +++ trunk/src/dl-learner/org/dllearner/tools/ore/ui/MetricsPanel.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -289,7 +289,7 @@ for (OWLMetricManager man : metricManagerMap.values()) { man.setOntology(activeOntology); } - TitledBorder border = new TitledBorder(activeOntology.getURI().toString()); + TitledBorder border = new TitledBorder(activeOntology.getURI().toString() + " successfully loaded"); border.setTitleFont(getFont().deriveFont(Font.BOLD, 12.0f)); border.setTitleColor(PropertyUtil.getColor(ProtegeProperties.getInstance().getProperty(ProtegeProperties.PROPERTY_COLOR_KEY), Color.GRAY)); Added: trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton.java (rev 0) +++ trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -0,0 +1,191 @@ +package org.dllearner.tools.ore.ui; + +//Imports for the GUI classes. +import java.awt.*; +import javax.swing.*; +import java.awt.event.*; + +/** + * RoundButton.java - + * A custom JComponent that is a round button. The round button + * will be empty until the mouse enters the circle. When the + * mouse enters the circle it will be filled in with a specified + * color. Then when the mouse is pressed the color will change + * to a second specified color. Note that RoundButton "is a" + * MouseListener so it can handle its own MouseEvents. + * + * @author Grant William Braught + * @author Dickinson College + * @version 11/29/2000 + */ +public class RoundButton + extends JComponent + implements MouseListener { + + private Color mouseOverColor; + private Color mousePressedColor; + + private boolean mouseOver; + private boolean mousePressed; + + + /** + * Construct a new RoundButton with the specified + * colors for mouse over and mouse pressed events. + * + * @param mouseOverColor the color the button should + * be filled with when the mouse is + * over the button. + * @param mousePressedColor the color the button should be + * filled with when the mouse + * is pressed on the button. + */ + public RoundButton(Color mouseOverColor, + Color mousePressedColor) { + this.mouseOverColor = mouseOverColor; + this.mousePressedColor = mousePressedColor; + mouseOver = false; + mousePressed = false; + + // Make this object a MouseListener for itself. This + // ensures that the MouseEvents ocurring on this JComponet + // will be routed to this object. NOTE: "this" is a + // reference to a RoundButton and a RoundButton "is a" + // JComponent so it has an addMouseListener() method that + // accepts a MouseListener object. Since RoundButton + // implements MouseListener it "is a" MouseListener. + this.addMouseListener(this); + } + + /** + * Default constructor that sets the mouse over color + * to blue and the mouse pressed color to red. + */ + public RoundButton() { + this(Color.blue, Color.red); + } + + /** + * Paint the RoundButton on the screen each time the + * window is redrawn. Recall that the paint() method + * of each JComponent in the content pane is called + * automatically when the window is redrawn. This + * overrides paint() from JComponent so we have control + * over what the RoundButton will look like when it is + * painted. + * + * @param g the Graphics context on which to paint the + * button. + */ + public void paint(Graphics g) { + // Check mouse pressed first because if the mouse + // is pressed it will also be in the button. + if (mousePressed && mouseOver) { + g.setColor(mousePressedColor); + g.fillOval(0,0,100,100); + } + else if (mouseOver) { + g.setColor(mouseOverColor); + g.fillOval(0,0,100,100); + } + else { + g.setColor(Color.black); + g.drawOval(0,0,100,100); + } + } + + /** + * Return the minimum size that our button would + * like to be. This overrides getMinimumSize from + * JComponent which returns 0x0. + * + * @return the minimum size of the RoundButton. + */ + public Dimension getMinimumSize() { + return new Dimension(100,100); + } + + /** + * Return the ideal size that our button would + * like to be. This overrides the getPreferredSize + * from JComponent which returns 0x0. + * + * @return the preferred size of the RoundButton. + */ + public Dimension getPreferredSize() { + return new Dimension(100,100); + } + + // Methods from the MouseListener Interface. + /** + * Handler called when the mouse is clicked on + * the RoundButton. + * + * @param e reference to a MouseEvent object describing + * the mouse click. + */ + public void mouseClicked(MouseEvent e) {} + + /** + * Handler called when the mouse enters the + * RoundButton. This is called when the mouse + * enters the bounding rectangle of the JComponent + * not when it enters the circle! (See RoundButton2 + * for a fix.) + * + * @param e reference to a MouseEvent object describing + * the mouse entry. + */ + public void mouseEntered(MouseEvent e) { + mouseOver = true; + + // Calling repaint() causes the component to be repainted. + // repaint() makes a call to paint() but also does a few + // other things related to the maintainence of the window + // and layout. Therefore, you should never call paint() + // directly. If you want the component to be repainted, + // call repaint(). + repaint(); + } + + /** + * Handler called when the mouse exits the + * RoundButton. Again, this is called when the + * mouse exits the bounding rectangle. + * + * @param e reference to a MouseEvent object describing + * the mouse exit. + */ + public void mouseExited(MouseEvent e) { + mouseOver = false; + repaint(); + } + + /** + * Handler called when the mouse button is pressed + * over the RoundButton. Again this is called if the + * button is pressed anywhere within the bounding + * rectangle. + * + * @param e reference to a MouseEvent object describing + * the mouse press. + */ + public void mousePressed(MouseEvent e) { + mousePressed = true; + repaint(); + } + + /** + * Handler called when the mosue button is released + * over the RoundButton. Blah... Blah.. bounding + * rectangle. + * + * @param e reference to a MouseEvent object describing + * the mouse release. + */ + public void mouseReleased(MouseEvent e) { + mousePressed = false; + repaint(); + } +} + Added: trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton2.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton2.java (rev 0) +++ trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton2.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -0,0 +1,126 @@ +package org.dllearner.tools.ore.ui; + +import java.awt.Color; +import java.awt.Dimension; +import java.awt.Graphics; +import java.awt.Graphics2D; +import java.awt.Rectangle; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; +import java.awt.event.MouseEvent; +import java.awt.event.MouseListener; + +import javax.swing.ImageIcon; +import javax.swing.JComponent; +import javax.swing.UIManager; + +public class RoundButton2 extends JComponent implements MouseListener{ + String title; + ImageIcon ico; + ActionListener a; + String ac; + boolean p,pressed; + public RoundButton2(String title){ + this(title,new ImageIcon()); + } + public RoundButton2(ImageIcon ico){ + this("",ico); + } + public RoundButton2(){ + this("",new ImageIcon()); + } + public RoundButton2(String title,ImageIcon ico){ + this.title=title; + this.ico=ico; + p=pressed=false; + getInsets().set(15,15,15,15); + addMouseListener(this); + } + public Dimension getPreferredSize() { + Rectangle bounds=getBounds(); + return(new Dimension(new Double(bounds.getWidth()).intValue()+ + getInsets().left+getInsets().left, + new Double(bounds.getHeight()).intValue()+ + getInsets().top+getInsets().bottom)); + } + public Dimension getMinimumSize() { + return(getPreferredSize()); + } + public Dimension getMaximumSize() { + return(getPreferredSize()); + } + boolean onbutton(MouseEvent m){ + double + a=getBounds().getWidth()/2, + b=getBounds().getHeight()/2, + x=new Integer(m.getX()).doubleValue()-a, + y=new Integer(m.getY()).doubleValue()-b, + w=b/a*Math.sqrt(( (a*a) - (x*x) )); + return( y<= w && y>=-w ); + } + public void mouseClicked(MouseEvent e){} + public void mouseEntered(MouseEvent e){ + p=true; + if(pressed)repaint(); + } + public void mouseExited(MouseEvent e){ + if(pressed)repaint(); + } + public void mousePressed(MouseEvent e){ + pressed=true;if(onbutton(e)){p=true; repaint(); } + } + public void mouseReleased(MouseEvent e){ + pressed=false; + if(onbutton(e)){repaint();} + if(ac==null)ac=""; + if(a!=null) a.actionPerformed(new ActionEvent(this,ActionEvent.ACTION_PERFORMED,ac)); + } + protected void paintComponent(Graphics g){ + Graphics2D g2=(Graphics2D)g; + Rectangle bounds=getBounds(); + Color t=g.getColor(); + int j=0; + g.setColor(UIManager.getColor("Button.background").brighter()); + if(p){ + j=1;p=false; + g.setColor(UIManager.getColor("Button.background").darker().darker()); + } + g.fillArc( + j,j, + new Double(bounds.getWidth()).intValue()-4, + new Double(bounds.getHeight()).intValue()-4, + 0, + 360); + g.setColor(UIManager.getColor("Button.background").darker().darker()); + g.fillArc( + 3,3, + new Double(bounds.getWidth()).intValue()-4, + new Double(bounds.getHeight()).intValue()-4, + 45, + -180); + g.setColor(UIManager.getColor("Button.background")); + g.fillArc( + 2+j,2+j, + new Double(bounds.getWidth()).intValue()-6, + new Double(bounds.getHeight()).intValue()-6, + 0, + 360); + g.drawImage( + ico.getImage(), + new Double((double)bounds.getWidth()/8).intValue()+j, + new Double((double)bounds.getHeight()/8).intValue()+j, + new Double((double)bounds.getWidth()*.75).intValue(), + new Double((double)bounds.getHeight()*.75).intValue(), + ico.getImageObserver() + ); + g.setColor(UIManager.getColor("Button.background").darker().darker()); + g.drawString(title.trim(), + new Double((double)bounds.getWidth()/2).intValue()+j, + new Double((double)bounds.getHeight()/2).intValue()+j + ); + g.setColor(t); + } + public void addActionListener(ActionListener e){a=e;} + public void removeActionListener(ActionListener e){a=null;} + public void setActionCommand(String c){ac=c;} +} Added: trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton3.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton3.java (rev 0) +++ trunk/src/dl-learner/org/dllearner/tools/ore/ui/RoundButton3.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -0,0 +1,75 @@ +package org.dllearner.tools.ore.ui; + +import java.awt.Color; +import java.awt.Component; +import java.awt.Dimension; +import java.awt.Graphics; +import java.awt.Graphics2D; +import java.awt.RenderingHints; +import java.awt.Shape; +import java.awt.geom.Ellipse2D; + +import javax.swing.Action; +import javax.swing.BorderFactory; +import javax.swing.DefaultButtonModel; +import javax.swing.Icon; +import javax.swing.JButton; + +class RoundButton3 extends JButton { + public RoundButton3() { + this(null, null); + } + public RoundButton3(Icon icon) { + this(null, icon); + } + public RoundButton3(String text) { + this(text, null); + } + public RoundButton3(Action a) { + this(); + setAction(a); + } + public RoundButton3(String text, Icon icon) { + setModel(new DefaultButtonModel()); + init(text, icon); + if(icon==null) { + return; + } + int iw = Math.max(icon.getIconWidth(), icon.getIconHeight()); + int sw = 1; + setBorder(BorderFactory.createEmptyBorder(sw,sw,sw,sw)); + Dimension dim = new Dimension(iw+sw+sw, iw+sw+sw); + setPreferredSize(dim); + setMaximumSize(dim); + setMinimumSize(dim); + setBackground(Color.BLACK); + setContentAreaFilled(false); + setFocusPainted(false); + //setVerticalAlignment(SwingConstants.TOP); + setAlignmentY(Component.TOP_ALIGNMENT); + initShape(); + } + protected Shape shape, base; + protected void initShape() { + if(!getBounds().equals(base)) { + Dimension s = getPreferredSize(); + base = getBounds(); + shape = new Ellipse2D.Float(0, 0, s.width-1, s.height-1); + } + } + @Override + protected void paintBorder(Graphics g) { + initShape(); + Graphics2D g2 = (Graphics2D)g; + g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); + g2.setColor(getBackground()); + //g2.setStroke(new BasicStroke(1.0f)); + g2.draw(shape); + g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); + } + @Override + public boolean contains(int x, int y) { + initShape(); + return shape.contains(x, y); + } +} Modified: trunk/src/dl-learner/org/dllearner/tools/ore/ui/wizard/Wizard.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/ui/wizard/Wizard.java 2009-09-10 11:37:40 UTC (rev 1840) +++ trunk/src/dl-learner/org/dllearner/tools/ore/ui/wizard/Wizard.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -46,6 +46,7 @@ import javax.swing.UIManager; import javax.swing.border.EmptyBorder; +import org.dllearner.tools.ore.RecentManager; import org.dllearner.tools.ore.TaskManager; import org.dllearner.tools.ore.ui.StatusBar; import org.dllearner.tools.ore.ui.wizard.panels.LeftPanel; @@ -462,6 +463,8 @@ TaskManager.getInstance().setDialog(wizardDialog); TaskManager.getInstance().setStatusBar(statusBar); + + RecentManager.getInstance().deserialize(); } Modified: trunk/src/dl-learner/org/dllearner/tools/ore/ui/wizard/descriptors/KnowledgeSourcePanelDescriptor.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/ore/ui/wizard/descriptors/KnowledgeSourcePanelDescriptor.java 2009-09-10 11:37:40 UTC (rev 1840) +++ trunk/src/dl-learner/org/dllearner/tools/ore/ui/wizard/descriptors/KnowledgeSourcePanelDescriptor.java 2009-09-10 15:18:56 UTC (rev 1841) @@ -52,8 +52,8 @@ public class KnowledgeSourcePanelDescriptor extends WizardPanelDescriptor implements ActionListener{ public static final String IDENTIFIER = "KNOWLEDGESOURCE_CHOOSE_PANEL"; - public static final String INFORMATION = "Choose an OWL-ontology from filesystem or URI. Your are also able to extract a fragment " + - "from a SPARQL-endpoint. After all press <Next>"; + public static final String INFORMATION = "Choose an OWL-ontology from filesystem or URI. Your can also extract a fragment " + + "from a SPARQL endpoint. When finished, press <Next>."; private KnowledgeSourcePanel knowledgePanel; @@ -172,6 +172,7 @@ } private void handleOpenFromRecent(URI uri){ + currentURI = uri; OREManager.getInstance().setCurrentKnowledgeSource( uri); new OntologyLoadingTask(getWizard().getStatusBar()).execute(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |