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] Is it normal for the changed namespace delcaration when saving changed ontology

Tania Tudorache tudorache at stanford.edu
Mon Jan 7 19:17:35 PST 2008


Weishan,

I wondered why did you use the OWLModelWriter. Did you find it anywhere 
in the documentation?

The OWLModelWriter is the Protege experimental native writer. The 
RDF/XML writer used when you save an ontology from the Protege UI or 
when you invoke the owlModel.save method is the Jena writer, which is 
the default one for Protege. For that reason, the output of the two save 
methods are different.

Tania



zhang weishan wrote:
> It seems that OWLModelWriter is quite different with the 
> owlModel.save, which should be explained in the tutorial, or 
> somewhere... Sorry if i missed this information if it exists already.
>
>
> ----- Original Message ----
> From: zhang weishan <dr_zhangws at yahoo.com>
> To: protege-owl at lists.stanford.edu
> Sent: Tuesday, January 8, 2008 4:08:03 AM
> Subject: [protege-owl] Is it normal for the changed namespace 
> delcaration when saving changed ontology
>
> Dear All,
>   I am using the an ontology which contains SWRL rules, and it imports 
> another ontology (StateMachine.owl) that is updated periodiacally.
>   When i use :
>     FileWriter writer = new 
> FileWriter("D:/Tomcat/webapps/ontology/StateMachine.owl");
>
>                    OWLModelWriter omw = new OWLModelWriter(owlModel, 
>                            
> owlModel.getTripleStoreModel().getActiveTripleStore(), writer);
>                    omw.write();
>                    writer.close();
>
>   The original name space declaration is:
>   <rdf:RDF
>     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
>     xmlns="http://localhost:9999/ontology/StateMachine.owl#"
>     xmlns:owl="http://www.w3.org/2002/07/owl#"
>     xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
>     xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
>   xml:base="http://localhost:9999/ontology/StateMachine.owl">
>
> After switching the active triple store, the StateMachine.owl is saved 
> after changed. But now the name space declaration is as attached. It 
> is a valid but not as tidy as the original one. Is this normal? Or 
> what should i do to avoid this?
>
> Cheers,
> Weishan
>
>
>
>
> <!DOCTYPE rdf:RDF [
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
>    
> ]>
>
>
>
>      xml:base="http://localhost:9999/ontology/StateMachine.owl"
>      
> xmlns:operatingSystem="http://localhost:9999/ontology/OperatingSystem.owl#"
>      xmlns:Java="http://localhost:9999/ontology/Java.owl#"
>      
> xmlns:abox="http://swrl.stanford.edu/ontologies/built-ins/3.3/abox.owl#"
>      
> xmlns:sqwrl="http://sqwrl.stanford.edu/ontologies/built-ins/3.4/sqwrl.owl#"
>      xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
>      xmlns:swrl="http://www.w3.org/2003/11/swrl#"
>      xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
>      xmlns:owl11="http://www.w3.org/2006/12/owl11#"
>      xmlns:protege="http://protege.stanford.edu/plugins/owl/protege#"
>      xmlns:owl11xml="http://www.w3.org/2006/12/owl11-xml#"
>      xmlns:error="http://localhost:9999/ontology/Error.owl#"
>      
> xmlns:swrlx="http://swrl.stanford.edu/ontologies/built-ins/3.3/swrlx.owl#"
>      xmlns:statemachine="http://localhost:9999/ontology/StateMachine.owl#"
>      xmlns:units="http://localhost:9999/ontology/Units.owl#"
>      
> xmlns:swrlm="http://swrl.stanford.edu/ontologies/built-ins/3.4/swrlm.owl#"
>      
> xmlns:SoftwarePlatform="http://localhost:9999/ontology/SoftwarePlatform.owl#"
>      xmlns:Hardware="http://localhost:9999/ontology/Hardware.owl#"
>      
> xmlns:temporal="http://swrl.stanford.edu/ontologies/built-ins/3.3/temporal.owl#"
>      xmlns:owl="http://www.w3.org/2002/07/owl#"
>      xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
>      xmlns:device="http://localhost:9999/ontology/Device.owl#"
>      xmlns:swrlb="http://www.w3.org/2003/11/swrlb#"
>      xmlns:DotNet="http://localhost:9999/ontology/DotNet.owl#"
>      
> xmlns:tbox="http://swrl.stanford.edu/ontologies/built-ins/3.3/tbox.owl#"
>      xmlns:swrla="http://swrl.stanford.edu/ontologies/3.3/swrla.owl#">
>
> ------------------------------------------------------------------------
> Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try 
> it now. 
> <http://us.rd.yahoo.com/evt=51733/*http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ%20> 
>
>
>
> -----Inline Attachment Follows-----
>
> _______________________________________________
> protege-owl mailing list
> protege-owl at lists.stanford.edu <mailto: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
>
>
> ------------------------------------------------------------------------
> Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try 
> it now. 
> <http://us.rd.yahoo.com/evt=51733/*http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ%20> 
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> 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 
>   




More information about the protege-owl mailing list