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-discussion] ModelFactory error

Davenport, Daniel daniel.davenport at lmco.com
Fri Oct 5 13:08:06 PDT 2007


That did it.  I added the whole Protégé library (why skimp?) and it found what it needed.  Thanks so much. I hadn't thought of the possibility that jars might reqire other jars even though C is my natural habitat (as it were).  Thx again.  -Dan 

-----Original Message-----
From: protege-discussion-bounces at mailman.stanford.edu [mailto:protege-discussion-bounces at mailman.stanford.edu] On Behalf Of Thomas Russ
Sent: Friday, October 05, 2007 2:29 PM
To: User support for Core Protege and the Protege-Frames editor
Subject: Re: [protege-discussion] ModelFactory error


On Oct 5, 2007, at 8:11 AM, Davenport, Daniel wrote:

> I ran my code with the class generated by Protégé for my ontology  
> and got this messge
>
>
>
> Exception in thread "main" java.lang.NoClassDefFoundError: org/ 
> apache/commons/logging/LogFactory
>
>       at com.hp.hpl.jena.rdf.model.impl.PropertyImpl.<clinit> 
> (PropertyImpl.java:61)
>
>       at com.hp.hpl.jena.enhanced.BuiltinPersonalities.<clinit> 
> (BuiltinPersonalities.java:28)
>
>       at com.hp.hpl.jena.rdf.model.impl.ModelCom.<init> 
> (ModelCom.java:51)
>
>       at com.hp.hpl.jena.rdf.model.ModelFactory.createDefaultModel 
> (ModelFactory.java:162)
>
>       at com.hp.hpl.jena.rdf.model.ModelFactory.createDefaultModel 
> (ModelFactory.java:156)
>
>       at com.hp.hpl.jena.rdf.model.impl.ModelSpecImpl.<clinit> 
> (ModelSpecImpl.java:56)
>
>       at lantern.test.<clinit>(test.java:18)
>
>       at lantern.Lantern.main(Lantern.java:23)
>
>
>
> I used the right libraries
>
>
>
> import com.hp.hpl.jena.rdf.model.*;
>
> import com.hp.hpl.jena.ontology.*;
>
>
>
> so it compiled alright.  Im running it on Eclipse.  So what am I  
> missing?

You don't have your classpath setup properly for the runtime.

At runtime there are more dependencies that come from the code you  
are using but haven't written yourself.
You need to add all of the *.jar files from the main Protege directory.
You may also need to add the jar files from the OWL plugin directory  
as well, although the plugin loader may take care of that for you.   
That's where the commons-logging file comes from.



_______________________________________________
protege-discussion mailing list
protege-discussion at lists.stanford.edu
https://mailman.stanford.edu/mailman/listinfo/protege-discussion

Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03 



More information about the protege-discussion mailing list