Vous êtes sur la page 1sur 6

ÉCOLE DES SCIENCES DE L’INFORMATION Année universitaire 2022/2023

Département Génie des Données, 3ème année / GDV


des Contenus et des Connaissances Web Sémantique

TP N° 1
Exercice 1 :
<?xml version="1.0" encoding="iso-8859-1"?>
<livre>
<titre>Mon livre</titre>
<auteurs>
<auteur><nom>Brillant</nom><prenom>Alexandre</prenom></auteur>
<auteur><nom>Briand</nom><prenom>Aristide</prenom></auteur>
</auteurs>
<sections>
<section>
<titre>Section 1</titre>
<chapitres>
<chapitre>
<titre>Chapitre 1</titre>
<paragraphes>
<paragraphe>Premier paragraphe</paragraphe>
<paragraphe>Deuxième paragraphe</paragraphe>
</paragraphes>
</chapitre>
<chapitre>
<titre>Chapitre 2</titre>
<paragraphes>
<paragraphe>Premier paragraphe</paragraphe>
<paragraphe>Deuxième paragraphe</paragraphe>
</paragraphes>
</chapitre>
</chapitres>
</section>
<section>
<titre>Section 2</titre>
<chapitres>
<chapitre>
<titre>Chapitre 1</titre>
<paragraphes>
<paragraphe>Premier paragraphe</paragraphe>
<paragraphe>Deuxième paragraphe</paragraphe>
</paragraphes>
</chapitre>
<chapitre>
<titre>Chapitre 2</titre>
<paragraphes>
<paragraphe>Premier paragraphe</paragraphe>
<paragraphe>Deuxième paragraphe</paragraphe>
</paragraphes>
</chapitre>
</chapitres>
</section>
</sections>
</livre>

Exercice 2 :
<?xml version="1.0" encoding="iso-8859-1"?>
<livre titre="Mon livre">
<auteurs>
<auteur nom="Brillant" prenom="Alexandre"/>
<auteur nom="Briand" prenom="Aristide"/>
</auteurs>
<sections>
<section titre="Section 1">
<chapitre titre="Chapitre 1">
<paragraphe>Premier paragraphe</paragraphe>
<paragraphe>Deuxième paragraphe</paragraphe>
</chapitre>
<chapitre titre="Chapitre 2">
<paragraphe>Premier paragraphe</paragraphe>
<paragraphe>Deuxième paragraphe</paragraphe>
</chapitre>
</section>
<section titre="Section 2">
<chapitre titre="Chapitre1">
<paragraphe>Premier paragraphe</paragraphe>
<paragraphe>Deuxième paragraphe</paragraphe>
</chapitre>
<chapitre titre="Chapitre 2">
<paragraphe>Premier paragraphe</paragraphe>
<paragraphe>Deuxième paragraphe</paragraphe>
</chapitre>
</section>
</sections>
</livre>

Exercice 3 :

Exercice 5 :
Exercice 6 :
<?xml version="1.0" encoding="UTF-8"?>
<!ELEMENT biblio (livre | article)*>
<!ELEMENT livre (titre, auteur+, tome*, edition, avis?)>
<!ELEMENT titre (#PCDATA)>
<!ELEMENT auteur (#PCDATA)>
<!ELEMENT tome (nb_pages)>
<!ELEMENT nb_pages (#PCDATA)>
<!ELEMENT edition (editeur, lieu_edition, lieu_impression, isbn)>
<!ELEMENT editeur (#PCDATA)>
<!ELEMENT lieu_edition (#PCDATA)>
<!ELEMENT lieu_impression (#PCDATA)>
<!ELEMENT isbn (#PCDATA)>
<!ELEMENT avis (#PCDATA)>
<!ELEMENT article (titre, auteur+, journal)>
<!ELEMENT journal (nom_journal, page, num_journal, annee)>
<!ELEMENT nom_journal (#PCDATA)>
<!ELEMENT page (#PCDATA)>
<!ELEMENT num_journal (#PCDATA)>
<!ELEMENT annee (#PCDATA)>
Exercice 7 :
Exercice 8 :
<?xml version="1.0"?>
<!DOCTYPE carnet SYSTEM "carnet.dtd">
<carnet>
<personne nom="dupont" prenom="jean" telephone="001122"/>
<personne nom="dupond" telephone="221100"/>
</carnet>

Vous aimerez peut-être aussi