|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: Simple Schema
Hi Raja,
There is a separate schema validation feature that you need to set in your
Java code. It would look like:
parser.setFeature("http://apache.org/xml/features/validation/schema", true);
That may be the source of your problem.
Priscilla
------------------------------------------------------------------
Priscilla Walmsley priscilla@w...
Vitria Technology http://www.vitria.com
Author, Definitive XML Schema (Prentice Hall PTR)
------------------------------------------------------------------
> -----Original Message-----
> From: rajac [mailto:rajac@n...]
> Sent: Sunday, February 10, 2002 7:12 PM
> To: xml-dev@l...
> Subject: Re: Simple Schema
>
>
> Hi KRUMPOLEC Martin,
> Even then(after changing from minOccur to minOccurs), it is failing.
> Initially i was using minOccurs only.
>
> Rgds.,
> Raja
>
> ----- Original Message -----
> From: "KRUMPOLEC Martin" <krumpolec@a...>
> To: "'rajac'" <rajac@n...>; <xml-dev@l...>
> Sent: Monday, February 11, 2002 5:16 PM
> Subject: RE: Simple Schema
>
>
> > Hi rajac,
> >
> > > <?xml version="1.0" encoding="UTF-8"?>
> > > <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
> > > <xs:element name="note">
> > > <xs:complexType>
> > > <xs:sequence>
> > > <xs:element name="to" type="xs:string" minOccur="1"
> > > maxOccur="5"/>
> > > <xs:element name="heading" type="xs:string" minOccur="1"
> > > maxOccur="5"/>
> > > <xs:element name="body" type="xs:string" minOccur="1"
> > > maxOccur="5"/>
> > > </xs:sequence>
> > > </xs:complexType>
> > > </xs:element>
> > > </xs:schema>
> >
> > Your schema is invalid - please note difference between
> > minOccur/minOccurs and maxOccur/maxOccurs ...
> >
> > HTH
> >
> > Martin
> >
> > --
> > Martin Krumpolec <krumpo@p...>
>
>
> -----------------------------------------------------------------
> The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
> initiative of OASIS <http://www.oasis-open.org>
>
> The list archives are at http://lists.xml.org/archives/xml-dev/
>
> To subscribe or unsubscribe from this list use the subscription
> manager: <http://lists.xml.org/ob/adm.pl>
>
>
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








