Université d’Oran - Faculté des Sciences Année: 2016/2017
Département Informatique
3ème année Licence
Examen : Web Sémantique – Partie 2
Durée : 45mn
---------------------------------------------------------------------------------------------------------------------------------
Nom : ……………………………………………Prénom : ……..........……………………………..………
---------------------------------------------------------------------------------------------------------------------------------
Exercice 1 : (6pts)
Soit le document catalogue.xml :
1 <?xml version="1.0" encoding="iso-8859-1"?>
2 <catalogue>
3 <entité>
4 <objet>
5 <nom lang="en">Bedside table</nom>
6 <description lang="en">
7 What a cute mahogany table with rich ornaments !
8 </description>
9 <nom lang="fr">Table de nuit</nom>
10 <Description lang="fr">
11 Magnifique table de nuit en acajou, ornée de motifs chatoyants.
12 </description>
13 </objet>
14 <prix >125<stock>22</stock>
15 </entité>
16 <entité>
17 <objet>
18 <nom lang="fr">Buffet</NOM>
19 <description lang="fr">
20 Buffet deux corps, de style classique.
21 </description>
22 </objet>
23 <prix >250</prix>
24 <stock>1</stock>
25 </entité>
26 </catalogue>
1- Indiquer si ce document est bien formé ? est valide? (Argumenter vos réponses)
2- Déduire la DTD «Catalogue.dtd»et la compléter en prenant en compte les informations suivantes :
• Une date d'ajout est toujours associée à l'élément entité saisi dans le catalogue.
• Un objet peut être décrit en plusieurs langues.
• Les éléments prix et le stock sont optionnels et tous les attributs sont obligatoires.
3- A partir de la DTD définie dans 2, proposer une représentation de la syntaxe de l'élément XML "entité"
dans le formalisme XML Schema en considérant que le type de l'élément "objet" est "objetType" (déjà
défini) et la valeur du contenu de l'élément "stock" ne dépassent pas 100.
Exercice 2 : (2pts)
Représenter en RDF avec la notation des triplets (tableau), la situation suivante :
«Le module Inf03 de bases de données est enseigné par le professeur Ahmed. Ce module est un prérequis du
module inf04 des systèmes distribués dont l'enseignant responsable est Ali qui est maître de conférences.»
Exercice 3 : (2pts)
A partir du document RDF/XML , donner la représentation graphique du modèle RDF en précisant
les ressources, les prédicats et les valeurs littérales..
<?xml version="1.0" encoding="ISO-8859-1" ?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:md="http://www.univ-oran1.dz#">
<rdf:Description rdf:about="http://www.univ-oran1.dz">
<md:titre>Site de l'université d'Oran1</md:titre>
<md:pageWeb rdf:resource="http://www.univ-oran1.dz/index.html" />
</rdf:Description>
<rdf:Description rdf:about="http://www.univ-oran1.dz#Mohamed">
<md:pageWeb rdf:resource="http://www.univ-oran1.dz/~mohamed"/>
</rdf:Description>
<rdf:Description rdf:about="http://www.univ-oran1.dz">
<md:directeur rdf:resource="http://www.univ-oran1.dz#Mohamed"/>
</rdf:Description>
</rdf:RDF>