NOTE-rdf-uml-19980804
16.7 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
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<META NAME="GENERATOR" CONTENT="Adobe PageMill 3.0 Win">
<TITLE>A Discussion of the Relationship Between RDF-Schema
and UML</TITLE>
<LINK rel="STYLESHEET" href="http://www.w3.org/StyleSheets/TR/NOTE.css" type="text/css">
</HEAD>
<BODY>
<H4 align=right>
<a href="http://www.w3.org/"><img src="http://www.w3.org/Icons/w3c_home" alt="W3C" border="0" align="left"></a>
NOTE-rdf-uml-19980804
</h4>
<H1 class="maintitle" align="center" STYLE="text-align: center">
A Discussion of the Relationship Between RDF-Schema and UML
</H1>
<p align=center STYLE="text-align: center">
<strong>W3C Note 04-Aug-1998</strong>
</p>
<center><a href="/1998/.status/NOTE-rdf-uml-19980804/status"><img src="/1998/.status/NOTE-rdf-uml-19980804/statusimg" border=0 alt="Status of this Document"></a></center>
<div class="intro">
<dl>
<dt>This document:
<dd>
<A HREF="http://www.w3.org/TR/1998/NOTE-rdf-uml-19980804/">http://www.w3.org/TR/1998/NOTE-rdf-uml-19980804</A>
<dt>Author:
<dd><a href="mailto:wchang@adobe.com">Walter W. Chang</a>, Advanced Technology Group, Adobe Systems
</dl>
<H2>Status of This Document</H2>
<p>This document is a
<a href="http://www.w3.org/Consortium/Process/#Notes">NOTE</a> made
available by W3C for discussion only. This indicates no endorsement of
its content, nor that W3C has had any editorial control in its
preparation, nor that W3C has, is, or will be allocating any resources
to the issues addressed by the NOTE.</p>
<P>Comments may be sent to
<A HREF="mailto:www-rdf-comments@w3.org">www-rdf-comments@w3.org</A>.
All mail is
<A HREF="http://lists.w3.org/Archives/Public/www-rdf-comments/">archived</a>
and available for review.</p>
</div>
<hr>
<h2>Introduction</h2>
<P>This note summarizes the relationship between RDF-Schema and
UML, the generic industry standard object-oriented modeling framework
for information systems modeling. This note will briefly describe
these systems then relate them to each other.</P>
<H2>RDF-Schema</H2>
<P>RDF-Schema specifies information about classes in a schema,
including properties (attributes) and relationships between classes.
RDF-Schema provides a typing system: informally, it is a basic
set of nodes and relations that can be used to express properties
of classes of the schema. RDF-Schema includes a facility to indicate
that certain classes are subclasses of others, and provides a
small number of basic classes. Finally, it contains a facility
for specifying a small number of constraints such as the cardinality
(number of occurrences) required and permitted of properties of
instances of classes.</P>
<P>"RDF-Schemas are specified using a declarative representation
language influenced by ideas from knowledge representation, e.g.,
semantic nets, frames, and predicate logic, as well as database
schema representation models such as binary relational models
([NIAM], etc.) and graph data models. The RDF schema specification
language is less expressive, but simpler, than full predicate
calculus languages such as CycL [CycL] and KIF [KIF]."</P>
<H2>UML</H2>
<P>The Unified Modeling Language (UML) is a framework for describing
a set of models that capture the functional and structural semantics
of any complex information system. UML defines the following models
for representing such systems:</P>
<P>1. A use case model that states the requirements of the user<BR>
2. A class model that captures the static information structure
of objects<BR>
3. A state model that describes the dynamic behavior of objects
<BR>
4. An activity implementation model that describes work unit actions<BR>
5. An interaction model that models scenarios and message flows<BR>
6. A deployment model that describes how software subsystems are
allocated<BR>
to actual hardware components</P>
<H2>How RDF and UML Relate to Each Other</H2>
<P>Web-based and non-Web based applications can be described by
a number of schema specification mechanisms, including RDF-Schema.
The RDF-Schema model itself is equivalent to a subset of the class
model in UML. RDF-Schema uses a DLG (Directed Labeled Graph) model
for describing schemas.</P>
<P>Class schemas expressed in UML can be viewed also as DLGs.
If a DLG is used for a class model schema in UML, the RDF-Schema
DLG can be shown to be isomorphic to a subgraph of the UML class
schema DLG. This is possible because RDF-Schema elements map directly
into UML class model elements.</P>
<P>In addition, the DAG formed by considering RDF-Schema subClassOf
class inheritance structures maps directly to UML class generalization
DAGs, RDF class properties map to UML class attributes, and RDF
properties and property cardinality constraints map to UML associations
and association <BR>
constraints.</P>
<P>The various constructs and elements in the class models of
UML (#2.) and RDF-Schema readily map between each other. While
currently the RDF-Schema work does not have counterparts to the
other 5 remaining UML modeling areas, RDF-Schema could be extended
to support these models as well.</P>
<P>Given that an application schema can be described by RDF-Schema
(or UML), how do RDF-Schema and UML actually relate to each other?
The remainder of this note describes the relationship between
the elements of the class models for RDF-Schema and UML. An outline
is presented below to show how a given schema represented by the
RDF-Schema model can be transformed into an equivalent UML class
schema representation.</P>
<P>Further, given any UML class schema representation, we can
specify an equivalent RDF-Schema representation.</P>
<H2>Comparison of Models</H2>
<P>Outlined below are the steps for showing that class schema
representations using RDF-Schema and the class model subset of
UML are equivalent.</P>
<P><CENTER><TABLE WIDTH="515" BORDER="1" CELLSPACING="2"
CELLPADDING="0">
<TR>
<TD WIDTH="25%" HEIGHT="25">
Step</TD>
<TD WIDTH="75%">
<P><CENTER> Description</CENTER></TD>
</TR>
<TR>
<TD HEIGHT="47">
1.</TD>
<TD>
Show that RDF-Schema and UML classes map between each other. </TD>
</TR>
<TR>
<TD HEIGHT="47">
1a.</TD>
<TD>
Show that single and multiple class inheritance constructs in
each system maps to the other. </TD>
</TR>
<TR>
<TD HEIGHT="68">
1b.</TD>
<TD>
Show that the class inheritance DAGs for RDF-Schema and UML (using
RDF-Schema subClassOf and UML subclass relationships respectively)
are isomorphic. </TD>
</TR>
<TR>
<TD HEIGHT="89">
1c.</TD>
<TD>
Note that RDF-Schema does not explicitly support the notion of
operations or methods, We ignore this for now. When RDF-Schema
supports this, map these methods into UML operations.</TD>
</TR>
<TR>
<TD HEIGHT="68">
2.</TD>
<TD>
Show that RDF-Schema properties and UML attributes can be directly
mapped between each other. Extensions can be added later to support
this if necessary. </TD>
</TR>
<TR>
<TD HEIGHT="47">
3.</TD>
<TD>
Show that any UML associations can be expressed as RDF-Schema
properties. </TD>
</TR>
<TR>
<TD HEIGHT="46">
3a.</TD>
<TD>
Show that UML multiplicity constraints on associations are equivalent
to a subset of RDF-Schema cardinality constraints</TD>
</TR>
<TR>
<TD HEIGHT="44">
3b.</TD>
<TD>
Show that property naming and reification in RDF-Schema maps
to UML association names and attributes. </TD>
</TR>
<TR>
<TD HEIGHT="84">
4.</TD>
<TD>
Show that while currently missing from RDF-Schema, a generalized
constraint model can be created by extending RDF-Schema using
reification allowing it to map into the general UML Class constraint
model. </TD>
</TR>
<TR>
<TD HEIGHT="84">
5.</TD>
<TD>
Having accomplished 1,2, and the portion of 3 relevant to the
RDF-Schema, we can then show that the full RDF-Schema DLG can
map into a proper subgraph of the UML class model DLG. </TD>
</TR>
</TABLE></CENTER>
<P><BR>
As noted, because UML contains additional modeling constructs
not found in RDF-Schema, full specification using UML may result
in a DLG model that is a superset of the model specified by RDF-Schema.
However, as indicated earlier, extensions to the RDF-Schema model
could be made to support these class model constructs as well
as other UML system models as needed by future application schemas
that use RDF-Schema.</P>
<H2>How RDF-Schema Properties and UML Roles Relate</H2>
<P>We note that RDF-Schema properties can correspond to UML roles,
and when a PropertyType actually names a range that is another
RDF-Schema class, one way this can be viewed is that the RDF-Schema
property is in fact being used as an association in the UML sense.
More precisely, an RDF-Schema property corresponds to a named
role within an unnamed association. UML has some facilities here
(such as naming associations and associating roles) that RDF-Schema
does not. [Layman,1]</P>
<P>[Wickstead] has presented several good examples of this in
the context of RDF-Schema WG discussions about non-Web resource
identifiers: he suggests that instead of introducing database
Primary/Foreign Keys, we let properties name actual classes. This
would cause the property to be used as an association to other
objects constrained by whatever cardinality constraint was specified.</P>
<H2>Conclusion</H2>
<P>A class of application schemas can be described by RDF-Schema.
RDF-Schema in turn can be shown to map into a subset of the UML
framework through inheritance schema DAG isomorphism and isomorphism
of RDF-Schema DLGs to a subgraph of UML full schema DLGs using
the procedure outlined above.</P>
<P>Thanks to Ron Daniels for his careful review of earlier draft
versions of this document and his comments and suggestions.</P>
<H2>Appendix 1</H2>
<H3>Summary of Schema Model Differences Between RDF-Schema and UML</H3>
<P>The table below summarizes how the two different schema modeling
systems support specific object constructs.</P>
<P><CENTER><TABLE WIDTH="450" BORDER="1" CELLSPACING="2"
CELLPADDING="0">
<TR>
<TD WIDTH="36%" HEIGHT="24">
Construct</TD>
<TD WIDTH="29%">
RDF-Schema</TD>
<TD WIDTH="35%">
UML</TD>
</TR>
<TR>
<TD HEIGHT="24">
Classes</TD>
<TD>
Y</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Members</TD>
<TD>
Properties</TD>
<TD>
Attributes</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Methods</TD>
<TD>
N</TD>
<TD>
Operations</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Generalization</TD>
<TD>
Y, S.I., M.I.</TD>
<TD>
Y, S.I., M.I.</TD>
</TR>
<TR>
<TD HEIGHT="44">
- Visibility of Attr/Meth.</TD>
<TD>
Public</TD>
<TD>
Public (1), Protected (2), and Private (3)</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Interfaces</TD>
<TD>
N</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Template Classes</TD>
<TD>
N</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Utility Classes</TD>
<TD>
N</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
Associations</TD>
<TD>
Y</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Assoc. Naming</TD>
<TD>
via Properties</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Role Naming</TD>
<TD>
via Properties</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Cardinality</TD>
<TD>
</TD>
<TD>
(6)</TD>
</TR>
<TR>
<TD HEIGHT="24">
- - - One</TD>
<TD>
ExactlyOne</TD>
<TD>
1</TD>
</TR>
<TR>
<TD HEIGHT="24">
- - - Zero or One</TD>
<TD>
ZeroOrMore</TD>
<TD>
0..1</TD>
</TR>
<TR>
<TD HEIGHT="24">
- - - From 0 to N</TD>
<TD>
ZeroOrMore</TD>
<TD>
0..N</TD>
</TR>
<TR>
<TD HEIGHT="24">
- - - From 1 to N</TD>
<TD>
OneOrMore</TD>
<TD>
1..N</TD>
</TR>
<TR>
<TD HEIGHT="24">
- - - From M to N</TD>
<TD>
No</TD>
<TD>
M..N</TD>
</TR>
<TR>
<TD HEIGHT="24">
- General Constraints</TD>
<TD>
N</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Association Classes</TD>
<TD>
N</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
- N-ary Associations</TD>
<TD>
reification</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
- Association Qualifiers</TD>
<TD>
N</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
Aggregation</TD>
<TD>
Y (4)</TD>
<TD>
Y</TD>
</TR>
<TR>
<TD HEIGHT="24">
Navigation</TD>
<TD>
Y</TD>
<TD>
Y (5)</TD>
</TR>
<TR>
<TD HEIGHT="24">
MetaModel</TD>
<TD>
Y</TD>
<TD>
Y (7)</TD>
</TR>
</TABLE></CENTER>
<H3>Table Notes:</H3>
<P>(1) Public - the element is visible to all clients of the class.<BR>
(2) Protected - the element is visible only to the subclass of
the class.<BR>
(3) Private - the element is visible to only the class itself.<BR>
(4) UML distinguishes between aggregation and composition: aggregation
is an abstract modeling, composition is a containment model
that can correspond to the RDF-Schema collection, bag, or
sequence constructs.<BR>
(5) RDF-Schema can use directed arcs, UML uses directed associations.<BR>
(6) RDF-Schema cardinality constraints are a subset of UML multiplicity
constraints. UML allows specification of multiplicity information
at
both ends of an association. RDF-Schema currently does not directly
support cardinality constraints besides the 4 listed. Supporting
arbitrary cardinalities e.g., 2-100 times would be useful, as
well as
intervals e.g., 3..5,17..23 would be useful. In the table, M and N
are integers > 1.<BR>
(7) While both RDF-Schema and UML have MetaModels, it is worth
pointing
out that the UML meta model is both substantially more elaborate
and
different than that of RDF-Schema meta model. [Layman,2]<BR>
(8) We note that the intended usages for RDF-Schema and UML may
differ.
While both systems can describe schemas, each system may be better
suited for a particular application. Eg., databases are described
by
schemas defining tables, views, referential integrity constraints,
and other database mechanisms; models of tree-structure grammars
such
as XML are described by schemas such as XML DTDs; models of entities
and relations are described in E-R schemas such as UML; models
of
nodes and arcs are described by node-and-arc schemas such as RDF
schemas. While there is substantial overlap between RDF and UML,
we anticipate that each will be used to describe somewhat different
entities. [Layman,2]</P>
<H2>References:</H2>
<P>[Rumbaugh et. al.] Jim Rumbaugh, Ivar Jacobson, and Grady Booch,
Unified
Modeling Language Reference Manual, ISBN: 0-201-30998-X, Addison
Wesley,
est. publication December 1997.</P>
<P>[RDF M+S] <A HREF="http://www.w3.org/TR/WD-rdf-syntax">Resource Description Framework, (RDF) Model and Syntax</A>,
W3C
Working Draft 16 Feb 1998, http://www.w3.org/TR/WD-rdf-syntax
,<BR>
Ora Lassila <<A HREF="mailto:ora.lassila@research.nokia.com">ora.lassila@research.nokia.com</A>>, Nokia Research
Center<BR>
Ralph R. Swick <<A HREF="mailto:swick@w3.org">swick@w3.org</A>>, World Wide Web Consortium
<BR>
et. al.</P>
<P>[RDF-Schema] <A HREF="http://www.w3.org/RDF/Group/WD-rdf-schema">Resource Description Framework, (RDF) Schemas</A>,
W3C Working
Draft 1 May 1998, http://www.w3.org/RDF/Group/WD-rdf-schema ,<BR>
Dan Brickley, University of Bristol, R.V. Guha, Netscape, Andrew
Layman, <BR>
Microsoft.</P>
<P>[UML-Tk] Hans-Erik Eriksson and Magnus Penker, "UML Toolkit",
John Wiley & <BR>
Sons, New York, 1997.</P>
<P>[IUML] Pierre-Alain Muller. "Instant UML", Wrox Press
Ltd., Birmingham, <BR>
UK, 1997. Original French Edition: "Modelisation objet avec
UML", <BR>
Editions Eyrolles, Paris France, 1997.</P>
<P>[NIAM] G. M. Nijssen and Terry Halpin, Conceptual Schema and
Relational <BR>
Database Design, (Prentice Hall, Sydney:1989)</P>
<P>[CycL] CycL: The CYC Representation Language; <BR>
<A HREF="http://www.cyc.com/tech.html#cycl">http://www.cyc.com/tech.html#cycl</A></P>
<P>[KIF] Knowledge Interchange Format (KIF); <BR>
<A HREF="http://logic.stanford.edu/kif/kif">http://logic.stanford.edu/kif/kif</A>.</P>
<P>[Wicksteed] Charles Wicksteed, Reuters.<BR>
<A HREF="/1998/08/NOTE-rdf-uml-19980804-references">Working Group mail archive</a>
(<a href="/Consortium/Prospectus/Joining">member only</a>)</p>
<P>[Layman], Andrew Layman. Microsoft Corporation.<BR>
<A HREF="/1998/08/NOTE-rdf-uml-19980804-references">Working Group mail archive</a>
(<a href="/Consortium/Prospectus/Joining">member only</a>)</p>
</BODY>
</HTML>