🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: fr.comp.text.xml
Article #8968

Re: [DTD/Schema] Liens vers entite

#8968
From: Thomas Broyer
Date: Wed, 04 Jul 2001 11:54
25 lines
1889 bytes
In <3B42A5A1.28DD39B8@insalien.org>, Laurent AJDNIK wrote:
>>   <!ELEMENT �l�ves (�l�ve)+>
>> 
>>   <!ELEMENT �l�ve (nom, age)>
>>   <!ATTLIST �l�ve
>>     id      ID    #REQUIRED
>>     parrain IDREF #IMPLIED
>>   >
>> 
>>   <!ELEMENT nom (#PCDATA)>
>> 
>>   <!ELEMENT age (#PCDATA)>
> 
> Cependant, la DTD fournie n'empeche pas "parrain" de pointer vers un
> element qui ne soit pas "eleve", n'est-ce pas (ce que je veux eviter) ?

Puisqu'il n'y a que les �l�ments ��l�ve� qui ont un attribut de type ID, un 
attribut de type IDREF ne peut r�f�rencer que des �l�ments ��l�ve�
Un IDREF doit aussi, pour �tre valide, r�f�rencer un ID existant dans le 
document.

S'il doit y avoir d'autres ID dans le document, une DTD ne peut forcer un 
IDREF � "pointer" vers l'ID d'un ��l�ve�, un XML Sch�ma le pourra.

Tom.
Technical Details
Message-ID: <2644732.LvFx2qVVIh@ltgt.net>
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news.tele.dk!193.251.151.101!opentransit.net!proxad.net!feeder2-1.proxad.net!nnrp4.proxad.net.POSTED!not-for-mail
References: <3B41BC18.70D13E8D@insalien.org> <2593444.KmheAe9J7N@ltgt.net> <3B42A5A1.28DD39B8@insalien.org>

Show Full Headers
Complete Article Headers
X-Google-Language: FRENCH,ASCII
X-Google-Thread: 114f60,ed6ef6154433ceb8
X-Google-Attributes: gid114f60,public
X-Google-ArrivalTime: 2001-07-04 04:54:56 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news.tele.dk!193.251.151.101!opentransit.net!proxad.net!feeder2-1.proxad.net!nnrp4.proxad.net.POSTED!not-for-mail
Message-ID: <2644732.LvFx2qVVIh@ltgt.net>
From: Thomas Broyer <ptittom+news@free.fr>
Subject: Re: [DTD/Schema] Liens vers entite
Newsgroups: fr.comp.text.xml
References: <3B41BC18.70D13E8D@insalien.org> <2593444.KmheAe9J7N@ltgt.net> <3B42A5A1.28DD39B8@insalien.org>
Lines: 25
Organization: </>
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8Bit
Date: Wed, 04 Jul 2001 11:54:55 GMT
NNTP-Posting-Host: 193.251.185.191
X-Complaints-To: abuse@proxad.net
X-Trace: nnrp4.proxad.net 994247695 193.251.185.191 (Wed, 04 Jul 2001 13:54:55 CEST)
NNTP-Posting-Date: Wed, 04 Jul 2001 13:54:55 CEST