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] Ontology based applications!!

Michael Rusch mcrusch at wisc.edu
Wed Aug 19 07:53:49 PDT 2009


I'm not quite sure which question your asking (maybe both?):

A. How does one design and write an application using OWL ontologies, 
via the Protege 4 API?

B. How does one set up an environment to make development using the APIs 
easy (in terms of build, code completion, etc.)?

The first is more a question about design, whereas the second is more 
practical.

I am a little too new to this to comment on design issues, but as far as 
IDE setup, here's what I did, with Eclipse:

First, I set up a "toy" project called toy-protege, so I'd have a way to 
play around with Protege stuff, when I wasn't sure how it would work.  I 
happened to do this as a servlet, so I created a new "Dynamic Web 
Project".  I then put all of the jars from the Protege release (some 
were in the root dir, some were in lib) into WebContent/WEB-INF/lib.

Now, when I did this, I found that for whatever reason, I couldn't use 
Apache in Eclipse as the server.  I don't know why, but it seemed to not 
load all of the jar files into the classpath, as I would get errors 
about not being able to find classes, but they were right there in the 
lib dir.  I would restart the server, and then it would complain about a 
different class being missing.  Strange.  Hopefully nobody else will 
have this problem.  So, I wound up exporting to a war file, which I 
deployed to my stand-alone resin app server.

Then, I started my real project which was just a vanilla Java project. 
I then did the following:

* went into configure build path -> Libraries tab
* clicked on Add Library
* selected User Library and hit next
* clicked on User Libraries...
(this next part might be different in Protege 4, I have 3.4.1)
* created a new user library named Protege, and added to it all of the 
jars in the root Protege dir
* created another new user library named Protege-OWL, and added all of 
the jars from <root Protege dir>/plugins/edu.standford.smi.protegex.owl
* (still in User Libraries) under the Protege library, found the 
protege.jar and added source attachment from local (can't remember if 
protege source is a separate download or part of the regular download), 
and javadoc from the web site
* (still in User Libraries) under the Protege-OWL library, found 
protege-owl.jar and added source attachment and javadoc similarly
* hit OK to go back to add library screen
* selected Protege and Protege-OWL libraries to add

I've found that to be sufficient for all of my building and debugging so 
far.  Though there is only source attachment/javadoc for those two jars, 
that's been all I needed, and that has made development pretty painless. 
  With the vanilla Java project, having those libraries on the build 
path was sufficient for them to be available at run time when running 
from Eclipse.

Hope this helps answer your question.

Michael

Sohaib Ahmed wrote:
> Hi Samson !!
>  
> Thanks for your reply. This documentation is definitely helpful but i am 
> interested in the implementation of ontology (developed in Protege 4.0) 
> in a real-world application. Currently, I am using OWL API which behaves 
> as a framework between application and the developed ontology. Can you 
> please tell me about any tutorial which describes how an application can 
> be implemented through OWL ontology (developed in Protege 4.0)...
>  
> As far as the import problem is concerned it is also solved after using 
> OWL API. The link is as under:-
> http://owlapi.sourceforge.net/
>  
> please guide me in the above defined matter. Hope for the positive 
> response from you as always...
>  
> Regards,
> 
> *Sohaib Ahmed*
> 
> 
> 
> 
>  
>  > To: protege-discussion at lists.stanford.edu
>  > From: swt at stanford.edu
>  > Date: Tue, 18 Aug 2009 15:31:21 -0700
>  > Subject: Re: [protege-discussion] Ontology based applications!!
>  >
>  >
>  > You need to find the Protege 4 developer documentation site:
>  >
>  > http://protegewiki.stanford.edu/index.php/Protege4DevDocs
>  >
>  > Samson
>  >
>  > Sohaib Ahmed wrote:
>  > >
>  > > Hi!!
>  > >
>  > > Can anyone tell me abt how i can use ontology in JAVA IDEs like Net
>  > > beans or Eclipse which is developed in Protege 4.0 . I came across few
>  > > tutorials and web pages used Protege 3.x instead of Protege 4.0.. and
>  > > similarly if i want to import "edu.stanford.smi.protegex.owl.model" as
>  > > mentioned in most of the tutorials.. How i can import in Protege 4.0
>  > > which i cant able to find in Protege 4.0 because there are limited
>  > > number of jars files present. so plz help me in this regard...or if 
> any
>  > > one tell me any tutorial which can help me in understanding to develop
>  > > applications by Protege 4.0 ontologies...
>  > >
>  > > Thanking you in advance
>  >
>  > _______________________________________________
>  > 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
> 
> ------------------------------------------------------------------------
> check out the rest of the Windows Live™. More than mail–Windows Live™ 
> goes way beyond your inbox. More than messages 
> <http://www.microsoft.com/windows/windowslive/>
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> 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