index.html 89.1 KB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-us" lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>Semantic Annotations for WSDL and XML Schema</title>
<style type="text/css"> /*<![CDATA[*/ pre {
 background:#D5DEE3;
 margin-left: 0!important;
} div.body dt {
 font-weight: normal;
 padding-top: 1ex;
} .todo {
  background: url(img/todo.png) left top no-repeat;
  background-color:#FFFF80;
  border: solid 1px black;
  padding-left: 100px;
  margin-left:20px;
  margin-right:20px;
  font-style:italic;
}
/*]]>*/ </style>
<link rel="stylesheet" type="text/css"
  href="http://www.w3.org/StyleSheets/TR/W3C-REC" />
</head>

<body>

<div class="head">
<p><a href="http://www.w3.org/"><img
  src="http://www.w3.org/Icons/w3c_home" alt="W3C" height="48" width="72" /></a></p>

<h1 id="title">Semantic Annotations for WSDL and XML Schema</h1>

<h2 id="w3c-doctype">W3C Recommendation 28 August 2007</h2>
<dl>
  <dt>This version:</dt>

  <dd><a href="http://www.w3.org/TR/2007/REC-sawsdl-20070828/">http://www.w3.org/TR/2007/REC-sawsdl-20070828/</a></dd>

  <dt>Latest version:</dt>

  <dd><a href="http://www.w3.org/TR/sawsdl/">http://www.w3.org/TR/sawsdl/</a></dd>

  <dt>Previous version:</dt>

  <dd><a href="http://www.w3.org/TR/2007/PR-sawsdl-20070705/">
http://www.w3.org/TR/2007/PR-sawsdl-20070705/</a></dd>

  <dt>Editors:</dt>

  <dd>Joel Farrell, IBM</dd>

  <dd>Holger Lausen, DERI Innsbruck</dd>
</dl>

<p>Please refer to the <a href="http://www.w3.org/2002/ws/sawsdl/errata/"><strong>errata</strong></a> for this document, which may include some normative corrections.</p>
<p>See also <a href="http://www.w3.org/2003/03/Translations/byTechnology?technology=sawsdl">translations</a>.</p>

<p class="copyright"><a href="http://www.w3.org/Consortium/Legal/ipr-notice#Copyright">Copyright</a> &copy; 2007 <a href="http://www.w3.org/"><acronym title="World Wide Web Consortium">W3C</acronym></a><sup>&reg;</sup> (<a href="http://www.csail.mit.edu/"><acronym title="Massachusetts Institute of Technology">MIT</acronym></a>, <a href="http://www.ercim.org/"><acronym title="European Research Consortium for Informatics and Mathematics">ERCIM</acronym></a>, <a href="http://www.keio.ac.jp/">Keio</a>), All Rights Reserved. W3C <a href="http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer">liability</a>, <a href="http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks">trademark</a> and <a href="http://www.w3.org/Consortium/Legal/copyright-documents">document use</a> rules apply.</p>
</div>
<hr />

<h2 id="abstract">Abstract</h2>

<p>This document defines a set of extension attributes for the Web Services
Description Language and XML Schema definition language that allows
description of additional semantics of WSDL components. The specification defines how semantic annotation is accomplished using references to semantic models, e.g.
ontologies. Semantic Annotations for WSDL and XML Schema (SAWSDL) does not specify a language for representing the semantic models.
Instead it provides mechanisms by which concepts from the semantic models, typically defined outside
the WSDL document, can be referenced from within WSDL and XML Schema components using annotations. </p>

<div>
<h2 id="status">Status of this Document</h2>

<p><em>This section describes the status of this document at the time
of its publication. Other documents may supersede this document.
A list of current W3C publications and the latest
      revision of this technical report can be found in the <a href="http://www.w3.org/TR/">W3C technical reports index</a> at http://www.w3.org/TR/.</em></p>

<p>This is the <a href="http://www.w3.org/2005/10/Process-20051014/tr.html#RecsW3C">W3C Recommendation</a> of the Semantic Annotations for WSDL  and XML Schema
    specification. It has been produced by the <a href="http://www.w3.org/2002/ws/sawsdl/">SAWSDL Working Group</a>, which is part of the <a href="http://www.w3.org/2002/ws/">W3C Web Services Activity</a>.</p>

<p>Feedback on this document is welcome on the
   public mailing list <a href="mailto:public-ws-semann-comments@w3.org">public-ws-semann-comments@w3.org</a> (<a href="http://lists.w3.org/Archives/Public/public-ws-semann-comments/">public archive</a>). </p>
    <p>The Working Group released an <a href="http://www.w3.org/2002/ws/sawsdl/CR/">implementation report</a> and a <a href="http://www.w3.org/2002/ws/sawsdl/CR/testsuite.html">test suite</a>. A <a href="sawsdl-diff.html">diff-marked version</a> against the previous version of this document is available.</p>

<p>This document has been reviewed by W3C Members, by software developers, and by other W3C groups and interested parties, and is endorsed by the Director as a W3C Recommendation. It is a stable document and may be used as reference material or cited from another document. W3C's role in making the Recommendation is to draw attention to the specification and to promote its widespread deployment. This enhances the functionality and interoperability of the Web.</p>

 <p>This document was produced by a group operating under the <a
   href="http://www.w3.org/Consortium/Patent-Policy-20040205/">5 February
   2004 W3C Patent Policy</a>. W3C maintains a <a
   href="http://www.w3.org/2004/01/pp-impl/39001/status" rel="disclosure">public
   list of any patent disclosures</a> made in connection with the
   deliverables of the group; that page also includes instructions for
   disclosing a patent. An individual who has actual knowledge of a patent
   which the individual believes contains <a
   href="http://www.w3.org/Consortium/Patent-Policy-20040205/#def-essential">Essential
   Claim(s)</a> must disclose the information in accordance with <a
   href="http://www.w3.org/Consortium/Patent-Policy-20040205/#sec-Disclosure">section
   6 of the W3C Patent Policy</a>.</p>

</div>

<h2 id="toc">Table of Contents</h2>

<ul class="toc">
  <li><a href="#Intro">1. Introduction</a>
  <ul class="toc">
    <li><a href="#Terminology">1.1 Terminology</a></li>
    <li><a href="#Notation">1.2 Notational Conventions</a></li>
    <li><a href="#Namespace">1.3 Namespaces</a></li>
    <li><a href="#RunningExample">1.4 Example</a></li>
  </ul>
  </li>

  <li><a href="#Using">2. Annotation Mechanisms</a>
  <ul class="toc">
    <li><a href="#modelReference">2.1 SAWSDL Model Reference</a></li>
    <li><a href="#schemaMapping">2.2 SAWSDL Schema Mapping</a></li>
    <li><a href="#embedding">2.3 Embedding Semantic Models</a></li>
    <li><a href="#external">2.4 External Annotations</a></li>
  </ul>
  </li>

  <li><a href="#Using">3. Annotating WSDL Documents</a>
  <ul class="toc">
    <li><a href="#annotateWSDLInterfaces">3.1 Annotating Interfaces with Model Reference</a></li>
    <li><a href="#annotateWSDLOperations">3.2 Annotating Operations with Model Reference</a></li>
    <li><a href="#annotateWSDLFaults">3.2 Annotating Faults with Model Reference</a></li>
  </ul></li>

  <li><a href="#annotateXSD">4. Annotating XML Schema Documents</a>
  <ul class="toc">
    <li><a href="#annotateXSDModelReference">4.1 Annotating XML Schema Documents with Model Reference</a>
    <ul class="toc">
      <li><a href="#annotateXSDSimpleTypesModelReference">4.1.1 Annotating Simple Types with Model Reference</a></li>
      <li><a href="#annotateXSDComplexTypesModelReference">4.1.2 Annotating Complex Types with Model Reference</a></li>
      <li><a href="#annotateXSDElementsModelReference">4.1.3 Annotating Elements with Model Reference</a></li>
      <li><a href="#annotateXSDAttributesModelReference">4.1.4 Annotating Attributes with Model Reference</a></li>
    </ul>
    </li><li><a href="#annotateXSDSchemaMapping">4.2 Annotating XML Schema Documents with Schema Mapping</a></li>
  </ul>

  </li><li><a href="#S5">5. WSDL 1.1 Support</a>
  <ul class="toc">
    <li><a href="#attrEx">5.1 SAWSDL attrExtensions Element</a></li>
    <li><a href="#wsdl11Ann">5.2 WSDL 1.1 Annotations</a></li>
    <li><a href="#example11">5.3 Example in WSDL 1.1</a></li>
  </ul>
  </li>
  <li><a href="#rdfmapping">6. Mapping SAWSDL into RDF</a></li>

  <li><a href="#S8">7. References</a></li>
</ul>

<h3><a name="appendix" id="appendix">Appendices</a></h3>

<ul class="toc">
  <li><a href="#Example">A. An Example</a></li>
  <li><a href="#Categorization">B. Categorization Examples</a></li>
  <li><a href="#sawsdlxsd">C. XML Schema for Semantic Annotations for WSDL  and XML Schema</a></li>
  <li><a href="#Acknowledgements">D. Acknowledgements</a></li>
</ul>


<h2 id="Intro">1. Introduction</h2>

<p>Semantic Annotations for WSDL  and XML Schema (SAWSDL) defines how to add semantic
annotations to various parts of a WSDL document such as input and output message structures, interfaces and
operations. The extension attributes defined in this specification fit within the WSDL 2.0 [<a href="#WSDL2">WSDL 2.0</a>],
WSDL 1.1 [<a href="#WSDL">WSDL 1.1</a>] and XML Schema [<a href="#XMLSchemaPart1">XMLSchema Part 1: Structures</a>] extensibility frameworks. For example, this specification defines a way to annotate WSDL interfaces and operations
with categorization information that can be used to publish a Web service in a registry. The annotations on schema types can
be used during Web service discovery and composition. In addition, SAWSDL defines an annotation mechanism
for specifying the data mapping of XML Schema types to and from an ontology; such mappings could be used during invocation,
particularly when mediation is required.  To accomplish semantic annotation,
SAWSDL defines extension attributes that can be applied both to WSDL elements and to XML Schema elements.</p>

<p>The semantic annotations reference a concept in an ontology or a
mapping document. The annotation mechanism is independent of the
ontology expression language and this specification requires and enforces no
particular ontology language. It is also independent of mapping
languages and does not restrict the possible choices of such
languages.</p>

<p>The rest of the document describes
the SAWSDL extension attributes and provide examples as appropriate to illustrate their usage. For background and further examples,
read the <em>Semantic Annotations for WSDL and XML Schema &mdash; Usage Guide</em> [<a href="#SAWSDLUG">SAWSDL Usage Guide</a>].
Additionally, the SAWSDL Working Group plans to keep its <a
href="http://www.w3.org/2002/ws/sawsdl/">Working Group page</a> up to date
(at least during the lifetime of the WG) with links to known uses of SAWSDL,
including SAWSDL-aware tools, and most importantly, specifications (from W3C
and outside) that define concrete semantic models for SAWSDL annotations, and
how annotations with these models can be used.</p>


<h3 id="Terminology">1.1 Terminology</h3>

<p>The following are the basic definitions for the terminology used in this document.</p>

<dl>

  <dt>Semantic Model</dt>

  <dd>A semantic model is a set of machine-interpretable representations used to model
an area of knowledge or some part of the world, including software. Examples of
such models are ontologies that embody some community agreement, logic-based
representations, etc. Depending upon the framework or language used for
modelling, different terminologies exist for denoting the building blocks of
semantic models.</dd>

  <dt>Concept</dt>

  <dd>A concept is an element of a semantic model. This specification makes
 no assumptions about the nature of concepts, except that they must be
 identifiable by URIs. A concept can for example be a
 classifier in some language, a predicate logic relation, the value of the
 property of an ontology instance, some object instance or set of related
 instances, an axiom, etc.</dd>

  <dt>Semantic Annotation</dt>

  <dd>A semantic annotation in a document is additional information that identifies
 or defines a concept in a semantic model in order to describe part of that
 document. In SAWSDL, semantic annotations are XML attributes added to a WSDL or
 associated XML Schema document, at the XML element they describe. Semantic
 annotations are of two kinds: explicit identifiers of concepts, or identifiers
 of mappings from WSDL to concepts or vice versa.</dd>

  <dt>Semantics</dt>

  <dd>Semantics in the scope of this specification refers to sets of concepts identified by annotations.</dd>

</dl>

<h3 id="Notation">1.2 Notational Conventions</h3>

<p>The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document
are to be interpreted as described in RFC 2119 [<a href="#keywords">RFC2119</a>].</p>

<h3 id="Namespace">1.3 Namespaces</h3>

<p>The XML namespace URIs [<a href="#XMLNamespace">XML Namespaces</a>]
together with the prefixes as used by this specification are as follows:</p>

<table border="1" cellpadding="5">
  <thead>
    <tr>
      <th>Prefix</th>
      <th>Namespace name</th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>sawsdl</td>
      <td><a href="http://www.w3.org/ns/sawsdl">http://www.w3.org/ns/sawsdl</a></td>
    </tr>

    <tr>
      <td>sawsdlrdf</td>
      <td><a href="http://www.w3.org/ns/sawsdl#">http://www.w3.org/ns/sawsdl#</a></td>
    </tr>

    <tr>
      <td>wsdl</td>
      <td><a href="http://www.w3.org/ns/wsdl/">http://www.w3.org/ns/wsdl</a></td>
    </tr>

    <tr>
      <td>wsdl11</td>
      <td><a href="http://schemas.xmlsoap.org/wsdl/">http://schemas.xmlsoap.org/wsdl/</a></td>
    </tr>

    <tr>
      <td>xs</td>
      <td><a href="http://www.w3.org/2001/XMLSchema">http://www.w3.org/2001/XMLSchema</a></td>
    </tr>
  </tbody>
</table>

<h3 id="RunningExample">1.4 Example</h3>

<p>In order to illustrate the concepts of SAWSDL, later sections will use a purchase
order Web service interface. This imaginary Web service expects as input a customer account number
and a list of items to be ordered, each containing quantity information and
a product identifier in form of a Universal Product Code (UPC). The service will return the status of the order, which can
be either reject, accept or pending. The WSDL including semantic annotations for this service is given below.</p>

<pre>&lt;wsdl:description
  targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns:wsdl="http://www.w3.org/ns/wsdl"
  xmlns:xs="http://www.w3.org/2001/XMLSchema"
  xmlns:sawsdl="http://www.w3.org/ns/sawsdl"&gt;

  &lt;wsdl:types&gt;
    &lt;xs:schema targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
      elementFormDefault="qualified"&gt;
      &lt;xs:element name="OrderRequest"
          <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderRequest"
          sawsdl:loweringSchemaMapping="http://www.w3.org/2002/ws/sawsdl/spec/mapping/RDFOnt2Request.xml"</strong>&gt;
        &lt;xs:complexType&gt;
          &lt;xs:sequence&gt;
            &lt;xs:element name="customerNo" type="xs:integer" /&gt;
            &lt;xs:element name="orderItem" type="item" minOccurs="1" maxOccurs="unbounded" /&gt;
          &lt;/xs:sequence&gt;
        &lt;/xs:complexType&gt;
      &lt;/xs:element&gt;
      &lt;xs:complexType name="item"&gt;
        &lt;xs:all&gt;
          &lt;xs:element name="UPC" type="xs:string" /&gt;
        &lt;/xs:all&gt;
        &lt;xs:attribute name="quantity" type="xs:integer" /&gt;
      &lt;/xs:complexType&gt;
      &lt;xs:element name="OrderResponse" type="confirmation" /&gt;
      &lt;xs:simpleType name="confirmation"
          <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderConfirmation"</strong>&gt;
        &lt;xs:restriction base="xs:string"&gt;
          &lt;xs:enumeration value="Confirmed" /&gt;
          &lt;xs:enumeration value="Pending" /&gt;
          &lt;xs:enumeration value="Rejected" /&gt;
        &lt;/xs:restriction&gt;
      &lt;/xs:simpleType&gt;
    &lt;/xs:schema&gt;
  &lt;/wsdl:types&gt;

  &lt;wsdl:interface name="Order"
      sawsdl:modelReference="http://example.org/categorization/products/electronics"&gt;
    &lt;wsdl:operation name="order" pattern="http://www.w3.org/ns/wsdl/in-out"
        <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#RequestPurchaseOrder"</strong>&gt;
      &lt;wsdl:input element="OrderRequest" /&gt;
      &lt;wsdl:output element="OrderResponse" /&gt;
    &lt;/wsdl:operation&gt;
  &lt;/wsdl:interface&gt;
&lt;/wsdl:description&gt;</pre>

<p>The annotations in this example appear as <em>modelReference</em> and <em>loweringSchemaMapping</em>
attributes on schema and WSDL elements. Each <em>modelReference</em> shown above identifies the concept in a semantic model that describes the element to which it is
attached. For instance, the <em>OrderRequest</em> element is described by the "OrderRequest" concept in the ontology whose URI is
"http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder." A <em>loweringSchemaMapping</em> is also attached to the <em>OrderRequest</em> element
to point to a mapping, in this case an XML document, which shows how the elements within the <em>OrderRequest</em> can be mapped from
semantic data in the model.</p>

<p> Sections of this example annotated WSDL document will be used in subsequent parts of the specification where these
SAWSDL attributes are fully defined.
 </p>

<h2 id="Using">2. Annotation Mechanisms</h2>

<p>This section introduces the two basic semantic annotation constructs that SAWSDL provides. Subsequent sections explain how they can be applied to WSDL and XML Schema documents.</p>

<p>Conceptually, WSDL 2.0 has the following components to represent
service descriptions: Element Declaration, Type Definition, Interface,
Binding and Service. Of these, the first three, namely Element
Declaration, Type Definition and Interface deal with the abstract
definition of a service while the latter two deal with service
implementation. This specification focuses on semantically annotating
the abstract definition of a service to enable dynamic discovery,
composition and invocation of services. This specification does not
address the annotation of service implementations. It provides
generic reference mechanisms that can be applied, for example, to
the aforementioned components. The references can point to concepts
defined in semantic model or to mapping documents.</p>

<p>A summary of the extension attributes defined by SAWSDL is given
below:</p>

<ul>

  <li>an extension attribute, named <strong>modelReference</strong>, to
  specify the association between a WSDL or XML Schema component and a concept in some semantic
  model. It is used to to annotate XML Schema type definitions, element declarations,
  and attribute declarations as well as WSDL interfaces, operations, and faults.</li>

  <li>two extension attributes, named <strong>liftingSchemaMapping</strong>
  and <strong>loweringSchemaMapping</strong>, that are added to XML Schema
  element declarations and type definitions
  for specifying mappings between semantic data and XML.</li>

</ul>

<p>SAWSDL allows multiple semantic annotations to be associated with WSDL elements.
Both schema mappings and a model references can contain multiple pointers.
Multiple schema mappings are interpreted as alternatives whereas multiple model references
all apply. SAWSDL does not specify any other relationship between them.
More details about this are presented in the sections that follow.</p>

<h3 id="modelReference">2.1 SAWSDL Model Reference</h3>

<p>This section defines the extension attribute <em>modelReference</em>. A
model reference may be used with every element within WSDL and XML schema. However, SAWSDL
defines its meaning only for wsdl:interface, wsdl:operation, wsdl:fault, xs:element,
xs:complexType, xs:simpleType and xs:attribute.</p>

<p>The following XML schema excerpt defines the <em>modelReference</em>
attribute.</p>

<pre>&hellip;
&lt;xs:attribute name="modelReference" type="listOfAnyURI" /&gt;
&lt;xs:simpleType name="listOfAnyURI"&gt;
    &lt;xs:list itemType="xs:anyURI"/&gt;
&lt;/xs:simpleType&gt;
&hellip;</pre>

<p>The value of the <em>modelReference</em> attribute is a set of zero or more URIs, separated by
whitespaces, that identify concepts in a semantic model. Each URI is a pointer to a concept in a semantic model and is
intended to provide semantic information about the WSDL or XML Schema component being annotated.</p>

<p>The <em>modelReference</em> attribute allows multiple annotations to be associated with a given WSDL or XML Schema component via a set of URIs.
These URIs may identify concepts expressed in different semantic representation languages. When a component is annotated with a
<em>modelReference</em> that includes multiple URIs, each
of them applies to the component, but no logical relationship between them is defined by this specification.</p>

<p>SAWSDL does not define any particular way to dereference model
references, i.e., it does not prescribe how a client processor can obtain the
document in which the semantic model is defined. It is recommended that the URI
used for pointing to a semantic concept resolve to a document containing its
definition. If the semantic model is expressed using XML, it could be placed directly within the WSDL document.</p>
<p>
Sections <a href="#annotateWSDLInterfaces">3.1</a> through <a href="#annotateWSDLFaults">3.3</a> describe the use of
<em>modelReference</em> for annotating WSDL documents, whereas <a href="#annotateXSDModelReference">Section 4.1</a> describes its use for
annotating XML schema documents.</p>

<h3 id="schemaMapping">2.2 SAWSDL Schema Mapping</h3>

<p>This section defines the extension attributes
<em>liftingSchemaMapping</em> and <em>loweringSchemaMapping</em>.
SAWSDL introduces schema mapping annotations to address  post-discovery issues in using a Web service. Model references
can be used to help determine if a service meets the requirements of a client, but there may still be mismatches between the semantic model and
the structure of the inputs and outputs. For example, a client may have a given name and last name among its data, and these
values need to be concatenated in the message to the Web service. A lowering schema mapping would take the client's semantic
data and turn it into XML, and in the process it would perform the necessary concatenation to produce the full name.
In general, lifting schema mappings <em>lift</em> data from XML to a semantic
model, whereas lowering schema mappings <em>lower</em> data from a semantic
model into an XML structure.
</p>

<p>In a more complex scenario, a client may use WSDL with semantic annotations to describe the service it expects. Again, if the
XML structures expected by the client and by the service differ, schema mappings can translate the XML structures into the
semantic model where any mismatches can be understood and resolved.</p>

<p>Schema mapping relates the instance data defined by an XML Schema document with some semantic data
defined by a semantic model. Such mappings are useful in general when the structure of the instance data does not correspond trivially to the
organization of the semantic data. The mappings are used when mediation code is generated to
support invocation of a Web service.</p>

<p>The following schema excerpt defines the <em>liftingSchemaMapping</em>
and <em>loweringSchemaMapping</em> attributes.</p>

<pre>&hellip;
&lt;xs:attribute name="liftingSchemaMapping" type="listOfAnyURI" /&gt;
&lt;xs:attribute name="loweringSchemaMapping" type="listOfAnyURI" /&gt;
&lt;xs:simpleType name="listOfAnyURI"&gt;
    &lt;xs:list itemType="xs:anyURI"/&gt;
&lt;/xs:simpleType&gt;
&hellip;</pre>

<p>The usage of schema mapping attributes is further defined in <a href="#annotateXSDSchemaMapping">Section 4.2</a>.</p>

<h3 id="embedding">2.3 Embedding Semantic Models</h3>

<p>The semantic annotation mechanism defined by this specification does not
rely on any particular semantic modeling language. It only requires that the
semantic concepts defined in it be identifiable via URI references. The URIs
typically refer to concepts in a semantic model that is external to the WSDL document.
However, the URIs can also refer to elements within the WSDL document if
semantic information is included in the document via WSDL extension elements
as shown below on lines 3 to 14.</p>

<pre style="margin-left:10px;padding-left:0px">
01   &lt;wsdl:description &hellip; &gt;
02
03     &lt;rdf:RDF
04       xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
05       xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
06       xmlns:owl="http://www.w3.org/2002/07/owl#"
07       xml:base="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder"&gt;
08       &lt;owl:Class rdf:ID="OrderRequest"/&gt;
09       &lt;owl:ObjectProperty rdf:ID="has_items"&gt;
10         &lt;rdfs:domain rdf:resource="#OrderRequest"/&gt;
11         &lt;rdfs:range rdf:resource="#Item"/&gt;
12       &lt;/owl:ObjectProperty&gt;
13       &lt;owl:Class rdf:ID="Item"/&gt;
14     &lt;/rdf:RDF&gt;
15
16     &lt;wsdl:types&gt;
17       &lt;xs:element name="OrderRequest"
18           sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderRequest"&gt;
19           &hellip;
20       &lt;/xs:element&gt;
21       &hellip;
22     &lt;/wsdl:types&gt;
23
24     &lt;wsdl:interface name="Order"&gt;
25       &hellip;
26     &lt;/wsdl:interface&gt;
27   &lt;/wsdl:description&gt;
</pre>

<p>SAWSDL does not define an additional container element for embeding semantic models, since
WSDL already allows extension elements within a
<em>wsdl:description</em> element as illustrated above. In the example above the
language expressing the semantic model uses the RDF ID mechanism to define the resources
referenced, for instance line 8 defines "OrderRequest" in a semantic model.
This identifier is then referenced using <em>modelReference</em> in line 18.</p>

<h3 id="external">2.4 External Annotations (Non-Normative)</h3>

<p>This specification defines annotations that are specified as attributes in
the annotated WSDL and XML Schema documents. There are scenarios, however,
which call for annotating documents externally. For example, a WSDL document
can import an external WSDL or XML Schema and wish to add annotations to it.
Adding the annotations inside the imported document may not be possible due
to considerations like authority (the imported document comes from an external
organization unwilling to add the annotations) or because the imported
document is generated on the request from a dynamic source and the generating
process does not allow adding annotations.</p>

<p>Without creating new syntactic constructs for annotating external WSDL and
XML Schema documents, we can suggest two approaches in which our semantic
annotations can be applied externally: XSLT pre-processing, and using RDF.</p>

<p><strong>XSLT Pre-processing:</strong> as both WSDL and XML Schema are XML
languages, it is natural to use XPath to identify the elements in the
external document that should be annotated with SAWSDL (or other)
annotations. Therefore, one can construct an XSLT stylesheet that mostly
copies its input to its output, only in specific places it would add the
appropriate annotation attributes. The output of the XSLT stylesheet would be
an annotated version of the external document, ready for being processed with
a SAWSDL-aware processor.</p>

<p><strong>Using RDF:</strong> the WSDL specification [<a href="#WSDL2">WSDL
2.0</a>] contains <a
href="http://www.w3.org/TR/wsdl20/#wsdl-iri-references">Appendix C:
IRI-References for WSDL 2.0 Components</a>. This appendix defines unambiguous
URIs for identifying WSDL components. The <a
href="http://www.w3.org/XML/Schema">XML Schema Working Group</a> is working
on a component designators specification [<a href="#xmlschema-ref">XMLSchema:
Component Designators</a>] that will also provide URIs for XML Schema
components. SAWSDL <a href="#rdfmapping">Section 6</a> presents RDF
properties equivalent to the SAWSDL annotation mechanisms, therefore one can
have a WSDL document that imports an external WSDL or XML Schema document,
and also contains an RDF graph embedded as an extension (see also <a
href="#embedding">Section 2.3</a> for an example of RDF embedded in a WSDL
document). The embedded RDF graph will provide all the annotations for
the components imported from the external document.</p>

<p>There may be other mechanisms and we do not intend to mandate any
particular way of capturing external annotations. Different mechanisms will
have different properties, for instance XSLT pre-processing for adding
annotations may be fragile in face of changing input (especially if relying
on concrete element positions); this fragility may be mitigated somewhat in
the RDF approach as it identifies the components, independent of where in the
imported document they are defined.</p>

<h2 id="annotateWSDL">3. Annotating WSDL Documents</h2>

<p>In terms of the WSDL 2.0 component model, a model reference is a new
property. In particular, when used on an element that represents a WSDL
2.0 Component (e.g. a <em>wsdl:interface</em> element representing
an <a href="http://www.w3.org/TR/wsdl20/#Interface">Interface</a>
component, a <em>wsdl:operation</em> element representing an <a
href="http://www.w3.org/TR/wsdl20/#InterfaceOperation">Interface
Operation</a> component, a top-level <em>xs:element</em>
representing an <a
href="http://www.w3.org/TR/wsdl20/#component-ElementDeclaration">Element
Declaration</a> component, etc.), the <em>modelReference</em> extension
attribute with a non-empty value introduces an OPTIONAL property
{model reference} whose value is the set of URIs taken from
the value of the attribute. An empty model reference or no model
reference are both reflected by the absence of the {model reference}
property on the given component.</p>

<p>The <em>modelReference</em> annotation on xs:element, xs:complexType, xs:simpleType and xs:attribute defines the semantics of the
input or output data of WSDL operations, as shown in <a href="#annotateXSD">Section 4</a>.
A <em>modelReference</em> on a WSDL operation or fault gives semantic
information about that operation, while a <em>modelReference</em> on a WSDL interface provides a classification or other semantic
descriptions of the interface.</p>

<h3 id="annotateWSDLInterfaces">3.1 Annotating Interfaces with Model Reference</h3>

<p>This section defines how a <em>modelReference</em> can be used to
annotate <em>interface</em> elements, to categorize them according to some model,
to specify behavioral aspects or other semantic definitions.
A  <em>modelReference</em> on a
WSDL <em>interface</em> element provides a reference to a concept or concepts in a semantic model that describe
the Interface.  The example below illustrates a categorization annotation on an <em>interface</em> element.</p>

<pre>&hellip;
&lt;wsdl:interface name="Order" <strong>sawsdl:modelReference="http://example.org/categorization/products/electronics"&gt;</strong>
  &hellip;
&lt;/wsdl:interface&gt;
&hellip;</pre>

<p>The<em> modelReference</em> in this example points to a category concept "electronics" in some semantic model. For taxonomies whose elements are not identifiable with a URI, the <em>modelReference</em> can point to a simple semantic model that contains the taxonomy reference
information. This specification does not define such a categorization semantic model, but includes a non-normative example in
<a href="#Categorization">Appendix&nbsp;C</a>. SAWSDL does not constrain the form of the semantic model for categorization or that of any other semantic
model specified in a <em>modelReference</em> on an interface.</p>

<p>When an interface extends one or more interfaces, the model references of the extended interfaces
do not propagate to the new interface. In addition, annotations
applied to other WSDL components, such as operations, are separate.  SAWSDL defines no relationship between annotations.
</p>

<p>In the WSDL component model, a non-empty modelReference on a WSDL interface is represented as {model
reference} property of the Interface component; the case of an empty
modelReference or no modelReference is represented with an
Interface component that does not have a {model reference} property.</p>

<p><a href="#Categorization">Appendix C</a> further describes the use of categorization annotations including examples that show how to use
the taxonomies supported by Universal Description, Discovery and Integration (UDDI) to categorize an interface.</p>

<h3 id="annotateWSDLOperations">3.2 Annotating Operations with Model Reference</h3>

<p>The example below shows the annotated WSDL with a <em>modelReference</em>
attribute to annotate the <em>operation</em> element. The annotation of the <em>operation</em> element carries a reference
to a concept in a semantic model that provides a high level description of the
operation, specifies its behavioral aspects or includes other semantic definitions. In the purchase order example, the <em>order</em> operation can be
annotated using a class that represents a purchase order request operation. The annotation of the
operation using the <em>modelReference</em> attribute is shown below.</p>

<pre>&hellip;
&lt;wsdl:operation name="order" pattern="http://www.w3.org/ns/wsdl/in-out"
  <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#RequestPurchaseOrder"</strong>&gt;
  &lt;wsdl:input element="OrderRequest"/&gt;
  &lt;wsdl:output element="OrderResponse"/&gt;
&lt;/wsdl:operation&gt;
&hellip;</pre>

<p>Although inputs and outputs
provide one way of capturing the semantics of an operation, a simple
semantic annotation indicating the intended behavior of a given operation as a
verb concept may be useful at certain times. During service discovery, this verb
provides a coarse indication of whether this service is a match for a given
request.  This can act as way to reduce the number of services whose input and output must be checked.</p>
<p>Operations can also be annotated with category references.  These are separate from any categorizations applied to other WSDL
components (e.g. the interface holding the operation) and SAWSDL defines no relationships between categorizations applied to them.</p>

<p>In the WSDL component model, a non-empty modelReference on a WSDL interface operation is represented
as {model reference} property of the Interface Operation component; the
case of an empty modelReference or no modelReference at all is
represented with an Interface Operation component that does not have a
{model reference} property.</p>

<h3 id="annotateWSDLFaults">3.3 Annotating Faults with Model Reference</h3>

<p>The annotation of the <em>fault</em> element carries a reference
to a concept in a semantic model that provides a high level description of the
fault and can include other semantic definitions. The <em>fault</em> annotation does not describe the fault message, which should be annotated in the XML schema.
The example below illustrates how to use the <em>modelReference</em>
attribute to annotate the <em>fault</em> element. A fault that could be associated with <em>order</em> operation can be
annotated using a class that represents the failure of a purchase order request operation due to the unavailability of the item.
The annotation of a <em>fault</em> using the <em>modelReference</em> attribute is shown below.</p>

<pre>&hellip;
&lt;wsdl:interface name="Order"&gt;

  &lt;wsdl:fault name="ItemUnavailableFault" element="AvailabilityInformation"
    <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#ItemUnavailable"</strong>/&gt;
  &hellip;
&lt;/wsdl:interface&gt;</pre>

<p>This example identifies the "ItemUnavailable" concept in the referenced semantic model as a description of the fault "itemUnavailableFault."</p>

<p>In the WSDL component model a non-empty modelReference on a WSDL interface fault is represented as
{model reference} property of the Interface Fault component; the case of
an empty modelReference or no modelReference at all is represented with
an Interface Fault component that does not have a {model reference}
property.</p>

<h2 id="annotateXSD">4. Annotating XML Schema Documents</h2>

<p>In order to annotate XML schema documents, SAWSDL provides two constructs:
model reference and schema mapping. The former provides a generic link from
an XML structure to a semantic model. XML Schema model reference annotations can be used, for example, to help determine
if a service meets the requirements of a client. The schema mapping addresses post-discovery
issues when using Web services, such as how to overcome structural mismatches between the semantic model and the service inputs and outputs.</p>

<h3 id="annotateXSDModelReference">4.1 Annotating XML Schema Documents with Model Reference</h3>
<p>Model references define
additional semantics for the annotated XML Schema components.</p>

<h4 id="annotateXSDSimpleTypesModelReference">4.1.1 Annotating Simple Types with Model Reference</h4>

<p>Simple types can be annotated by including a <em>modelReference</em> attribute on the <em>xs:simpleType</em> element. An example is shown below
for the output of the <em>order</em> operation in the example WSDL document presented in <a href="#RunningExample">Section 1.4</a>.</p>

<pre>&hellip;
&lt;xs:simpleType name="Confirmation"
  <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderConfirmation"</strong>&gt;
  &hellip;
&lt;/xs:simpleType&gt;
&hellip;</pre>

<p>In this example, any element or attribute whose type is <em>Confirmation</em> is described by the <em>OrderConfirmation</em> concept in
the referenced semantic model.</p>

<p>In the XML Schema component model, a non-empty modelReference on a top-level simple type is
represented as {model reference} property of the XML Schema <a href="http://www.w3.org/TR/xmlschema-1/#Simple_Type_Definition_details">
Simple Type Definition Schema
component</a>; the case of an empty modelReference or no modelReference at
all is represented with an XML Schema Simple Type Definition component that does not have a
{model reference} property. {model reference} properties are propagated from a simple type definition schema component to all
attribute and element declaration schema components that are defined with that simple type.</p>

<p>In the WSDL component model, a non-empty modelReference on a top-level simple type used in WSDL is
represented as {model reference} property of the WSDL <a href="http://www.w3.org/TR/wsdl20/#component-TypeDefinition">Type
Definition component</a>; the case of an empty modelReference or no modelReference at
all is represented with a Type Definition component that does not have a
{model reference} property. {model reference} properties are propagated from a type definition WSDL component to all element declaration WSDL components that are defined with that type.</p>

<h4 id="annotateXSDComplexTypesModelReference">4.1.2 Annotating Complex Types with Model Reference</h4>

<p>There are two principal techniques for annotating complex types which can be
summarized as follows:</p>

<ul>
  <li>Bottom Level Annotation: Annotating at the member element or attribute level</li>
  <li>Top Level Annotation: Annotating at complex type container level</li>
</ul>

<p>In bottom level annotation, all the member elements and attributes in a complex type
can be annotated. In some cases, the members of a complex type will correspond with
the concepts in a semantic model. To accommodate this case, the member elements and attributes can be annotated
by adding a modelReference attribute to the relevant schema element or attribute.</p>

<pre>&hellip;
&lt;xs:complexType&gt;
  &lt;xs:sequence minOccurs="1" maxOccurs="unbounded"&gt;
    &lt;xs:element name="quantity" type="xs:integer"
      <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#Quantity"</strong>/&gt;
    &lt;xs:element name="UPC" type="xs:string"
      <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#ProductCode"</strong>/&gt;
  &lt;/xs:sequence&gt;
&lt;/xs:complexType&gt;
&hellip;</pre>

<p>In this <em>sequence</em>, each bottom level <em>element</em> has an annotation since the semantic model contains concepts,
namely "Quantity" and "ProductCode", that describe each of the components of the complex type.</p>

<p>Bottom level annotation uses the mechanisms described below in sections
<a href="#annotateXSDElementsModelReference">4.1.3</a> and
<a href="#annotateXSDAttributesModelReference">4.1.4</a>.
</p>

<p>In top level annotation, the complex types themselves are annotated with
model references. If multiple concepts describe the complex type, all of their
URIs can be included in the value of the <em>modelReference</em> attribute.
This <em>sawsdl:modelReference</em>
attribute on a complex type annotates the type as a whole, but does not
necessarily make any specific statements about the elements or attributes within the complex type.</p>

<pre>&hellip;
&lt;xs:complexType <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderRequest"</strong>&gt;
  &lt;xs:sequence minOccurs="1" maxOccurs="unbounded"&gt;
    &lt;xs:element name="quantity" type="xs:integer"
    &lt;xs:element name="UPC" type="xs:string"
  &lt;/xs:sequence&gt;
&lt;/xs:complexType&gt;
&hellip;</pre>

<p>Here, the <em>complexType</em> as a whole has been annotated with a reference to the <em>OrderRequest</em> concept.
<em>OrderRequest</em> describes a concept that groups "quantity" and "UPC" elements that make up the complex type.</p>

<p>A complex type can be annotated at both the top and bottom level. These annotations are independent of each other.
</p>

<p>In the XML schema component model, a non-empty modelReference on a
top-level complex type is represented as {model reference} property of
the XML Schema <a href="http://www.w3.org/TR/xmlschema-1/#Complex_Type_Definition_details">Complex Type Definition component</a>; the case of an empty modelReference or no modelReference at
all is represented with a type definition schema component that does not have a
{model reference} property. {model reference} properties are propagated
from a complex type definition schema component to all
element declaration schema components that are defined with that complex type.</p>

<p>In the WSDL component model, a non-empty modelReference on a top-level
complex type used in WSDL is represented as {model reference} property of the WSDL <a href="http://www.w3.org/TR/wsdl20/#component-TypeDefinition">Type Definition
component</a>; the case of an empty modelReference or no modelReference at
all is represented with a Type Definition component that does not have a
{model reference} property. {model reference} properties are propagated
from a type definition component to all
element declaration components that are defined with that type.</p>

<h4 id="annotateXSDElementsModelReference">4.1.3 Annotating Elements with Model Reference</h4>

<p>An element declaration can be annotated by including a <em>modelReference</em> on the <em>xs:element</em> element.
An example of annotating a global <em>element</em> using the <em>modelReference</em>
attribute is shown below.</p>

<pre>&hellip;
&lt;xs:element name="OrderRequest"
    <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderRequest"</strong>&gt;
  &lt;xs:complexType&gt;
    &lt;xs:sequence&gt;
      &lt;xs:element name="customerNo" type="xs:integer" /&gt;
      &lt;xs:element name="orderItem" type="item" minOccurs="1" maxOccurs="unbounded" /&gt;
    &lt;/xs:sequence&gt;
  &lt;/xs:complexType&gt;
&lt;/xs:element&gt;
&hellip;</pre>

<p>In this example, the annotation indicates that the <em>element</em> "OrderRequest" is described by the
concept "OrderRequest" in the referenced semantic model. This example is very similar to a top-level <em>complexType</em> annotation
in that the <em>element</em> being annotated is defined in terms of a <em>complexType</em> and the annotation describes the "OrderRequest" as
a whole.</p>

<p>A non-empty modelReference on a top-level element declaration used in
WSDL is represented as {model reference} property of the WSDL <a href="http://www.w3.org/TR/wsdl20/#component-ElementDeclaration">Element
Declaration component</a>
or the XML Schema <a href="http://www.w3.org/TR/xmlschema-1/#Element_Declaration_details">Element
Declaration Component</a>; the case of an empty modelReference or no
modelReference at all is represented with a WSDL or XML Schema Element Declaration
component that does not have a {model reference} property.
Due to model reference propagation, element declaration {model reference} property also contains the values of the
{model reference} property from the type definition component referenced by this element declaration.</p>

<h4 id="annotateXSDAttributesModelReference">4.1.4 Annotating Attributes with Model Reference</h4>

<p>An attribute can be annotated by including a <em>modelReference</em> on the <em>xs:attribute</em> element. If the quantity element in the
example above were defined as an attribute, a <em>modelReference</em> could be applied to it as follows.</p>

<pre>&hellip;
&lt;xs:attribute name="quantity" type="xs:integer"
    <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#Quantity"</strong>/&gt;
&hellip;</pre>

<p>This annotation indicates that the <em>attribute</em> "quantity" is described by the concept "Quantity" in the referenced
semantic model.</p>

<p>In the XML schema component model, a non-empty modelReference on a
top-level attribute declaration is represented as {model reference}
property of the XML Schema <a href="http://www.w3.org/TR/xmlschema-1/#Attribute_Declaration_details">Attribute
Declaration Schema component</a>; the case of an empty modelReference or no
modelReference at all is represented with an Attribute Declaration Schema
component that does not have a {model reference} property.
Due to model reference propagation, attribute declaration {model reference} property also contains the values of the
{model reference} property from the simple type definition component referenced by this attribute declaration.</p>


<h3 id="annotateXSDSchemaMapping">4.2 Annotating XML Schema Documents with Schema Mapping</h3>

<p>The extension attributes <em>liftingSchemaMapping</em> and <em>loweringSchemaMapping</em>
are used to associate a schema type or element with a mapping to an
ontology. Schema mappings may be added to global type
definitions (complex or simple) as well as to global element declarations. It is
possible to specify either lowering or lifting information as well as both together
on the same schema element.</p>

<p>The value of the <em>liftingSchemaMapping</em> attribute is a set of zero or more URIs that reference
mapping definitions. A mapping referenced by this attribute
defines how an XML instance document conforming to the element or type defined
in a schema is transformed to data that conforms to some semantic model, i.e. the
output of the transformation process will be semantic data. The input to the
transformation is the XML element on whose declaration the mapping is located; or an
element valid according to the type on whose definition the mapping is located.</p>

<p>The value of the <em>loweringSchemaMapping</em> attribute is a set of zero or more URIs that
reference mapping definitions. A mapping referenced by this attribute
defines how data in a semantic model is transformed to XML instance data. The
input will be some semantic data. The output of the process will be the XML
element on whose declaration the mapping is located; or an element valid
according to the type on whose definition the mapping is located.</p>

<p>When multiple URIs are specified on liftingSchemaMapping or loweringSchemaMapping, the schema
mappings they reference are to be treated as alternatives, i.e. the client processor should choose one of them to apply, and the choice is
fully at the client processor's discretion. For example, a mapping can be selected based on what mapping language the
processor supports (different alternatives can use different languages), based on the availability of the mapping document,
or by other preferences.</p>

<p>This specification provides a mechanism for associating optional schema
mapping functions with a global type definition or global element declaration without any
restriction on the choice of the mapping language. Just as SAWSDL does not prescribe
any particular ontology representation language for specifying modelReferences,
 it does not prescribe
any particular mapping representation language.</p>

<p>The following excerpt
from the purchase order example shows how XSLT can be used as a schema mapping
language to specify mapping from XSD elements to concepts in a semantic
model. Detailed examples showing schema mapping using XSLT [<a href="#XSLT">XSLT</a>] and
SPARQL [<a href="#SPARQL">SPARQL</a>] are shown in <a href="#Example">Appendix A</a>. Other languages,
such as XQuery [<a href="#XQuery">XQuery</a>], can also be used.</p>

<pre>&hellip;
&lt;xs:element name="OrderResponse" type="confirmation" /&gt;
&lt;xs:simpleType name="confirmation"
    sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderConfirmation"
    <strong>sawsdl:liftingSchemaMapping="http://www.w3.org/2002/ws/sawsdl/spec/mapping/Response2Ont.xslt"</strong>&gt;
  &lt;xs:restriction base="xs:string"&gt;
    &lt;xs:enumeration value="Confirmed" /&gt;
    &lt;xs:enumeration value="Pending" /&gt;
    &lt;xs:enumeration value="Rejected" /&gt;
  &lt;/xs:restriction&gt;
&lt;/xs:simpleType&gt;
&hellip;</pre>

<p>In order to perform the lifting of the data contained in an XML message, a client
processor retrieves the transformation from the URI given in
the value of sawsdl:liftingSchemaMapping (or from a cache or registry etc.) and applies it to those
elements where the schema mapping was specified. In the example above
<em>http://www.w3.org/2002/ws/sawsdl/spec/mapping/Response2Ont.xslt</em>
will be applied to <em>OrderResponse</em> elements. A mapping specified
on a global type definition can be applied to any element that is of that type.</p>

<p>A mapping specified on an element, including an empty value (""), overrides any mappings specified on its type. If no
mapping is specified on the element, the mapping on its type applies to the element.
</p>

<p>The following example illustrates this rule. The element <em>orderItem</em> has a
<em>liftingSchemaMapping</em>. The complex type of <em>orderItem</em> is defined later in the schema and the
complex type itself has a schema mapping. In such a case, the <em>liftingSchemaMapping</em> specified on the element overrides the one
specified on the complex type. This means that only the schema mapping that is given with the URI
http://example.org/mapping/OrderItem2Ont.xslt applies to the element orderItem.
The mapping http://example.org/mapping/ItemType2Ont.xslt does not apply. The reason for
specifying such an override rule is to allow an element to indicate the type mapping does not apply.</p>

<pre>&hellip;
&lt;xs:element name="orderItem" type="itemType"
  <strong>sawsdl:liftingSchemaMapping="http://example.org/mapping/OrderItem2Ont.xslt"</strong>/&gt;

&lt;xs:complexType name="itemType"
  <strong>sawsdl:liftingSchemaMapping="http://example.org/mapping/ItemType2Ont.xslt"</strong>&gt;
  &lt;xs:sequence&gt;
      &lt;xs:element ref="partDesc" /&gt;
  &lt;/xs:sequence&gt;
  &lt;xs:attribute name="ItemID" type="xs:string"/&gt;
&lt;/xs:complexType&gt;
&hellip;
</pre>

<p>When used on an element that represents a WSDL 2.0 Component (a
top-level <em>xs:element</em> element representing an <a
href="http://www.w3.org/TR/wsdl20/#component-ElementDeclaration">Element
Declaration</a> component, an <em>xs:complexType</em> element or an
<em>xs:simpleType</em> element representing a <a
href="http://www.w3.org/TR/wsdl20/#component-TypeDefinition">Type
Definition</a> component), the loweringSchemaMapping and
liftingSchemaMapping extension attributes introduce the properties
{lowering schema mapping} and {lifting schema mapping}.</p>

<p>When used on an element that represents an XML Schema <a href="http://www.w3.org/TR/xmlschema-1/#components">Component</a>
(a top-level Element Declaration Schema component element, a Complex Type Definition Schema component or a
Simple Type Definition Schema component), the loweringSchemaMapping and
liftingSchemaMapping extension attributes introduce properties
{lowering schema mapping} and {lifting schema mapping}.</p>

<p>
The value of either of these properties is a (possibly empty) set of URIs taken from
the value of the respective attribute. If an element declaration does not
have a liftingSchemaMapping (or loweringSchemaMapping) attribute but its type
definition does, the element declaration component acquires the {lifting
schema mapping} (or {lowering schema mapping}) property from the type
definition component.</p>


<h2 id="S5">5. WSDL 1.1 Support</h2>

<p>The mechanism for semantic annotation described in this specification can
also be applied to WSDL 1.1 [<a href="#WSDL">WSDL 1.1</a>] Web
service descriptions. All the XML attributes defined in this
specification apply without modification to the WSDL 1.1 descriptions. However,
in some cases they are applied to different elements in the WSDL document
structure and a new element is introduced to facilitate operation annotations.</p>

<h3 id="attrEx">5.1 SAWSDL attrExtensions Element</h3>

<p>The <a href="http://schemas.xmlsoap.org/wsdl/">WSDL 1.1 schema</a> does not allow extension attributes on the <em>operation</em> element, so this specification introduces a new
extension element, <em>attrExtensions</em>, to support semantic annotation of WSDL 1.1 operations.  The following XML
Schema excerpt defines the <em>attrExtensions</em> element.</p>

<pre>
&hellip;
&lt;xs:element name="attrExtensions"&gt;
  &lt;xs:complexType&gt;
    &lt;xs:anyAttribute namespace="##any" processContents="lax" /&gt;
  &lt;/xs:complexType&gt;
&lt;/xs:element&gt;
&hellip;
</pre>

<p>The <em>attrExtensions</em> element provides a general mechanism for adding extension attributes where attribute extensibility
is not allowed, but element extensibility is allowed.
It SHOULD NOT be used where attribute extensibility is allowed.
For SAWSDL it is used to add the sawsdl:modelReference attribute in
WSDL 1.1 operations. It MUST NOT be used for SAWSDL annotations in WSDL 2.0. Attributes with the same namespace
name and local name MUST NOT appear both on the attrExtensions element and on its parent element.</p>

<h3 id="wsdl11Ann">5.2 WSDL 1.1 Annotations</h3>
<p><em>portTypes</em></p>

<p>A <em>portType</em> corresponds to a WSDL 2.0 <em>interface</em> and is annotated in the same way.</p>

<p><em>Input and Output</em></p>

<p>Annotation of XML Schema types with <em>modelReference</em>, <em>liftingSchemaMapping</em> or <em>loweringSchemaMapping</em> can be accomplished using the approach
described for annotating these elements in WSDL 2.0. In addition, a <em>liftingSchemaMapping</em>, <em>loweringSchemaMapping</em>
or <em>modelReference</em> attribute may be added to a <em>part</em> element
(under a <em>message</em> element) to specify an input or output annotation that
applies to the entire message part. Message parts are referenced from the <em>portType</em>
structure in WSDL 1.1 that generally corresponds to the WSDL 2.0 <em>interface</em>
structure.</p>

<p><em>Faults</em></p>

<p>In WSDL 1.1, faults are specified as messages within operations.
In contrast to WSDL 2.0, a WSDL 1.1 fault is defined identically
to an input or output, i.e. as a <em>fault</em> subelement of the
<em>operation</em> element. Annotation of the meaning of the fault needs to be
done  on the <em>fault</em> element in each operation where it occurs.

</p>

<p><em>Operations</em></p>

<p>Because operation in WSDL 1.1 does not allow attribute extensibility, an <em>operation</em> is annotated by adding an <em>attrExtensions</em> element as a child of the <em>operation</em> element.
The <em>modelReference</em> attribute of <em>attrExtensions</em> specifies the operation annotation.  An example of such an
annotation is shown below.</p>
<pre>&hellip;
&lt;wsdl11:operation name="order"&gt;
    &lt;<strong>sawsdl:attrExtensions
        sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#RequestPurchaseOrder"</strong>&gt;
    &lt;wsdl11:input message="OrderRequestMessage"/&gt;
    &lt;wsdl11:output message="OrderResponseMessage"/&gt;
&lt;/wsdl11:operation&gt;
&hellip;
</pre>

<h3 id="example11">5.3 Example in WSDL 1.1</h3>

<p>The same example as shown in <a href="#RunningExample">Section 1.4</a> is shown here in its WSDL 1.1
form.  An important difference is the way messages are defined:</p>

<ul>
  <li>The message structure is defined in terms of message parts.
  For the response message, the SAWSDL annotation is applied to
  the <em>part</em> element named <em>OrderResponse</em>. In the
  WSDL 2.0 example, this annotation was applied to the
  <em>OrderResponse</em> element in the schema. This annotation could have
  been left the same in the WSDL 1.1 example, but was applied
  in this way to illustrate the annotation of message parts.</li>

  <li>The definition of the <em>OrderResponse</em> element was not
  included in the schema since the <em>OrderResponse</em> message
  part fills its role.</li>
</ul>

<p>The other difference is the inclusion of <em>attrExtensions</em> to annotate the operation.</p>

<pre>
&lt;wsdl11:definitions
  targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns:wsdl11="http://schemas.xmlsoap.org/wsdl/"
  xmlns:xs="http://www.w3.org/2001/XMLSchema"
  xmlns:sawsdl="http://www.w3.org/ns/sawsdl"
  name="OrderService"&gt;

  &lt;wsdl11:types&gt;
    &lt;xs:schema
      targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
      xmlns="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
      elementFormDefault="qualified"&gt;
      &lt;xs:element name="OrderRequest"
        <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderRequest"
        sawsdl:liftingSchemaMapping="http://www.w3.org/2002/ws/sawsdl/spec/mapping/Response2Ont.xslt"</strong>&gt;
        &lt;xs:complexType&gt;
          &lt;xs:sequence&gt;
            &lt;xs:element name="customerNo" type="xs:integer" /&gt;
            &lt;xs:element name="orderItem" type="item" minOccurs="1" maxOccurs="unbounded" /&gt;
          &lt;/xs:sequence&gt;
        &lt;/xs:complexType&gt;
      &lt;/xs:element&gt;
      &lt;xs:complexType name="item"
        <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#Item"</strong>&gt;
        &lt;xs:all&gt;
          &lt;xs:element name="UPC" type="xs:string" /&gt;
        &lt;/xs:all&gt;
        &lt;xs:attribute name="quantity" type="xs:integer" /&gt;
      &lt;/xs:complexType&gt;
      &lt;xs:simpleType name="Confirmation"&gt;
        &lt;xs:restriction base="xs:string"&gt;
          &lt;xs:enumeration value="Confirmed"/&gt;
          &lt;xs:enumeration value="Pending"/&gt;
          &lt;xs:enumeration value="Rejected"/&gt;
        &lt;/xs:restriction&gt;
      &lt;/xs:simpleType&gt;
    &lt;/xs:schema&gt;
  &lt;/wsdl11:types&gt;

  &lt;wsdl11:message name="OrderRequestMessage"&gt;
    &lt;wsdl11:part name="OrderRequest" element="OrderRequest" /&gt;
  &lt;/wsdl11:message&gt;
  &lt;wsdl11:message name="OrderResponseMessage"&gt;
    &lt;wsdl11:part name="OrderResponse" type="Confirmation"
      <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderConfirmation"/</strong>&gt;
  &lt;/wsdl11:message&gt;

  &lt;wsdl11:portType name="Order"&gt;
    &lt;wsdl11:operation name="order"&gt;
      &lt;sawsdl:attrExtensions
        <strong>sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#RequestPurchaseOrder"/&gt;</strong>
      &lt;wsdl11:input message="OrderRequestMessage" /&gt;
      &lt;wsdl11:output message="OrderResponseMessage" /&gt;
    &lt;/wsdl11:operation&gt;
  &lt;/wsdl11:portType&gt;
&lt;/wsdl11:definitions&gt;
</pre>
<p>This example is available as a separate file at <a
  href="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order11">http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order11</a>.</p>





<h2 id="rdfmapping">6. Mapping SAWSDL into RDF</h2>

<p>This section describes how the WSDL extensions introduced in this document
are mapped into an RDF form compatible with the WSDL&nbsp;2.0 RDF Mapping [<a
href="#WSDL2RDF">WSDL&nbsp;2.0&nbsp;RDF</a>]. This specification introduces the
properties {model reference}, {lifting schema mapping} and {lowering schema
mapping}, and this section describes the equivalent RDF properties. However,
since the WSDL&nbsp;2.0 RDF mapping does not provide an RDF form for the
element declaration and type definition components, the schema mapping
properties (i.e. {lifting schema mapping} and {lowering schema mapping})
potentially present in SAWSDL documents, are currently not represented in the
RDF form of WSDL documents. Only {model reference} properties are mapped.</p>

<p>The {model reference} property on any WSDL component
(esp. Interface, Interface Operation, and Interface Fault components, as described earlier in
this document) is represented in the RDF form using a property with the
identifier <em>sawsdlrdf:modelReference</em> (the full URI of the property is then
"http://www.w3.org/ns/sawsdl#modelReference"), as shown in
table 6-1. As the value of {model reference} is a set of URIs,
an RDF triple is introduced for each of the URIs.</p>

<div class="mappingtable">
<table cellpadding="4" width="100%" border="1">
  <caption><a id="table6-1">Table 6-1.</a>&nbsp;Mapping modelReference
    property to RDF</caption>
  <col width="20%" /><col width="80%" />
  <tbody>
    <tr>
      <th>Property</th>

      <th>RDF Form</th>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td> <em>(componentId of the parent component generated per <a href="http://www.w3.org/TR/wsdl20/#wsdl-iri-references">IRI-References for WSDL&nbsp;2.0 Components</a>)</em></td>
    </tr>
    <tr>

      <td> {model reference}</td>
      <td> <em>(for each URI &lt;uri&gt; in the value of {model reference})</em><br/>
      &lt;componentId&gt; sawsdlrdf:modelReference &lt;uri&gt; .</td>
    </tr>

  </tbody>
</table>
</div>

<p>Similarly, the {lifting schema mapping} and {lowering schema mapping}
properties can be represented in RDF (within a hypothetical RDF mapping of
XML Schema) using the properties sawsdlrdf:liftingSchemaMapping and
sawsdlrdf:loweringSchemaMapping (the full URIs of the properties are then
"http://www.w3.org/ns/sawsdl#liftingSchemaMapping" and
"http://www.w3.org/ns/sawsdl#loweringSchemaMapping"). As the values of both
{lifting schema mapping} and {lowering schema mapping} are
sets of URIs, appropriate RDF triples are introduced for each of the URIs.</p>

<p>The following listing defines the three properties in RDF:</p>

<pre> &lt;http://www.w3.org/ns/sawsdl#modelReference&gt; rdf:type rdf:Property .
 &lt;http://www.w3.org/ns/sawsdl#liftingSchemaMapping&gt; rdf:type rdf:Property .
 &lt;http://www.w3.org/ns/sawsdl#loweringSchemaMapping&gt; rdf:type rdf:Property .</pre>








<h2 id="S8">7. References</h2>
<h3 id="normativeref">7.1 Normative References</h3>
<dl>

  <dt>[<a name="keywords" id="keywords">RFC2119</a>]</dt>
  <dd><cite><a href="http://www.ietf.org/rfc/rfc2119.txt">Key
  words for use in RFCs to Indicate Requirement Levels</a></cite>, S. Bradner, Author.
  Internet Engineering Task Force, June 1999. Available at
  http://www.ietf.org/rfc/rfc2119.txt.</dd>



  <dt>[<a name="WSDL" id="WSDL">WSDL 1.1</a>]</dt>
  <dd><a href="http://www.w3.org/TR/2001/NOTE-wsdl-20010315"><cite>W3C
  Note, Web Services Description Language (WSDL) 1.1</cite></a> Erik Christensen, Francisco
  Curbera, Greg Meredith and Sanjiva Weerawarana, Authors. Available at
  http://www.w3.org/TR/2001/NOTE-wsdl-20010315.</dd>



  <dt>[<a name="WSDL2" id="WSDL2">WSDL 2.0</a>]</dt>
  <dd><cite><a href="http://www.w3.org/TR/2007/PR-wsdl20-20070523/">Web
  Services Description Language (WSDL) Version 2.0 Part 1: Core Language</a></cite>, R.
  Chinnici, J-J. Moreau, A. Ryman, S. Weerawarana, Editors. World Wide Web
  Consortium, 23 May 2007. This version of the "Web Services Description
  Language (WSDL) Version 2.0 Part 1: Core Language" Specification is available
  is available at http://www.w3.org/TR/2007/PR-wsdl20-20070523. The <a
    href="http://www.w3.org/TR/wsdl20/">latest version of "Web Services
  Description Language (WSDL) Version 2.0 Part 1: Core Language"</a> is available at
  http://www.w3.org/TR/wsdl20.</dd>


  <dt><a name="XMLNamespace" id="XMLNamespace">[XML Namespaces]</a></dt>
  <dd><cite><a
    href="http://www.w3.org/TR/1999/REC-xml-names-19990114/">Namespaces in
  XML</a></cite>, T. Bray, D. Hollander, and A. Layman, Editors. World Wide Web Consortium,
  14 January 1999. This version of the Namespaces in XML Recommendation is
  http://www.w3.org/TR/1999/REC-xml-names-19990114. The <a
    href="http://www.w3.org/TR/REC-xml-names/">latest version of Namespaces
  in XML</a> is available at http://www.w3.org/TR/REC-xml-names.</dd>


  <dt id="XMLSchemaPart1">[XMLSchema Part 1: Structures]</dt>
  <dd><cite><a
    href="http://www.w3.org/TR/2004/REC-xmlschema-1-20041028/">XML Schema
  Part 1: Structures</a></cite>, H. Thompson, D. Beech, M. Maloney, and N. Mendelsohn,
  Editors. World Wide Web Consortium, 28 October 2004. This version of the XML
  Schema Part 1 Recommendation is
  http://www.w3.org/TR/2004/REC-xmlschema-1-20041028. The <a
    href="http://www.w3.org/TR/xmlschema-1/">latest version of XML Schema
  Part 1</a> is available at http://www.w3.org/TR/xmlschema-1.</dd>

</dl>



<h3 id="informativeref">7.2 Informative References</h3>

<dl>


  <dt>[<a name="GICS" id="GICS">GICS</a>]</dt>
  <dd><a href="http://www.msci.com/equity/gics.html"><cite>Global
  Industry Classification Standard.</cite></a> Available at
  http://www.msci.com/equity/gics.html.</dd>



  <dt>[<a name="NAICS" id="NAICS">NAICS</a>]</dt>
  <dd><a href="http://www.census.gov/epcd/www/naics.html"><cite>North
  American Industry Classification System.</cite></a> Available at
  http://www.census.gov/epcd/www/naics.html.</dd>



  <dt><a name="OWL" id="OWL">[OWL]</a></dt>
  <dd><a href="http://www.w3.org/TR/2004/REC-owl-ref-20040210/"> <cite>OWL
  Web Ontology Language Reference</cite></a>, Mike Dean and Guus Schreiber, Editors. W3C
  Recommendation, 10 February 2004,
  http://www.w3.org/TR/2004/REC-owl-ref-20040210/.<br />
  <a href="http://www.w3.org/TR/owl-ref/">Latest version</a> available at
  http://www.w3.org/TR/owl-ref/.</dd>



<dt>[<a name="SAWSDLUG" id="SAWSDLUG">SAWSDL Usage Guide</a>]</dt>
  <dd><a href="http://www.w3.org/TR/2007/NOTE-sawsdl-guide-20070828/"> <cite>Semantic Annotations for WSDL and XML Schema - Usage Guide</cite></a>,
  Rama Akkiraju and Brahmananda Sapkota, Editors. W3C
  Working Group Note, 28 August 2007,
  http://www.w3.org/TR/2007/NOTE-sawsdl-guide-20070828/.<br />
  <a href="http://www.w3.org/TR/sawsdl-guide/">Latest version</a> available at
  http://www.w3.org/TR/sawsdl-guide/.</dd>



  <dt>[<a name="SPARQL" id="SPARQL">SPARQL</a>]</dt>
  <dd><a href="http://www.w3.org/TR/rdf-sparql-query/"><cite>SPARQL Query Language for RDF</cite></a>,
  Eric Prud'hommeaux and Andy Seaborne, Editors. World Wide Web Consortium,
  14 June 2007. This version is
  http://www.w3.org/TR/2007/CR-rdf-sparql-query-20070614/. The <a
    href="http://www.w3.org/TR/rdf-sparql-query/">latest version</a> is available at
  http://www.w3.org/TR/rdf-sparql-query/.</dd>


  <dt>[<a name="UDDI" id="UDDI">UDDI</a>]</dt>
  <dd><a href="http://uddi.org/pubs/uddi_v3.htm"><cite>UDDI Version 3.0.2</cite></a>, Luc Clement,
  Andrew Hately, Claus von Riegen, and Tony Rogers, Editors.
  Organization for the Advancement of Structured Information Standards (OASIS). Available at
  http://uddi.org/pubs/uddi_v3.htm.</dd>


  <dt>[<a name="UNSPSC" id="UNSPSC">UNSPSC</a>]</dt>
  <dd><a href="http://www.unspsc.org/"><cite>The United Nations
  Standard Products and Services Code.</cite></a> United Nations Development Programme.
  Available at http://www.unspsc.org/.</dd>


  <dt>[<a name="WSDL2RDF" id="WSDL2RDF">WSDL 2.0 RDF</a>]</dt>
  <dd><cite><a href="http://www.w3.org/TR/2007/WD-wsdl20-rdf-20070523/">Web
  Services Description Language (WSDL) Version 2.0: RDF Mapping</a></cite>,
  J. Kopecky, B. Parsia, Editors. World Wide Web
  Consortium, 23 May 2007. This version of the "Web Services Description
  Language (WSDL) Version 2.0: RDF Mapping" Specification is available
  at http://www.w3.org/TR/2007/WD-wsdl20-rdf-20070523/. The <a
    href="http://www.w3.org/TR/wsdl20-rdf/">latest version of "Web Services
  Description Language (WSDL) Version 2.0: RDF Mapping"</a> is available at
  http://www.w3.org/TR/wsdl20-rdf/.</dd>


  <dt><a name="xmlschema-ref" id="xmlschema-ref">[XMLSchema: Component Designators]</a></dt>
  <dd><cite><a
    href="http://www.w3.org/TR/2005/WD-xmlschema-ref-20050329/">XML Schema:
    Component Designator</a></cite>, M. Holstege and A.S. Vedamuth, Editors. World Wide Web
  Consortium, 29 March 2005. This version of the XML Schema: Component
  Designators Working Draft is http://www.w3.org/TR/2005/WD-xmlschema-ref-20050329/. The <a
    href="http://www.w3.org/TR/xmlschema-ref/">latest version of XML Schema:
    Component Designators</a> is available at
    http://www.w3.org/TR/xmlschema-ref/.</dd>


  <dt>[<a name="XQuery" id="XQuery">XQuery</a>]</dt>
  <dd><a href="http://www.w3.org/TR/xquery/"><cite>XQuery 1.0:
  An XML Query Language</cite></a>, Scott Boag, Don Chamberlin, Mary F.
  Fern&aacute;ndez, Daniela Florescu, Jonathan Robie, J&eacute;r&ocirc;me
  Sim&eacute;on, Editors. World Wide Web Consortium, 23 January 2007. This version is
  http://www.w3.org/TR/2007/REC-xquery-20070123/. The <a
    href="http://www.w3.org/TR/xquery/">latest version</a> is available at
  http://www.w3.org/TR/xquery/.</dd>


  <dt>[<a name="XSLT" id="XSLT">XSLT</a>]</dt>
  <dd><a href="http://www.w3.org/TR/xslt20/"><cite>XSL
  Transformations (XSLT) Version 2.0</cite></a>, Michael Kay, Editor. World Wide Web
  Consortium, 23 January 2007. This version is
  http://www.w3.org/TR/2007/REC-xslt20-20070123/. The <a
    href="http://www.w3.org/TR/xslt20/">latest version</a> is available at
  http://www.w3.org/TR/xslt20/.</dd>

</dl>



<h2 id="Example">A. An Example (Non-Normative)</h2>

<p>In this appendix we present the accompanying
semantic descriptions and mappings to the example WSDL document
presented in <a href="#RunningExample">Section 1.4</a>. We also
provide examples on what the documents, pointed to by the schema mapping,
might look like.</p>

<p>The files used in this example are:</p>
<ul>
  <li>A WSDL file including SAWSDL annotation: <a
  href="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order">http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order</a>
  </li>
  <li>A purchase order ontology: <a
    href="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder">http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder</a></li>
  <li>A lowering schema mapping using SPARQL and XSLT: <a
    href="http://www.w3.org/2002/ws/sawsdl/spec/mapping/RDFOnt2Request.xml">http://www.w3.org/2002/ws/sawsdl/spec/mapping/RDFOnt2Request.xml</a></li>
  <li>A lifting schema mapping using XSLT: <a
    href="http://www.w3.org/2002/ws/sawsdl/spec/mapping/Response2Ont.xslt">http://www.w3.org/2002/ws/sawsdl/spec/mapping/Response2Ont.xslt</a></li>
  <li>A lifting schema mapping using XQuery: <a
    href="http://www.w3.org/2002/ws/sawsdl/spec/mapping/Response2Ont.xq">http://www.w3.org/2002/ws/sawsdl/spec/mapping/Response2Ont.xq</a></li>
</ul>

<p>The following subsections illustrate the two directions of the schema mapping:
lifting and lowering. Lifting schema mapping transforms XML data into instances of a
semantic model, and lowering schema mapping does the opposite, it transforms
semantic model instances into XML data.</p>

<p>Since SAWSDL does not constrain the language of the semantic model nor
the mapping language, the following can only be viewed as non-normative examples.
In our setting we have chosen to base the examples on languages standardized by the W3C.
For example, an RDF-based semantic Web service client may wish to invoke an
operation that it earlier discovered. The client would have some RDF data
that it intends to pass to the operation as the request XML message, lowering
from RDF to XML. When the service replies with the response XML message, the
client will need to lift the data back to RDF in order to process it.
When using other languages to express the semantic model, mappings
may be expressed using those languages.
</p>

<h3 id="lifting">A.1 Specifying Lowering Schema Mapping</h3>

<p>When expressing the semantic model using RDF/XML, lowering schema mappings
are potentially complex, because of the flexible nature of
RDF/XML. RDF/XML is an XML serialization of the graph-of-triples model of RDF
data. In essence, RDF data is always an unordered set of triples consisting
of a subject, a predicate and an object. The XML serialization puts the
values of these parts of the triples alternatively into namespace-qualified
XML element and attribute names, and into character values of elements or
attributes. Languages like XSLT or XQuery rely on XPath to find and select
data in XML structures. XPath is geared towards more fixed XML structures, so
it takes different XPath expressions for instance to select predicates, which
can be encoded as elements or attributes in many places within an RDF/XML
document. XPath (and by extension XSLT and XQuery) does not provide means of
ignoring the purely syntactical differences in the various possible RDF/XML
serializations of otherwise equal RDF graphs, therefore all alternatives have
to be accounted for in the XSLT stylesheet or XQuery query.</p>

<p>Practice has shown that it is a very hard task to create XSLT or XQuery
transformations that take arbitrary RDF/XML as input. Instead, we can imagine
that lowering schema mappings (for RDF-based semantic models) will use RDF
query languages either to construct the final XML, or to construct a stricter
form of XML that can then be input to XSLT or XQuery to produce the final XML
structure. In our examples, we combine SPARQL to query the RDF data and
produce an XML table of variable bindings, and XSLT that transforms this XML
table into the required XML.</p>

<p>To conclude, if we use RDF as the base for our semantic model, we can easily
use XML transformation technologies like XSLT or XQuery for lifting schema
mappings, but for lowering schema mappings we use the XML
technologies combined with an RDF query language like SPARQL to preprocess
the RDF data.</p>


<p>In the following we present an XML file that captures the information
necessary to perform the mapping from an RDF graph to XML data required
by the Web service. The <em>lowering</em> element in this file contains
two child elements. The first element <em>sparqlQuery</em> includes a SPARQL query to extract
the data in form of a variable binding table; the second element is the root element
of an XSLT transformation.</p>

<pre>&lt;lowering&gt;
  &lt;sparqlQuery&gt;
    PREFIX po: &lt;http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#&gt;
    SELECT ?qty ?UPC ?CustomerNo
    WHERE {
      ?order po:hasCustomer ?customer .
        ?customer po:hasCustomerID ?id .
          ?id po:hasLexicalRespresentation ?CustomerNo .
      ?order po:hasLineItems ?item .
        ?item po:hasQuantity ?qtyClass .
          ?qtyClass po:hasAmount ?qty .
        ?item po:hasProduct ?product .
          ?product po:hasProductCode ?code .
            ?code po:hasLexicalRespresentation ?UPC }
  &lt;/sparqlQuery&gt;
  &lt;xsl:transform version="2.0"
    xmlns:po="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:sp="http://www.w3.org/2005/sparql-results#"&gt;
    &lt;xsl:output method="xml" version="1.0" encoding="iso-8859-1" indent="yes" /&gt;
    &lt;xsl:template match="/sp:sparql"&gt;
      &lt;po:OrderRequest&gt;
        &lt;po:customerNo&gt;
          &lt;xsl:value-of
            select="sp:results/sp:result[position()=1]/sp:binding[@name='CustomerNo']/sp:literal" /&gt;
        &lt;/po:customerNo&gt;
        &lt;xsl:apply-templates select="sp:results/sp:result" /&gt;
      &lt;/po:OrderRequest&gt;
    &lt;/xsl:template&gt;
    &lt;xsl:template match="sp:result"&gt;
      &lt;po:orderItem&gt;
        &lt;xsl:attribute name="quantity"&gt;
          &lt;xsl:value-of select="sp:binding[@name='qty']/sp:literal" /&gt;
        &lt;/xsl:attribute&gt;
        &lt;po:UPC&gt;
          &lt;xsl:value-of select="sp:binding[@name='UPC']/sp:literal" /&gt;
        &lt;/po:UPC&gt;
      &lt;/po:orderItem&gt;
    &lt;/xsl:template&gt;
  &lt;/xsl:transform&gt;
&lt;/lowering&gt;</pre>

<p>We assume that some agent has semantic data as an RDF graph that is
intended to be used for a Web service invocation. Such data could look like
in the listing below, which shows an instance of the OrderRequest concept
according to the purchase order ontology introduced earlier.</p>

<pre>&lt;!DOCTYPE rdf:RDF[
    &lt;!ENTITY xs  "http://www.w3.org/2001/XMLSchema#" &gt;
]&gt; &lt;rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  xmlns:owl="http://www.w3.org/2002/07/owl#"
  xmlns="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#"
  xml:base="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#"&gt;
  &lt;owl:Ontology /&gt;
  &lt;OrderRequest&gt;
    &lt;hasLineItems&gt;
      &lt;LineItem&gt;
        &lt;hasProduct&gt;
          &lt;Product&gt;
            &lt;hasProductCode&gt;
              &lt;UPCCode&gt;
                &lt;hasLexicalRespresentation&gt;348290187318&lt;/hasLexicalRespresentation&gt;
              &lt;/UPCCode&gt;
            &lt;/hasProductCode&gt;
          &lt;/Product&gt;
        &lt;/hasProduct&gt;
        &lt;hasQuantity rdf:datatype="&amp;xs;float"&gt;12&lt;/hasQuantity&gt;
      &lt;/LineItem&gt;
    &lt;/hasLineItems&gt;
    &lt;hasLineItems&gt;
      &lt;LineItem&gt;
        &lt;hasProduct&gt;
          &lt;Product&gt;
            &lt;hasProductCode&gt;
              &lt;UPCCode&gt;
                &lt;hasLexicalRespresentation&gt;998212387318&lt;/hasLexicalRespresentation&gt;
              &lt;/UPCCode&gt;
            &lt;/hasProductCode&gt;
          &lt;/Product&gt;
        &lt;/hasProduct&gt;
        &lt;hasQuantity&gt;
          &lt;Quantity&gt;
            &lt;hasAmount rdf:datatype="&amp;xs;float"&gt;4&lt;/hasAmount&gt;
            &lt;hasUnit rdf:resource="#Piece"/&gt;
          &lt;/Quantity&gt;
        &lt;/hasQuantity&gt;
      &lt;/LineItem&gt;
    &lt;/hasLineItems&gt;
    &lt;hasCustomer&gt;
      &lt;Customer&gt;
        &lt;hasCustomerID&gt;
          &lt;CustomerID&gt;
            &lt;hasLexicalRespresentation&gt;007&lt;/hasLexicalRespresentation&gt;
          &lt;/CustomerID&gt;
        &lt;/hasCustomerID&gt;
      &lt;/Customer&gt;
    &lt;/hasCustomer&gt;
  &lt;/OrderRequest&gt;
&lt;/rdf:RDF&gt;</pre>

<p>When the SPARQL is applied to the RDF graph above, the following XML will be generated
as query answer.</p>

<pre>
&lt;sparql
xmlns="http://www.w3.org/2005/sparql-results#"&gt;
  &lt;head&gt;
    &lt;variable name="qty" /&gt;
    &lt;variable name="UPC" /&gt;
    &lt;variable name="CustomerNo" /&gt;
  &lt;/head&gt;
  &lt;results&gt;
    &lt;result&gt;
      &lt;binding name="qty"&gt;
        &lt;literal&gt;12&lt;/literal&gt;
      &lt;/binding&gt;
      &lt;binding name="UPC"&gt;
        &lt;literal&gt;348290187318&lt;/literal&gt;
      &lt;/binding&gt;
      &lt;binding name="CustomerNo"&gt;
        &lt;literal&gt;007&lt;/literal&gt;
      &lt;/binding&gt;
    &lt;/result&gt;
    &lt;result&gt;
      &lt;binding name="qty"&gt;
        &lt;literal&gt;4&lt;/literal&gt;
      &lt;/binding&gt;
      &lt;binding name="UPC"&gt;
        &lt;literal&gt;998212387318&lt;/literal&gt;
      &lt;/binding&gt;
      &lt;binding name="CustomerNo"&gt;
        &lt;literal&gt;007&lt;/literal&gt;
      &lt;/binding&gt;
    &lt;/result&gt;
  &lt;/results&gt;
&lt;/sparql&gt;</pre>

<p>When the XSLT is applied to the output of the SPARQL query,
the following XML data is generated. This data corresponds to the element
that has been annotated with the <em>loweringSchemaMapping</em> and can be used by some
agent to invoke the purchase order Web service.</p>

<pre>
&lt;ex:OrderRequest
xmlns:POOntology="http://example.org/ontologies/purchaseorder#"
  xmlns:sp="http://www.w3.org/2005/sparql-results#"
  xmlns:po="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns:ex="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order# ../wsdl/SchemaOnly.xsd "&gt;
  &lt;ex:customerNo&gt;007&lt;/ex:customerNo&gt;
  &lt;ex:orderItem quantity="12"&gt;
    &lt;ex:UPC&gt;348290187318&lt;/ex:UPC&gt;
  &lt;/ex:orderItem&gt;
  &lt;ex:orderItem quantity="4"&gt;
    &lt;ex:UPC&gt;998212387318&lt;/ex:UPC&gt;
  &lt;/ex:orderItem&gt;
&lt;/ex:OrderRequest&gt;
</pre>

<h3 id="lowering">A.2 Specifying Lifting Schema Mapping</h3>


<p>Our examples show lifting schema mappings using XSLT and XQuery, either one
will take the XML data (e.g. coming from the Web service) and produce RDF
data in the RDF/XML syntax. This is rather straightforward.
The mapping specification that is referenced using a <em>liftingSchemaMapping</em>
takes as input XML data and produces semantic data as output.
Within the purchase order example we have annotated the response
type, i.e. <em>OrderResponse</em>. The XML data corresponding to
the type can be transformed using XSLT or XQuery in order to obtain
data processable by a semantic agent.</p>


<p>A possible response of the purchase order Web service is the
following XML data.</p>

<pre>
&lt;OrderResponse
  xmlns="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  &gt;Confirmed&lt;/OrderResponse&gt;
</pre>

<p>The XSLT specification below describes how to convert the XML data
to an RDF graph corresponding to the purchase ontology.</p>

<pre>&lt;xsl:transform version="2.0"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  xmlns:po="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns:POOntology="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#"&gt;
  &lt;xsl:output method="xml" version="1.0" encoding="iso-8859-1" indent="yes" /&gt;
  &lt;xsl:template match="/"&gt;
    &lt;rdf:RDF&gt;
      &lt;POOntology:OrderConfirmation&gt;
        &lt;hasStatus rdf:datatype="http://www.w3.org/2001/XMLSchema#string"&gt;
          &lt;xsl:value-of select="po:OrderResponse" /&gt;
        &lt;/hasStatus&gt;
      &lt;/POOntology:OrderConfirmation&gt;
    &lt;/rdf:RDF&gt;
  &lt;/xsl:template&gt;
&lt;/xsl:transform&gt;
</pre>

<p>When the above XSLT sample is applied to the example response the following RDF instance
will be produced as output.</p>

<pre>&lt;rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
         xmlns:po="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
         xmlns:POOntology="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#"&gt;
   &lt;POOntology:OrderConfirmation&gt;
      &lt;hasStatus rdf:datatype="http://www.w3.org/2001/XMLSchema#string"&gt;Confirmed&lt;/hasStatus&gt;
   &lt;/POOntology:OrderConfirmation&gt;
&lt;/rdf:RDF&gt;
</pre>

<p>Equally the mapping can be specified by using XQuery. If both mappings are
present, a processor can choose the one it is designed to interpret.</p>

<pre>
xquery version "1.0";
declare namespace po="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#" ;
declare namespace rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#";
declare namespace owl="http://www.w3.org/2002/07/owl#" ;
&lt;rdf:RDF&gt;
  &lt;po:OrderConfirmation&gt;
    &lt;po:hasStatus rdf:datatype="http://www.w3.org/2001/XMLSchema#string"&gt;{ fn:string(/) }&lt;/po:hasStatus&gt;
  &lt;/po:OrderConfirmation&gt;
&lt;/rdf:RDF&gt;
</pre>


<h2 id="Categorization">B. Categorization Examples (Non-Normative)</h2>
<p>One purpose for annotating services at the interface level is to help enable
dynamic discovery. This is possible when services are published, catalogued and
annotated with semantics. The <em>modelReference</em> mechanism adds categorization
information to interfaces which could be used while publishing services in
registries such as UDDI [<a href="#UDDI">UDDI</a>]. Users can choose any categorization of their choice,
such as NAICS [<a href="#NAICS">NAICS</a>], UNSPSC [<a href="#UNSPSC">UNSPSC</a>]
and GICS [<a href="#GICS">GICS</a>]. This aids in service discovery by narrowing
the range of candidate services. The categorization can be used as input when
the service is published in a UDDI registry since taxonomies supported by UDDI can be specified via a
semantic model. </p>

<p>Service categorization is also aimed at supporting specialized taxonomies of
middleware or utility services such as mediators. The categorization <em>modelReference</em> is used to ensure
that there is basic and high-level categorization information about a service.</p>

<p>In this example, the interface categorization <em>modelReference</em> from
<a href="#annotateWSDLInterfaces">Section 3.1</a> points to an RDF instance
that gives two pieces of information: the taxonomy value (category code) of
the category and the URI of the taxonomy.</p>

<pre>&lt;rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
     xmlns:if="http://www.w3.org/2002/ws/sawsdl/spec/ontology/interface#"&gt;
  &lt;if:Category rdf:about="http://example.org/categorization/products/electronics"
    if:hasValue="443112"
    if:usesTaxonomy="http://naics.com/"/&gt;
&lt;/rdf:RDF&gt;</pre>

<p>This instance data derives from the following simple example model.</p>
<pre>
&lt;rdf:RDF&gt;
  &lt;rdfs:Class rdf:about="http://www.w3.org/2002/ws/sawsdl/spec/ontology/interface#Category"/&gt;
  &lt;rdf:Property rdf:about="http://www.w3.org/2002/ws/sawsdl/spec/ontology/interface#hasValue"&gt;
    &lt;rdfs:domain rdf:resource="http://www.w3.org/2002/ws/sawsdl/spec/ontology/interface#Category"/&gt;
    &lt;rdfs:range rdf:resource="http://www.w3.org/2000/01/rdf-schema#Literal"/&gt;
  &lt;/rdf:Property&gt;
  &lt;rdf:Property rdf:about="http://www.w3.org/2002/ws/sawsdl/spec/ontology/interface#usesTaxonomy"&gt;
    &lt;rdfs:domain rdf:resource="http://www.w3.org/2002/ws/sawsdl/spec/ontology/interface#Category"/&gt;
    &lt;rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#anyUri"/&gt;
  &lt;/rdf:Property&gt;
&lt;/rdf:RDF&gt;
</pre>

<p>Using this simple model, it is possible to create categorizations
using the registered taxonomies in UDDI. This information can then be
reused when the service is published in the UDDI registry. In the
following example we use the NAICS taxonomy identifier registered in UDDI, as
opposed to identifying the taxonomy with the URI of the NAICS Association Web
site, as shown above.</p>

<pre>&lt;rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
     xmlns:if="http://www.w3.org/2002/ws/sawsdl/spec/ontology/interface#"&gt;
  &lt;if:Category rdf:about="http://example.org/categorization/products/electronics"
    if:hasValue="443112"
    if:usesTaxonomy="uddi:uddi.org:ubr:categorization:naics:2002"/&gt;
&lt;/rdf:RDF&gt;</pre>

<p>When publishing in UDDI V3, the category bag created to classify the service would be built from this information.  This is the UDDI
<em>categoryBag</em> structure that would derive from this categorization.</p>

<pre>
&lt;categoryBag&gt;
         &lt;keyedReference
         tModelKey="uddi:uddi.org:ubr:categorization:naics:2002"
         keyName="Electronics"
         keyValue="443112"/&gt;
&lt;/categoryBag&gt;
</pre>
<p>The other UDDI taxonomies would also be referenced via their registered URIs.</p>


<h2 id="sawsdlxsd">C. XML Schema for Semantic Annotations for WSDL  and XML Schema</h2>

<p>The SAWSDL schema is also available as a separate file at <a href="sawsdl.xsd">sawsdl.xsd</a>.</p>

<pre>
&lt;xs:schema
  targetNamespace="http://www.w3.org/ns/sawsdl"
  xmlns="http://www.w3.org/ns/sawsdl"
  xmlns:xs="http://www.w3.org/2001/XMLSchema"
  xmlns:wsdl="http://www.w3.org/ns/wsdl"&gt;

  &lt;xs:simpleType name="listOfAnyURI"&gt;
    &lt;xs:list itemType="xs:anyURI"/&gt;
  &lt;/xs:simpleType&gt;

  &lt;xs:attribute name="modelReference" type="listOfAnyURI" /&gt;
  &lt;xs:attribute name="liftingSchemaMapping" type="listOfAnyURI" /&gt;
  &lt;xs:attribute name="loweringSchemaMapping" type="listOfAnyURI" /&gt;

  &lt;xs:element name="attrExtensions"&gt;
    &lt;xs:complexType&gt;
      &lt;xs:annotation&gt;
        &lt;xs:documentation&gt;This element is for use in WSDL 1.1 only. It does not apply to WSDL 2.0 documents.  Use in
        WSDL 2.0 documents is invalid.&lt;/xs:documentation&gt;
      &lt;/xs:annotation&gt;
      &lt;xs:anyAttribute namespace="##any" processContents="lax" /&gt;
    &lt;/xs:complexType&gt;
  &lt;/xs:element&gt;
&lt;/xs:schema&gt;
</pre>


<h2 id="Acknowledgements">D. Acknowledgements (Non-Normative)</h2>

<p>This document is the work of the <a
  href="http://www.w3.org/2002/ws/sawsdl/">W3C Semantic Annotations for Web
Service Description Language Working Group</a>.</p>

<p>Members of the Working Group are (at the time of writing, and in
alphabetical order): Rama Akkiraju (IBM Corporation), Carine Bournez (W3C), J.B.
Domingue (The Open University), Joel Farrell (IBM Corporation), Laura Ferrari (Telecom Italia SpA), Laurent Henocque
(ILOG, S.A.), Mathias Kleiner (ILOG, S.A.), Jacek Kopeck&yacute; (DERI Innsbruck
at the Leopold-Franzens-Universit&auml;t Innsbruck, Austria), Holger Lausen
(DERI Innsbruck at the Leopold-Franzens-Universit&auml;t Innsbruck, Austria), Peter Matthews (CA), Antony Miguel (Scapa Technologies Limited), John Miller
(University of Georgia Research Foundation, Inc (UGARF))
Carlos Pedrinaci (The Open University),
Eric Prud'hommeaux (W3C), Brahmananda Sapkota (DERI Galway at the National
University of Ireland, Galway, Ireland), Amit Sheth (Wright State University), Claudio Venezia (Telecom Italia SpA),
Tomas Vitvar (DERI Galway at the National University of Ireland, Galway, Ireland).</p>


</body>
</html>