Hello, all.

I am running TBC ver-2.6.2 on top of Eclipse ver-3.4.

Consider the following XML Schema.

<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema";
elementFormDefault="qualified" attributeFormDefault="unqualified">
  <xs:element name="Person">
    <xs:complexType>
      <xs:choice>
        <xs:element name="Male" type="MaleType" />
        <xs:element name="Female" type="FemaleType" />
      </xs:choice>
    </xs:complexType>
  </xs:element>

  <xs:complexType name="MaleType" />
  <xs:complexType name="FemaleType" />
</xs:schema>

The TBC XML Schema import engine produces the following OWL ontology:

<?xml version="1.0"?>
<rdf:RDF
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#";
    xmlns:xsd="http://www.w3.org/2001/XMLSchema#";
    xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#";
    xmlns:owl="http://www.w3.org/2002/07/owl#";
    xmlns="http://www.owl-ontologies.com#";
  xml:base="http://www.owl-ontologies.com";>
  <owl:Ontology rdf:about="">
    <owl:versionInfo rdf:datatype="http://www.w3.org/2001/
XMLSchema#string"
    >Created with TopBraid Composer from the XML Schema
http://www.owl-ontologies.com</owl:versionInfo>
  </owl:Ontology>
  <owl:Class rdf:ID="Female"/>
  <owl:Class rdf:ID="Male"/>
  <owl:Class rdf:about="http://www.w3.org/2001/XMLSchema#Any"/>
  <owl:Class rdf:ID="Person">
    <rdfs:subClassOf>
      <owl:Restriction>
        <owl:maxCardinality rdf:datatype="http://www.w3.org/2001/
XMLSchema#int"
        >1</owl:maxCardinality>
        <owl:onProperty>
          <owl:ObjectProperty rdf:ID="hasFemale"/>
        </owl:onProperty>
      </owl:Restriction>
    </rdfs:subClassOf>
    <rdfs:subClassOf>
      <owl:Restriction>
        <owl:allValuesFrom rdf:resource="#Female"/>
        <owl:onProperty rdf:resource="#hasFemale"/>
      </owl:Restriction>
    </rdfs:subClassOf>
    <rdfs:subClassOf>
      <owl:Restriction>
        <owl:maxCardinality rdf:datatype="http://www.w3.org/2001/
XMLSchema#int"
        >1</owl:maxCardinality>
        <owl:onProperty>
          <owl:ObjectProperty rdf:ID="hasMale"/>
        </owl:onProperty>
      </owl:Restriction>
    </rdfs:subClassOf>
    <rdfs:subClassOf>
      <owl:Restriction>
        <owl:allValuesFrom rdf:resource="#Male"/>
        <owl:onProperty rdf:resource="#hasMale"/>
      </owl:Restriction>
    </rdfs:subClassOf>
  </owl:Class>
</rdf:RDF>

The XML Schema's "Person" definition specifies a choice between a
"Male" and "Female". For an XML instance document to validate against
this schema, a "Person" element must contain either a "Male" element
or a "Female" element, but not both.

It appears the TBC-generated ontology's "Person" class does not
capture this. According to http://www.w3.org/TR/owl-guide/, "class
definitions have multiple subparts that are implicitly conjoined, and
the following example is provided.

<owl:Class rdf:ID="Wine">
  <rdfs:subClassOf rdf:resource="&food;PotableLiquid"/>
  <rdfs:subClassOf>
    <owl:Restriction>
      <owl:onProperty rdf:resource="#madeFromGrape"/>
      <owl:minCardinality rdf:datatype="&xsd;nonNegativeInteger">1</
owl:minCardinality>
    </owl:Restriction>
  </rdfs:subClassOf>
  ...
</owl:Class>

I interpret "implicitly conjoined" as a union set operation. It my
interprepation is accurate, then the preceding "Person" class allows a
Person individual to contain both Male and Female individuals on its
"hasMale" and "hasFemale" properties, respectively, which clearly
violates the intent of the "Person" XML Schema definition.

Is my assessment correct? If so, how can one best semantically
represent an XML Schema choice compositor within an OWL-DL ontology?

Thank you.


Regards,

Anthony
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TopBraid Composer Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/topbraid-composer-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to