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] Problem loading an ontology from a String

Ralf Weinand weinanr at
Mon Jan 14 15:12:48 PST 2008


I want to use the protege-owl API (3.4 b125) to load an ontology
which is not serialized in a file but is sent via e.g. a SOAP message.

However, when I try to create the JenaOWLModel via

     sourceOwlModel = ProtegeOWL.createJenaOWLModelFromInputStream(new

I get the following error:

SEVERE: An error occurred at parsing the OWL ontology

    at line -1 and column -1.
    Jena parse error message: {E213} --

To simulate that the ontology was send as a string, I did initialize
the variable via:

sourceIndividual =
"<?xml version=\"1.0\"?> <rdf:RDF  xmlns:rdf=\"\"
xmlns:xsd=\"\ "
xmlns=\"\ "
xml:base=\"\">  <owl:Ontology
rdf:about=\"\"/>  <owl:Class rdf:ID=\"Address\">
<owl:equivalentClass>  <owl:Class>  <owl:intersectionOf
rdf:parseType=\"Collection\">  <owl:Restriction>  <owl:onProperty>
<owl:FunctionalProperty rdf:ID=\"City\"/>  </owl:onProperty>
<owl:cardinality rdf:datatype=\"\"  >1</owl:cardinality>
</owl:Restriction>  <owl:Restriction>  <owl:onProperty>
<owl:FunctionalProperty rdf:ID=\"firstName\"/>  </owl:onProperty>
<owl:cardinality rdf:datatype=\"\"  >1</owl:cardinality>
</owl:Restriction>  <owl:Restriction>  <owl:onProperty>
<owl:FunctionalProperty rdf:ID=\"lastName\"/>  </owl:onProperty>
<owl:cardinality rdf:datatype=\"\"  >1</owl:cardinality>
</owl:Restriction>  </owl:intersectionOf>  </owl:Class>
</owl:equivalentClass>  </owl:Class>  <owl:FunctionalProperty
rdf:about=\"#firstName\">  <rdfs:range rdf:resource=\"\"/>  <rdf:type
rdf:resource=\"\ "/>
</owl:FunctionalProperty>  <owl:FunctionalProperty
rdf:about=\"#lastName\">  <rdf:type
rdf:resource=\"\ "/>
<rdfs:range rdf:resource=\"\"/>
 </owl:FunctionalProperty>  <owl:FunctionalProperty
rdf:about=\"#City\">  <rdf:type rdf:resource=\"\"/>  <rdfs:range
rdf:resource=\"\ "/>
</owl:FunctionalProperty>  <Address rdf:ID=\"Address_1\">  <City
rdf:datatype=\"\ "
>Berlin</City>  <lastName
>Smith</lastName>  <firstName rdf:datatype=\"\"  >John</firstName>
</Address> </rdf:RDF>";

I guess this is a repositoryManager-issue. Maybe someone can give me a
hint on how to handle such a case
 where I don´t have a file/url to point at. Thanks a lot in advance!


More information about the protege-owl mailing list