Re: Non-deterministic content model

Yuichi Koike wrote:
> 
> Thanks for teaching me.
> Now, I understand why my example is not allowed.

You're welcome.

> > > >> So, I think, the message is a warning, and the
> > > >>instance is schema-valid. Is it right?
> > >
> > > No, the schema language prohibits non-deterministic content models.
> 
> Let me show the real example, which is a part of P3P schema file.
> Is there any way to write a `right` schema, which is
> compatible with the following example?

In short, no, not exactly, but you can probably get
close enough.

For details, see...

Newsgroups: comp.text.sgml
Date: 29 Nov 1994 21:48:14 UT
From: Arjan Loeffen <Arjan.Loeffen@let.ruu.nl>
Message-ID: <56898.loeffen@ruulet.let.ruu.nl>
Subject: Simplification & disambiguation revisited
available at http://www.oasis-open.org/cover/loefTabl.html

linked from "(The SGML Notion of) Ambiguity"
http://www.oasis-open.org/cover/topics.html#ambiguity

in Robin Covers' bibliography, cited from
"Bookmarks: Recommended Reading" on the XML home page
http://www.w3.org/XML/#dev

Your situtation is also similar to the design of
the HTML <head> content model, so see the various
schemas and DTDs for HTML as well.

> 
>  <element name='DISPUTES'>
>   <complexType content='elementOnly'>
>    <element ref='p3p:EXTENSION' minOccurs='0' maxOccurs='unbounded'/>
>    <element ref='p3p:LONG-DESCRIPTION' minOccurs='0' maxOccurs='1'/>
>    <element ref='p3p:IMG' minOccurs='0' maxOccurs='1'/>
>    <element ref='p3p:REMEDIES' minOccurs='0' maxOccurs='1'/>
>    <element ref='p3p:EXTENSION' minOccurs='0' maxOccurs='unbounded'/>
>   </complexType>
>  </element>
> 
> --
> Yuichi Koike (koike@w3.org)
> World Wide Web Consortium (W3C)
> Technology and Society Domain
> http://www.w3.org/People/Koike/

-- 
Dan Connolly, W3C http://www.w3.org/People/Connolly/

Received on Thursday, 24 August 2000 12:45:56 UTC