[protege-owl] Protege-OWL API problem

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[protege-owl] Protege-OWL API problem

Daniel Elenius
Hi,

I am using the Protege-OWL API in a standalone application for a project
here at SRI, and I ran into a problem.

When I call getOWLIndividuals() on my OWLModel, I get the following
exception:

java.lang.NullPointerException
        at edu.stanford.smi.protege.model.DefaultFrame.isVisible(Unknown
Source)
        at
edu.stanford.smi.protegex.owl.model.impl.AbstractOWLModel.getRDFIndividuals(Unknown
Source)
        at
edu.stanford.smi.protegex.owl.model.impl.AbstractOWLModel.getOWLIndividuals(Unknown
Source)
        at
edu.stanford.smi.protegex.owl.model.impl.AbstractOWLModel.getOWLIndividuals(Unknown
Source)

Any idea what could cause this? I can get the classes and properties ok,
i.e. OWLModel.getRDFProperties() and OWLModel.getRDFSClasses() work as
expected.

Another gripe: When I call the load() method on an OWLModel, and there
are missing imports, the "Add repository" dialog pops up. What if I
don't want it to? I shouldn't have to use the Protege GUI just because
I'm using the API.

It seems like the API was not really designed to be used without a
Protege GUI running...

Daniel
_______________________________________________
protege-owl mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-owl

Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03 
Reply | Threaded
Open this post in threaded view
|

Re: [protege-owl] Protege-OWL API problem

Tania Tudorache
Daniel,

Daniel Elenius wrote:
>
> I am using the Protege-OWL API in a standalone application for a project
> here at SRI, and I ran into a problem.
>
> When I call getOWLIndividuals() on my OWLModel, I get the following
> exception:
>  
Can you please send the code snippet that you throws the exception? I
was not able to reproduce the NullPointer exception in a simple test,
using latest version of Protege.

> java.lang.NullPointerException
>         at edu.stanford.smi.protege.model.DefaultFrame.isVisible(Unknown
> Source)
>         at
> edu.stanford.smi.protegex.owl.model.impl.AbstractOWLModel.getRDFIndividuals(Unknown
> Source)
>         at
> edu.stanford.smi.protegex.owl.model.impl.AbstractOWLModel.getOWLIndividuals(Unknown
> Source)
>         at
> edu.stanford.smi.protegex.owl.model.impl.AbstractOWLModel.getOWLIndividuals(Unknown
> Source)
>
> Any idea what could cause this? I can get the classes and properties ok,
> i.e. OWLModel.getRDFProperties() and OWLModel.getRDFSClasses() work as
> expected.
>
> Another gripe: When I call the load() method on an OWLModel, and there
> are missing imports, the "Add repository" dialog pops up. What if I
> don't want it to? I shouldn't have to use the Protege GUI just because
> I'm using the API.
>  
Yes, we plan to improve this in Protege 3.3 beta.
> It seems like the API was not really designed to be used without a
> Protege GUI running...
>
>  
It is true that some parts of the code have a GUI bias, but we will this
gradually in the next versions.

Thanks,
Tania

> Daniel
> _______________________________________________
> protege-owl mailing list
> [hidden email]
> https://mailman.stanford.edu/mailman/listinfo/protege-owl
>
> Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03 
>
>  

_______________________________________________
protege-owl mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-owl

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