Hi Steve, here is the schema (at the end of the message). If I change the properties mixed="true" to mixed="false" I get no errors. However, if I leave them as is, I'll get this error:
compile:
[echo] Compiling the schema...
[xjc] Compiling file:/C:/work/toolkit/eContact.xsd
[xjc] [ERROR] the property "Content" is empty and contains no value
[xjc] line 37 of dc.xsd
[xjc] failure in the XJC task. Use the Ant -verbose switch for more details
BUILD FAILED
C:\work\toolkit\build.xml:37: unable to parse the schema. Error messages should have been provided
These properties are located in <xs:complexType name="SimpleLiteral" mixed="true"> and <xs:complexContent mixed="true">
I read in this forum that there is an issue with this "mixed" property. Do you have any idea of what I could do, I cannot modify dublin core schema...
SO, here is the schema, it corresponds to dublin core schema (see
http://dublincore.org/schemas/xmls/)
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="
http://www.w3.org/2001/XMLSchema" xmlns="dc" targetNamespace="dc" elementFormDefault="qualified" attributeFormDefault="unqualified">
<xs:annotation>
<xs:documentation xml:lang="en">
DCMES 1.1 XML Schema
XML Schema for
http://purl.org/dc/elements/1.1/ namespace
Created 2003-04-02
Created by
Tim Cole (t-cole3_at_uiuc.edu)
Tom Habing (thabing_at_uiuc.edu)
Jane Hunter (jane_at_dstc.edu.au)
Pete Johnston (p.johnston_at_ukoln.ac.uk),
Carl Lagoze (lagoze_at_cs.cornell.edu)
This schema declares XML elements for the 15 DC elements from the
http://purl.org/dc/elements/1.1/ namespace.
It defines a complexType SimpleLiteral which permits mixed content
and makes the xml:lang attribute available. It disallows child elements by
use of minOcccurs/maxOccurs.
However, this complexType does permit the derivation of other complexTypes
which would permit child elements.
All elements are declared as substitutable for the abstract element any,
which means that the default type for all elements is dc:SimpleLiteral.
CBCS/XML Subcommittee POC ---- modified 2004-03-07
CBCS/XML Subcommittee POC ---- target namespace modified to local
</xs:documentation>
</xs:annotation>
<xs:complexType name="SimpleLiteral" mixed="true">
<xs:annotation>
<xs:documentation xml:lang="en">
This is the default type for all of the DC elements.
It permits text content only with optional
xml:lang attribute.
Text is allowed because mixed="true", but sub-elements
are disallowed because minOccurs="0" and maxOccurs="0"
are on the xs:any tag.
This complexType allows for restriction or extension permitting
child elements.
</xs:documentation>
</xs:annotation>
<xs:complexContent mixed="true">
<xs:restriction base="xs:anyType">
<xs:sequence>
<xs:any processContents="lax" minOccurs="0" maxOccurs="0"/>
</xs:sequence>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
<xs:element name="any" type="SimpleLiteral" abstract="true"/>
<xs:element name="title" substitutionGroup="any"/>
<xs:element name="creator" substitutionGroup="any"/>
<xs:element name="subject" substitutionGroup="any"/>
<xs:element name="description" substitutionGroup="any"/>
<xs:element name="publisher" substitutionGroup="any"/>
<xs:element name="contributor" substitutionGroup="any"/>
<xs:element name="date" substitutionGroup="any"/>
<xs:element name="type" substitutionGroup="any"/>
<xs:element name="format" substitutionGroup="any"/>
<xs:element name="identifier" substitutionGroup="any"/>
<xs:element name="source" substitutionGroup="any"/>
<xs:element name="language" substitutionGroup="any"/>
<xs:element name="relation" substitutionGroup="any"/>
<xs:element name="coverage" substitutionGroup="any"/>
<xs:element name="rights" substitutionGroup="any"/>
<xs:group name="elementsGroup">
<xs:annotation>
<xs:documentation xml:lang="en">
This group is included as a convenience for schema authors
who need to refer to all the elements in the
http://purl.org/dc/elements/1.1/ namespace.
</xs:documentation>
</xs:annotation>
<xs:sequence>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="any"/>
</xs:choice>
</xs:sequence>
</xs:group>
<xs:complexType name="elementContainer">
<xs:annotation>
<xs:documentation xml:lang="en">
This complexType is included as a convenience for schema authors who need to define a root
or container element for all of the DC elements.
</xs:documentation>
</xs:annotation>
<xs:choice>
<xs:group ref="elementsGroup"/>
</xs:choice>
</xs:complexType>
</xs:schema>