Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[protege-owl] create owl

Timothy Redmond tredmond at stanford.edu
Fri Feb 24 15:58:56 PST 2012


On 2/24/12 12:42 AM, jamelmharsi wrote:
> i had this error when executing the code
> Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError:
> org/coode/obo/parser/OBOParserFactory

This raises several alarms.  First of all what is your classpath when 
you ran your code and what version of the OWL api are you using?  
Whatever code threw the exception that you saw was compiled against some 
very old (not recommended) version of the OWL api.  The exception also 
suggests the possibility that your classpath is mixing two different 
versions of the OWL api.

The fact that you got an OBOParserFactory problem suggests to me that 
you are linking with at least one version of the OWL api.  But something 
is wrong because the package is incorrect.  When I look at the latest 
OWL api from owlapi.sourceforge.net, I see a different package for the 
OBOParserFactory:

    [tredmond at bmir-3941355 Desktop]$ jar -tf owlapi-bin.jar | grep OBOParserFactory
    org/coode/owlapi/obo/parser/OBOParserFactory.class
    [tredmond at bmir-3941355 Desktop]$


The fact that your exception is in the AWT-EventQueue also suggests some 
possible issues.  This means that you are running your code inside some 
swing application.  Not Protege 4.0 by any chance?  Even with Protege 
4.1, you would need to think about class loading a bit differently than 
you would in a standalone application.

In any case I did not replicate your issue.  I did the following steps:

 1. went to the owlapi.sourceforge.net site and downloaded the latest
    OWL api (version 3.2.4).  This put a zip file owlapi-3.2.4.zip on my
    desktop.
 2. I unzipped the owlapi-bin.jar file out of the owlapi-3.2.4.zip file.
 3. I created the attached test code.  (To run it yourself you would
    have to change the static DIRECTORY variable.)
 4. I ran this code after carefully adjusting my classpath to only
    include the .class file for the CreateAndSave class and the
    owlapi-bin.jar that I had just downloaded.
 5. I did not see your exception.
 6. I did create the attached ontology.

-Timothy


>
> --
> View this message in context: http://protege-ontology-editor-knowledge-acquisition-system.136.n4.nabble.com/create-owl-tp4396842p4416538.html
> Sent from the Protege OWL mailing list archive at Nabble.com.
> _______________________________________________
> protege-owl mailing list
> protege-owl at lists.stanford.edu
> https://mailman.stanford.edu/mailman/listinfo/protege-owl
>
> Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.stanford.edu/pipermail/protege-owl/attachments/20120224/6f532652/attachment.html>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: CreateAndSave.java
URL: <http://mailman.stanford.edu/pipermail/protege-owl/attachments/20120224/6f532652/attachment.java>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Test.owl
Type: text/xml
Size: 522 bytes
Desc: not available
URL: <http://mailman.stanford.edu/pipermail/protege-owl/attachments/20120224/6f532652/attachment.owl>


More information about the protege-owl mailing list