Women in Technology

Hear us Roar

  Understanding JAXB: Java Binding Customization
Subject:   error when running the example
Date:   2003-12-22 10:52:29
From:   anonymous2

When I attempt to run the modified version of the XSD file, jxc throws a parsing error:
parsing a schema...
[ERROR] In "strict" mode, the following schema feature is not allowed (See App E
.2).Use the "-extension" switch:
vendor extension bindings (jaxb:extensionBindingPrefixes) are not suppor
line 5 of purchase.xsd

Failed to parse a schema.

Any ideas??

It fails on the following line:
jaxb:version="1.0" jaxb:extensionBindingPrefixes="xjc">



Full Threads Oldest First

Showing messages 1 through 1 of 1.

  • error when running the example
    2003-12-22 12:20:55  hashimisayed [View]

    Anytime you refer to JAXB extensions in your xsd, you have to compile with the "-extension" switch. An example of this:

    <simpleType name="Age">
    <xs:javaType name="int" />
    <xs:restriction base="xs:positiveInteger"/>

    Because I am using the javaType vendor extension in my customization, I have to tell the schema compiler to compile with extensions:

    xjc schemafilename.xsd -extension