users@jaxb.java.net

Re: problem about xs:choice

From: CANDAT Jerome <jerome.candat_at_c-s.fr>
Date: Thu, 4 Dec 2003 13:41:25 +0100

Hello,

May be you should define "jaxb" as a namespace in your XML Schema the same way as the "xs" one.

Jérôme.
  ----- Original Message -----
  From: Amila Suriarachchi
  To: users_at_jaxb.dev.java.net
  Sent: Thursday, December 04, 2003 12:15 PM
  Subject: problem about xs:choice


  i used this simple 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="Timing">

              <xs:complexType>

                    <xs:choice>

                          <xs:annotation>

                                <xs:appinfo>

                                      <jaxb:property name="Content"/>

                                </xs:appinfo>

                          </xs:annotation>

                          <xs:element name="Daily" type="xs:string"/>

                          <xs:element name="monthly" type="xs:string"/>

                          <xs:element name="yearly" type="xs:string"/>

                          <xs:element name="weekly" type="xs:string"/>

                    </xs:choice>

              </xs:complexType>

        </xs:element>

  </xs:schema>

   

   

  but I gives a compile error like this

  [ERROR] The prefix "jaxb" for element "jaxb:property" is not bound.

    line 8 of testbinding.xsd