Compare commits
555 Commits
| Author | SHA1 | Date |
|---|---|---|
|
|
e83df07d5f | |
|
|
e79f81666b | |
|
|
893fa38908 | |
|
|
a4fa650471 | |
|
|
606976778e | |
|
|
8d7a3e4b5c | |
|
|
2a471e5b8c | |
|
|
42c648b596 | |
|
|
5a058a3ace | |
|
|
24e5822d7b | |
|
|
7147eaa5ed | |
|
|
62acb7337b | |
|
|
de056154bd | |
|
|
27d7821666 | |
|
|
16c1937aad | |
|
|
70929da1d0 | |
|
|
6115e12837 | |
|
|
d273b6a3ef | |
|
|
cd8c3629a1 | |
|
|
c8f805bdef | |
|
|
d80597d547 | |
|
|
09576db5ae | |
|
|
75cc871a10 | |
|
|
0967a91289 | |
|
|
0ba1798ac5 | |
|
|
bab25cbe35 | |
|
|
26c9f9d1e5 | |
|
|
e93b793bd6 | |
|
|
e27eeb4bc3 | |
|
|
867dec5d9c | |
|
|
1d03695f8e | |
|
|
8b39c4614f | |
|
|
7169d40228 | |
|
|
dc18c503e9 | |
|
|
c7d8648352 | |
|
|
aa15be7405 | |
|
|
1925d2f1c7 | |
|
|
08b8976076 | |
|
|
1b29f70460 | |
|
|
2f27948475 | |
|
|
7d9f665d07 | |
|
|
9ddf84129a | |
|
|
a4ab6f179a | |
|
|
fe2c0c3df1 | |
|
|
f3e945c646 | |
|
|
141c8a9353 | |
|
|
fc1b199daf | |
|
|
1e52483a86 | |
|
|
f1be5aaee8 | |
|
|
f7df826f53 | |
|
|
644d148455 | |
|
|
e51f53b25e | |
|
|
a29ba21580 | |
|
|
bca0ceae17 | |
|
|
71f74d3093 | |
|
|
1b4c97630d | |
|
|
477d5cc58a | |
|
|
e5bc6f1f8f | |
|
|
e2595350fd | |
|
|
8806b89cd8 | |
|
|
70a7580e2c | |
|
|
cb77d617e9 | |
|
|
13bb2d54bc | |
|
|
27baa4a6be | |
|
|
3eb6f8d034 | |
|
|
b5238b3bdc | |
|
|
0477f4b82d | |
|
|
5de652cfeb | |
|
|
0e69b7a40f | |
|
|
132f389bcf | |
|
|
7cc92e6fa2 | |
|
|
40b24774eb | |
|
|
021dc34d8e | |
|
|
5cd82f641e | |
|
|
ce3847a1e6 | |
|
|
40b5a687cc | |
|
|
c0b7962170 | |
|
|
d744535438 | |
|
|
160a7db3a7 | |
|
|
5e854d5667 | |
|
|
962ad5af72 | |
|
|
e307530d8e | |
|
|
6211164ca2 | |
|
|
37dc189a29 | |
|
|
d0ede46da8 | |
|
|
30a611ec91 | |
|
|
a72c88fb70 | |
|
|
09fab1724d | |
|
|
db1a918e16 | |
|
|
ff13af7ea6 | |
|
|
c4713960af | |
|
|
a0ed8a2672 | |
|
|
c4f32a5a74 | |
|
|
86574a7824 | |
|
|
4425596017 | |
|
|
1ec3be2f98 | |
|
|
105db10e1a | |
|
|
9f25167880 | |
|
|
23e7da7ca5 | |
|
|
49a3f570bf | |
|
|
93e69a4e24 | |
|
|
ee82a7fd20 | |
|
|
17ab5f89f2 | |
|
|
9039a0011b | |
|
|
6700c90fe2 | |
|
|
691cf7fe69 | |
|
|
e2d2529ce6 | |
|
|
0a37b4e98f | |
|
|
3c92579f87 | |
|
|
43517f2a6d | |
|
|
ee39c4bca8 | |
|
|
91157698e3 | |
|
|
d88df8470f | |
|
|
e5d0ce31d3 | |
|
|
0a8e4a2481 | |
|
|
0bf2c1e440 | |
|
|
76c7c6290c | |
|
|
786d98cd71 | |
|
|
abeb6c22e0 | |
|
|
b23a483c1e | |
|
|
f687058ca3 | |
|
|
cc22b016ef | |
|
|
ade4d6dfc6 | |
|
|
d76d42066a | |
|
|
7fc14a491e | |
|
|
da4d335f38 | |
|
|
de854f562b | |
|
|
fe9ac58af1 | |
|
|
a8b1f1ff46 | |
|
|
fa40aaf731 | |
|
|
d46829bb01 | |
|
|
ac69e12d7a | |
|
|
c1d994d650 | |
|
|
52d95c3cc3 | |
|
|
8d77597da5 | |
|
|
a463b627fb | |
|
|
3bdff0e55b | |
|
|
44a146c03d | |
|
|
41d93e14f6 | |
|
|
e58589e4c0 | |
|
|
6202d34fa6 | |
|
|
0435986b92 | |
|
|
bd246d364f | |
|
|
e8b54cfde9 | |
|
|
9240c4a012 | |
|
|
14fca5b59c | |
|
|
c67864269c | |
|
|
bf757a720a | |
|
|
c713061dca | |
|
|
22f95917f4 | |
|
|
ef20511703 | |
|
|
a54b9bfc40 | |
|
|
faedc3f0ff | |
|
|
f6e263028a | |
|
|
af5f800017 | |
|
|
7621aba4df | |
|
|
37cd34d38f | |
|
|
f517c8704e | |
|
|
22d63f06b4 | |
|
|
4fe531b9d0 | |
|
|
6bedd8a96b | |
|
|
93b9f60f0d | |
|
|
22bee0462c | |
|
|
cdcbba6b74 | |
|
|
6c630e04b6 | |
|
|
b91039f798 | |
|
|
0508d2e2e8 | |
|
|
72a7eef460 | |
|
|
a000667eac | |
|
|
841067cda1 | |
|
|
ce821892f2 | |
|
|
f309d89222 | |
|
|
381301b1e3 | |
|
|
897edbda76 | |
|
|
b8a974e20f | |
|
|
c3fe00bb0c | |
|
|
8d63c48637 | |
|
|
402d57a502 | |
|
|
8c637cf8d8 | |
|
|
49fb9100a2 | |
|
|
3a599f0be9 | |
|
|
c19d24b5db | |
|
|
24a435a751 | |
|
|
0fd6bc912a | |
|
|
ea8deeca54 | |
|
|
e92131fdca | |
|
|
5851e43722 | |
|
|
d5d31d7bc6 | |
|
|
76172b583f | |
|
|
eecc4076d5 | |
|
|
a9de3300c0 | |
|
|
caae7d949b | |
|
|
13ae4f5aea | |
|
|
4bfd0200fa | |
|
|
4af68f0d3a | |
|
|
e87bfa6d8a | |
|
|
87a3fc7df3 | |
|
|
6d701ce7a3 | |
|
|
f528f5c973 | |
|
|
d54d8bf7da | |
|
|
6fcc5df6ef | |
|
|
41b09d5e62 | |
|
|
72ec8f2f41 | |
|
|
3f8eb67d7b | |
|
|
eae2f33497 | |
|
|
e8fcbbf72c | |
|
|
6e9eea3f90 | |
|
|
a4136c20d5 | |
|
|
9cbc8dc9d2 | |
|
|
17efed7a0c | |
|
|
88440e18d8 | |
|
|
0c403eb9e2 | |
|
|
2a4c1a936e | |
|
|
d7384d7c0f | |
|
|
1ebaea9eb0 | |
|
|
233c924f18 | |
|
|
eca48d28d3 | |
|
|
b70d336608 | |
|
|
708035d5f2 | |
|
|
630779e815 | |
|
|
e82a26fa64 | |
|
|
da28a7e4ff | |
|
|
d69eda41a3 | |
|
|
be16a6b0ee | |
|
|
c3cba69d67 | |
|
|
767f30bcf9 | |
|
|
41d8a6b2e2 | |
|
|
75f8df20de | |
|
|
e591d58a40 | |
|
|
41b61d45e0 | |
|
|
569d6849cc | |
|
|
328901d184 | |
|
|
5c21f3a786 | |
|
|
a54a65cad8 | |
|
|
ad0b20256f | |
|
|
247bae4d13 | |
|
|
d7eeaf436f | |
|
|
1db49b4577 | |
|
|
aebaf73c38 | |
|
|
befd420ad4 | |
|
|
a105239cc6 | |
|
|
157929db94 | |
|
|
78f4617d08 | |
|
|
3cc69df466 | |
|
|
8e5ba0d321 | |
|
|
1091f88537 | |
|
|
51984abeb6 | |
|
|
47361a08e9 | |
|
|
94557ac9fc | |
|
|
e8608cd8f5 | |
|
|
67afa1ca2a | |
|
|
3bd60dfe7a | |
|
|
f9f3092669 | |
|
|
47b2933c5d | |
|
|
f15cf62d01 | |
|
|
a122641030 | |
|
|
797b0a53ce | |
|
|
6c972e907d | |
|
|
81dbd74afc | |
|
|
c756b2a6a7 | |
|
|
87c6cff453 | |
|
|
abc9282a65 | |
|
|
c7f21798b2 | |
|
|
b1a551bf7b | |
|
|
1c2bae7d96 | |
|
|
4d482a7efb | |
|
|
4369f5bf0b | |
|
|
ea6d967519 | |
|
|
0b726accbe | |
|
|
1427982399 | |
|
|
7ce9ce6914 | |
|
|
c648ec0592 | |
|
|
fdb21fdf95 | |
|
|
80cbbb19ee | |
|
|
fb8b4b734d | |
|
|
b7dc99292c | |
|
|
3f799fe638 | |
|
|
689fbb000e | |
|
|
0555769921 | |
|
|
42f1789dd6 | |
|
|
a934d72b48 | |
|
|
c607ed24ec | |
|
|
06f8a8c98e | |
|
|
e1f11e65d3 | |
|
|
7d56db2d84 | |
|
|
4527cb9de0 | |
|
|
2d8d15a997 | |
|
|
17de32cf49 | |
|
|
285b7902ae | |
|
|
39a280a00f | |
|
|
5da653bbf8 | |
|
|
d8f18b8206 | |
|
|
5c6cb00f32 | |
|
|
30d5235754 | |
|
|
3ee06c1f1c | |
|
|
14e65218ea | |
|
|
b92066039f | |
|
|
f74dbe01e7 | |
|
|
dfb6bb46da | |
|
|
c794b95d4a | |
|
|
7c5496dd99 | |
|
|
edae9bd593 | |
|
|
3f44db55e4 | |
|
|
c68afc038a | |
|
|
a0f8541ac3 | |
|
|
f602edc587 | |
|
|
00883b934b | |
|
|
3d83e5d00f | |
|
|
6901d69a6c | |
|
|
66b795f23b | |
|
|
8d570e7db7 | |
|
|
1ffa818d41 | |
|
|
47453b0991 | |
|
|
0de944164f | |
|
|
249c2633fb | |
|
|
747ffd0b16 | |
|
|
044f614ff9 | |
|
|
c8dec47886 | |
|
|
71f21d6b5c | |
|
|
c60483af35 | |
|
|
20212d97f5 | |
|
|
15b5b303bf | |
|
|
6e5dabef48 | |
|
|
d7700f1715 | |
|
|
c3d3578973 | |
|
|
c2a24c9d41 | |
|
|
e8da03aaf3 | |
|
|
0755e26ffa | |
|
|
4777ec26fd | |
|
|
3000c1920a | |
|
|
ca0b8c59c9 | |
|
|
7155db4e89 | |
|
|
2cf0987e50 | |
|
|
58b41eb627 | |
|
|
950ef99b7c | |
|
|
023d908578 | |
|
|
0af87dbf1d | |
|
|
015ae1b747 | |
|
|
b9325a7f93 | |
|
|
0a3d86a0d0 | |
|
|
96ce9aac63 | |
|
|
e9a1156d87 | |
|
|
84b14f46e7 | |
|
|
ac04f8c72e | |
|
|
02a6de35e2 | |
|
|
6b7f7acc6a | |
|
|
031efd5bdd | |
|
|
c1fcc32bfa | |
|
|
1ade012c50 | |
|
|
6839e3c683 | |
|
|
d852aea76f | |
|
|
9167c95fb8 | |
|
|
c5069700a1 | |
|
|
c410ab3fad | |
|
|
ff7869b7c7 | |
|
|
f58bb743d4 | |
|
|
3755188d07 | |
|
|
71dec862c5 | |
|
|
c8a8916a72 | |
|
|
2f726e3ea8 | |
|
|
3f1c98a328 | |
|
|
84a3c98d16 | |
|
|
19d2716782 | |
|
|
b7b323ced5 | |
|
|
421785ef7d | |
|
|
6660aa26b5 | |
|
|
14b4114e64 | |
|
|
05d4587169 | |
|
|
4b50d26adb | |
|
|
b026ce6bc8 | |
|
|
41ffcdafcf | |
|
|
4321bf772f | |
|
|
845d9fac0d | |
|
|
60d6271d6d | |
|
|
e6f904048d | |
|
|
9925eb997e | |
|
|
92fcfb1514 | |
|
|
d180a45fcc | |
|
|
6c120adba4 | |
|
|
79f73a06d2 | |
|
|
545613a15b | |
|
|
92d45a67d4 | |
|
|
b5837d2840 | |
|
|
14b80c0eab | |
|
|
afa290cca5 | |
|
|
84fa647445 | |
|
|
cbc51f5ed5 | |
|
|
0f3c2cf511 | |
|
|
10d62dabb8 | |
|
|
9545893fa0 | |
|
|
56e3b66325 | |
|
|
e63dfd9fa8 | |
|
|
1a066ccff8 | |
|
|
63dff2aaa3 | |
|
|
fb49bafe0f | |
|
|
015357b8c7 | |
|
|
61a4cdea18 | |
|
|
1f6fcc90c7 | |
|
|
37cfbf2043 | |
|
|
6704856194 | |
|
|
b467af9238 | |
|
|
d827bdf1f5 | |
|
|
6bbf7d2f71 | |
|
|
561b50c0f2 | |
|
|
f971bded86 | |
|
|
9bac4fb51a | |
|
|
0c41210872 | |
|
|
51a19f4be1 | |
|
|
20070fafaf | |
|
|
54796efd41 | |
|
|
14932ba5b2 | |
|
|
19989b3736 | |
|
|
73c2338bce | |
|
|
78bea1ee77 | |
|
|
8ad82c975c | |
|
|
74a9c16003 | |
|
|
a1f3f6ab6c | |
|
|
6e7f99ef8c | |
|
|
17779ac68b | |
|
|
bdfc02ae06 | |
|
|
72f918b68c | |
|
|
23fbf7ff19 | |
|
|
bdc1e297ae | |
|
|
b7a7c2335e | |
|
|
6f36d06dc8 | |
|
|
8e35628205 | |
|
|
44d645541a | |
|
|
96163568f4 | |
|
|
f6e22bc3d5 | |
|
|
f2e38d03e5 | |
|
|
9d6602d0f5 | |
|
|
3dc36ec498 | |
|
|
f7f0725667 | |
|
|
fd167e489e | |
|
|
287c34e3d7 | |
|
|
bca022de5b | |
|
|
14c71ffd5a | |
|
|
6fc777d81f | |
|
|
ea955c8b37 | |
|
|
2a7a49f4db | |
|
|
2053cb50eb | |
|
|
11575dfd31 | |
|
|
6a16efccf3 | |
|
|
fa56977424 | |
|
|
18604f7165 | |
|
|
d04ac049c7 | |
|
|
eacd052ed8 | |
|
|
3339c047f2 | |
|
|
bc42b5df48 | |
|
|
26a8c04d31 | |
|
|
8022cbf8de | |
|
|
7edade65bb | |
|
|
5423bea7eb | |
|
|
a96f721897 | |
|
|
43d02af81b | |
|
|
7ae5c25bc8 | |
|
|
ff15f13cfc | |
|
|
f5e2524b21 | |
|
|
1fd2c1e280 | |
|
|
a9b9b74fab | |
|
|
fd5cf48554 | |
|
|
9be890d3b8 | |
|
|
12821f9ed9 | |
|
|
611cfdcafe | |
|
|
17b83fe007 | |
|
|
b52565829e | |
|
|
67e7f42714 | |
|
|
3983568510 | |
|
|
182e9c96d8 | |
|
|
2ae9b91a43 | |
|
|
d61b4dfdff | |
|
|
f7928506a7 | |
|
|
aa7fefa899 | |
|
|
fe09e407d1 | |
|
|
daf9b854bc | |
|
|
5c849c2a3f | |
|
|
6230ff6762 | |
|
|
6ed807ff6b | |
|
|
6cccd702ed | |
|
|
d6c2a57086 | |
|
|
b8740e3567 | |
|
|
31c437888c | |
|
|
fa224fa492 | |
|
|
1a31306333 | |
|
|
c1ed3aa942 | |
|
|
8817329e49 | |
|
|
d8a465fc5d | |
|
|
4602a06841 | |
|
|
297772ac76 | |
|
|
b9e04f474a | |
|
|
cd90d5b402 | |
|
|
761320b44d | |
|
|
d23eab3432 | |
|
|
7234737f40 | |
|
|
c4a3b07ea2 | |
|
|
dceb851073 | |
|
|
b77d5a9eb6 | |
|
|
646a4d5280 | |
|
|
f94c2df2bc | |
|
|
a60f9fbabf | |
|
|
16c5db82b0 | |
|
|
625a6d3cb3 | |
|
|
4ad5a8ff64 | |
|
|
68a3ae6afa | |
|
|
ef951d4d7a | |
|
|
8869faf749 | |
|
|
27efa03869 | |
|
|
1bde5b9787 | |
|
|
69aef6380f | |
|
|
7d7a328406 | |
|
|
405b179f20 | |
|
|
bd53402181 | |
|
|
3700ff6322 | |
|
|
f05546d9b6 | |
|
|
87df86413a | |
|
|
143fef34f1 | |
|
|
7111a8e37b | |
|
|
4142c0ef11 | |
|
|
39048e6f0f | |
|
|
85e0a62c74 | |
|
|
6c1a02f67a | |
|
|
4d2ee647b6 | |
|
|
eb6a80e6a5 | |
|
|
567430483d | |
|
|
8f8024e767 | |
|
|
3581178a23 | |
|
|
0233e2630a | |
|
|
620440e472 | |
|
|
d8190eefb0 | |
|
|
956673ffb7 | |
|
|
7fe982d20e | |
|
|
f85f88c082 | |
|
|
8da7b8c669 | |
|
|
73fc215e2c | |
|
|
01a850bf2b | |
|
|
6cad56de7a | |
|
|
c62e0905e1 | |
|
|
72d03ede3a | |
|
|
7cd1549d58 | |
|
|
3eb795736f | |
|
|
865f1de24e | |
|
|
ed65bed552 | |
|
|
102634a819 | |
|
|
c9b7c3c3c8 | |
|
|
c239058b38 | |
|
|
9adce39cea | |
|
|
5e5f966a17 | |
|
|
4a8c116f58 | |
|
|
cfd67610ab | |
|
|
35ffe1e685 | |
|
|
3c3d5e14cb | |
|
|
ac7963f269 | |
|
|
c5d0bcecf8 | |
|
|
8d83db6ddc | |
|
|
eda1057e16 |
|
|
@ -0,0 +1,18 @@
|
|||
*.DS_Store
|
||||
*.iml
|
||||
*.ipr
|
||||
*.iws
|
||||
*.swp
|
||||
.idea
|
||||
.settings
|
||||
.project
|
||||
.classpath
|
||||
_vimrc
|
||||
build
|
||||
CHECKSUM.MD5
|
||||
javadoc
|
||||
lib
|
||||
TAGS
|
||||
target
|
||||
UMLGraph-R*
|
||||
UMLGraph-snapshot*
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
language: java
|
||||
|
||||
addons:
|
||||
apt:
|
||||
packages:
|
||||
- graphviz
|
||||
|
||||
install: ant
|
||||
|
||||
script: ant test
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
Copyright (c) 2002-2007, Diomidis Spinellis
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
* Neither the name of Diomidis Spinellis nor the names of its
|
||||
contributors may be used to endorse or promote products derived from
|
||||
this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
|
||||
TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
79
Makefile
|
|
@ -1,13 +1,9 @@
|
|||
#
|
||||
# $Id$
|
||||
#
|
||||
|
||||
VERSION=4.1
|
||||
TARBALL=UMLGraph-$(VERSION).tar.gz
|
||||
VERSION:=$(shell git describe --abbrev=6 HEAD | sed 's/R//;s/_/./;s/-/./;s/-.*$$/-SNAPSHOT/')
|
||||
BALL_TAR_GZ=UMLGraph-$(VERSION).tar.gz
|
||||
ZIPBALL=UMLGraph-$(VERSION).zip
|
||||
DISTDIR=UMLGraph-$(VERSION)
|
||||
WEBDIR=/dds/pubs/web/home/sw/umlgraph
|
||||
DOCLETSRCPATH=src/gr/spinellis/umlgraph/doclet
|
||||
WEBDIR=$(UH)/dds/pubs/web/home/umlgraph
|
||||
DOCLETSRCPATH=src/main/java/org/umlgraph/doclet
|
||||
DOCLETSRC= \
|
||||
$(DOCLETSRCPATH)/ClassGraph.java \
|
||||
$(DOCLETSRCPATH)/ClassInfo.java \
|
||||
|
|
@ -16,13 +12,18 @@ DOCLETSRC= \
|
|||
$(DOCLETSRCPATH)/UmlGraph.java \
|
||||
$(DOCLETSRCPATH)/Version.java
|
||||
TESTSRC = \
|
||||
src/gr/spinellis/umlgraph/test/DotDiff.java \
|
||||
src/gr/spinellis/umlgraph/test/BasicTest.java
|
||||
src/main/java/org/umlgraph/test/DotDiff.java \
|
||||
src/main/java/org/umlgraph/test/BasicTest.java
|
||||
PICFILE=sequence.pic
|
||||
README=README.txt
|
||||
OTHERSRC=index.html build.xml Makefile
|
||||
# Files to tag
|
||||
ALLTAG=$(DOCLETSRC) $(TESTSRC) $(PICFILE) $(README) $(OTHERSRC)
|
||||
LICENSE=LICENSE
|
||||
OTHERSRC=index.html build.xml Makefile oldversion.html
|
||||
# Documentation location (release)
|
||||
ifeq ($(VERSION),snapshot)
|
||||
DOC=snapshot-doc
|
||||
else
|
||||
DOC=doc
|
||||
endif
|
||||
|
||||
JARFILE=lib/UmlGraph.jar
|
||||
|
||||
|
|
@ -31,30 +32,31 @@ LF=perl -p -e 'BEGIN {binmode(STDOUT);} s/\r//'
|
|||
|
||||
all: $(JARFILE)
|
||||
|
||||
tarball: $(TARBALL)
|
||||
tarball: $(BALL_TAR_GZ)
|
||||
|
||||
src/gr/spinellis/umlgraph/doclet/Version.java: Makefile
|
||||
echo "/* Automatically generated file */" >$@
|
||||
echo "package gr.spinellis.umlgraph.doclet;" >>$@
|
||||
echo "class Version { public static String VERSION = \"$(VERSION)\";}" >>$@
|
||||
|
||||
$(TARBALL): $(JARFILE) docs Makefile
|
||||
$(BALL_TAR_GZ): $(JARFILE) docs Makefile
|
||||
-cmd /c rd /s/q $(DISTDIR)
|
||||
mkdir $(DISTDIR)
|
||||
mkdir $(DISTDIR)/doc
|
||||
mkdir $(DISTDIR)/lib
|
||||
mkdir $(DISTDIR)/bin
|
||||
$(LF) $(README) >$(DISTDIR)/$(README)
|
||||
$(LF) $(LICENSE) >$(DISTDIR)/$(LICENSE)
|
||||
$(LF) $(PICFILE) >$(DISTDIR)/lib/$(PICFILE)
|
||||
cp $(JARFILE) $(DISTDIR)/lib
|
||||
cp $(WEBDIR)/doc/* $(DISTDIR)/doc
|
||||
cp $(WEBDIR)/$(DOC)/* $(DISTDIR)/doc
|
||||
cp build.xml $(DISTDIR)
|
||||
tar cf - src testdata/{java,dot-ref} --exclude='*/RCS' | tar -C $(DISTDIR) -xvf -
|
||||
cp umlgraph.bat $(DISTDIR)/bin
|
||||
$(LF) umlgraph >$(DISTDIR)/bin/umlgraph
|
||||
tar cf - src testdata/{java,dot-ref} javadoc --exclude='*/CVS' | tar -C $(DISTDIR) -xvf -
|
||||
$(LF) $(PICFILE) >$(DISTDIR)/src/$(PICFILE)
|
||||
tar cvf - $(DISTDIR) | gzip -c >$(TARBALL)
|
||||
tar czf $(BALL_TAR_GZ) $(DISTDIR)
|
||||
zip -r $(ZIPBALL) $(DISTDIR)
|
||||
|
||||
docs:
|
||||
(cd doc && make)
|
||||
(cd $(UH)/dds/pubs/Courses/tools && make)
|
||||
(cd doc && make DOC=$(DOC))
|
||||
ant javadocs
|
||||
|
||||
$(JARFILE): $(DOCLETSRC)
|
||||
ant compile
|
||||
|
|
@ -62,13 +64,26 @@ $(JARFILE): $(DOCLETSRC)
|
|||
test:
|
||||
ant test
|
||||
|
||||
web: $(TARBALL) CHECKSUM.MD5
|
||||
cp $(TARBALL) $(ZIPBALL) CHECKSUM.MD5 $(WEBDIR)
|
||||
cp UmlGraph.jar $(WEBDIR)/jars/UmlGraph-$(VERSION).jar
|
||||
sed "s/VERSION/$(VERSION)/g" index.html >$(WEBDIR)/index.html
|
||||
testupdate:
|
||||
bash tools/testupdate.sh
|
||||
|
||||
CHECKSUM.MD5: $(TARBALL)
|
||||
md5 UMLGraph-2.10.* UMLGraph-$(VERSION).* UmlGraph.jar >CHECKSUM.MD5
|
||||
# Create only the static HTML pages
|
||||
static-web:
|
||||
(cd web && sh build.sh)
|
||||
cp web/build/* $(WEBDIR)
|
||||
sed "s/VERSION/$(VERSION)/g" web/build/download.html >$(WEBDIR)/download.html
|
||||
|
||||
tag:
|
||||
rcs -nV$(VERSION):
|
||||
web: $(BALL_TAR_GZ) CHECKSUM.MD5
|
||||
cp $(BALL_TAR_GZ) $(ZIPBALL) CHECKSUM.MD5 $(WEBDIR)
|
||||
(cd web && sh build.sh)
|
||||
cp web/build/* $(WEBDIR)
|
||||
sed "s/VERSION/$(VERSION)/g" web/build/download.html >$(WEBDIR)/download.html
|
||||
cp $(JARFILE) $(WEBDIR)/jars/UmlGraph-$(VERSION).jar
|
||||
tar cf - javadoc | tar -C $(WEBDIR) -xvf -
|
||||
|
||||
CHECKSUM.MD5: $(BALL_TAR_GZ) $(JARFILE)
|
||||
openssl md5 legacy/UMLGraph-2.10.* legacy/UMLGraph-4.8.* UMLGraph-$(VERSION).* >CHECKSUM.MD5
|
||||
(cd lib ; openssl md5 UmlGraph.jar) >>CHECKSUM.MD5
|
||||
|
||||
tags:
|
||||
etags **/*.java
|
||||
|
|
|
|||
|
|
@ -0,0 +1,69 @@
|
|||
# UMLGraph - Declarative Drawing of UML Diagrams
|
||||
|
||||
*UMLGraph* allows the declarative specification and drawing of UML diagrams.
|
||||
You can browse the system's documentation
|
||||
through [this link](http://www.spinellis.gr/umlgraph/doc/index.html),
|
||||
or print it through [this link](http://www.spinellis.gr/umlgraph/doc/indexw.html).
|
||||
|
||||
In order to run *UMLGraph*, you need to have [GraphViz](https://www.graphviz.org/)
|
||||
installed in your system path. On most Linux distributions, this can be easily
|
||||
installed using the regular package manager.
|
||||
|
||||
To compile the Java doclet from the source code run *ant* on the
|
||||
*build.xml* file.
|
||||
|
||||
If you change the source code, you can run regression tests by
|
||||
executing *ant test*.
|
||||
|
||||
Visit the project's [home page](http://www.spinellis.gr/umlgraph) for more information.
|
||||
|
||||
## Compatibility
|
||||
|
||||
If you build against Java 8, please use latest version of 5.X of the Doclet.
|
||||
|
||||
Since Java 9 doclet APIs where completely rewritten, the Doclet in version 6 supports only supports Java 9 and above.
|
||||
|
||||
## Development versions
|
||||
|
||||
In order to use development versions, you can use [JitPack](https://jitpack.io/#dspinellis/UMLGraph/master-SNAPSHOT).
|
||||
Note that as this is compiled on demand, you may sometimes see a "Read timed out" when the package is recompiled,
|
||||
and it should be fine a few seconds later. And because the master branch can change any time, you may want to use
|
||||
a versioned snapshot instead (see the Jitpack documentation for details).
|
||||
|
||||
**Gradle**:
|
||||
```
|
||||
repositories { maven { url 'https://jitpack.io' } }
|
||||
configurations { umlgraph }
|
||||
dependencies { umlgraph 'com.github.dspinellis:UMLGraph:master-SNAPSHOT' }
|
||||
javadoc {
|
||||
doclet = 'org.umlgraph.doclet.UmlGraphDoc'
|
||||
docletpath = configurations.umlgraph.files.asType(List)
|
||||
tags("hidden:X", "opt:X", "has:X", "navhas:X", "assoc:X", "navassoc:X",
|
||||
"composed:X", "navcomposed:X", "stereotype:X", "depend:X")
|
||||
}
|
||||
```
|
||||
|
||||
**Maven**:
|
||||
```
|
||||
<repositories>
|
||||
<repository>
|
||||
<id>jitpack.io</id>
|
||||
<url>https://jitpack.io</url>
|
||||
</repository>
|
||||
</repositories>
|
||||
...
|
||||
<dependency>
|
||||
<groupId>com.github.dspinellis</groupId>
|
||||
<artifactId>UMLGraph</artifactId>
|
||||
<version>master-SNAPSHOT</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
```
|
||||
|
||||
**Jar download**: <https://jitpack.io/com/github/dspinellis/UMLGraph/master-SNAPSHOT/UMLGraph-master-SNAPSHOT.jar>
|
||||
|
||||
## See also
|
||||
* [D2: Declarative Diagraming](https://d2lang.com/) (Emphasis on aesthetics and extensionability)
|
||||
* [Mermaid diagramming and charting tool](https://mermaid.js.org/) (JavaScript-based; easier syntax, good Markdown integration; interactive diagrams)
|
||||
* [PlantUML](https://plantuml.com/) (Java-based; supports IDEs and more diagram types)
|
||||
* [Comparison of textual diagraming systems](https://text-to-diagram.com/)
|
||||
22
README.txt
|
|
@ -1,22 +0,0 @@
|
|||
UMLGraph - Declarative Drawing of UML Diagrams
|
||||
|
||||
UMLGraph allows the declarative specification and drawing of
|
||||
UML class and sequence diagrams. You can browse the system's
|
||||
documentation from the doc/index.html page, or print it from
|
||||
doc/indexw.html.
|
||||
|
||||
To install the elements required to run UMLGraph, simply copy
|
||||
the contents of the lib directory to a location consistent with
|
||||
your installation's conventions (for example to /usr/local/lib).
|
||||
|
||||
To compile the Java doclet from the source code run ant on the
|
||||
build.xml file.
|
||||
|
||||
If you change the source code, you can run regression tests by
|
||||
executing "ant test".
|
||||
|
||||
Project home page: http://www.spinellis.gr/sw/umlgraph
|
||||
|
||||
Diomidis Spinellis - November 2005
|
||||
|
||||
$Id$
|
||||
|
|
@ -0,0 +1,41 @@
|
|||
http://stackoverflow.com/questions/8609546/umlgraph-not-automatic-integrated-in-javadoc
|
||||
|
||||
Support for all UML diagrams: state, use-case, etc.
|
||||
|
||||
State diagrams:
|
||||
See state-example.dot
|
||||
See also http://forrst.com/posts/State_Machine_Dont_abuse_the_if-1fE
|
||||
|
||||
Note that Hierarchically nested states cannot be shown in GraphViz,
|
||||
because you can't set shape and labels in cluster, nor can they act
|
||||
as edge targets.
|
||||
|
||||
Add in UmlGraphDoc support for showing package dependencies.
|
||||
See http://java.dzone.com/articles/reverse-engineer-source-code-u#comment-6124
|
||||
|
||||
Yves Bossel: If I may do some suggestions:
|
||||
+ Self-adjusting box size and placement on sequence diagrams would help (I use lots of inner classes whose names are long and descriptive).
|
||||
|
||||
Try the http://prefuse.sourceforge.net/ back end for large graphs.
|
||||
|
||||
Provide a parameter to say how (untagged) data members relate to other
|
||||
classes.
|
||||
The line can be a composition, an aggregation, or a navigable association.
|
||||
public class A {
|
||||
.....
|
||||
}
|
||||
|
||||
public class B {
|
||||
A myInstance;
|
||||
}
|
||||
Requires special care for containers and arrays.
|
||||
|
||||
command-line (and global) options for setting all graph attributes
|
||||
|
||||
Class options for setting edge attributes fillcolor fontcolor etc per edge
|
||||
|
||||
Use doclet error reporting functions
|
||||
|
||||
A class can specify its rank, or its cluster.
|
||||
|
||||
The dot edge routing is not the best possible for UML. Implement a rectangular routing strategy, maybe based on stochastic optimization using simulated annealing.
|
||||
265
build.xml
|
|
@ -1,17 +1,76 @@
|
|||
<project name="umlgraph" default="compile" basedir=".">
|
||||
<project name="umlgraph" default="compile" basedir="."
|
||||
xmlns:artifact="antlib:org.apache.maven.artifact.ant" >
|
||||
|
||||
<description>
|
||||
The specification for the Java-based umlgraph build processes.
|
||||
$Id$
|
||||
</description>
|
||||
|
||||
<!-- set global properties for this build -->
|
||||
<property name="src" location="src"/>
|
||||
<property name="src" location="src/main/java"/>
|
||||
<property name="testsrc" location="src/test"/>
|
||||
<property name="build" location="build"/>
|
||||
<property name="javadoc" location="javadoc"/>
|
||||
<property name="lib" location="lib"/>
|
||||
<property name="testsrc" location="test/src"/>
|
||||
<!-- import environment varibles -->
|
||||
<property name="testout" location="${basedir}/testdata/dot-out"/>
|
||||
<property name="testref" location="${basedir}/testdata/dot-ref"/>
|
||||
|
||||
<property name="dist" location="dist" />
|
||||
|
||||
<!-- obtain version from git; see http://techblog.41concepts.com/2009/05/08/generating-ant-build-numbers-using-subversion/ -->
|
||||
<macrodef name="gitversion" description="Get git version.">
|
||||
<attribute name="outputproperty"/>
|
||||
<sequential>
|
||||
<echo message="git rev-parse --short=6 => '@{outputproperty}'"/>
|
||||
<exec executable="git"
|
||||
failonerror="true"
|
||||
outputproperty="@{outputproperty}">
|
||||
<arg value="rev-parse"/>
|
||||
<arg value="--short=6"/>
|
||||
<arg value="HEAD"/>
|
||||
<redirector>
|
||||
<outputfilterchain>
|
||||
<tokenfilter>
|
||||
<replaceregex pattern="R" replace=""/>
|
||||
<replaceregex pattern="_" replace="."/>
|
||||
<replaceregex pattern="-" replace="."/>
|
||||
<replaceregex pattern="(-.*)$" replace="-SNAPSHOT"/>
|
||||
</tokenfilter>
|
||||
</outputfilterchain>
|
||||
</redirector>
|
||||
</exec>
|
||||
<echo message="gitversion returned '${@{outputproperty}}'"/>
|
||||
</sequential>
|
||||
</macrodef>
|
||||
|
||||
<!-- define Maven coordinates; see https://docs.sonatype.org/display/Repository/Sonatype+OSS+Maven+Repository+Usage+Guide#SonatypeOSSMavenRepositoryUsageGuide-7c.DeploySnapshotsandStageReleaseswithAnt -->
|
||||
<property name="groupId" value="org.umlgraph" />
|
||||
<property name="artifactId" value="UmlGraph" />
|
||||
<!-- <property name="version" value="1.0-SNAPSHOT" /> -->
|
||||
<gitversion outputproperty="version"/>
|
||||
|
||||
<!-- define artifacts' name, which follows the convention of Maven -->
|
||||
<property name="maven-jar" value="${dist}/lib/${artifactId}-${version}.jar" />
|
||||
<property name="maven-javadoc-jar" value="${dist}/lib/${artifactId}-${version}-javadoc.jar" />
|
||||
<property name="maven-sources-jar" value="${dist}/lib/${artifactId}-${version}-sources.jar" />
|
||||
|
||||
<!-- defined maven snapshots and staging repository id and url -->
|
||||
<!-- passwords are stored in \Users\Diomidis Spinellis\.m2\settings.xml -->
|
||||
<property name="maven-snapshots-repository-id" value="sonatype-nexus-snapshots" />
|
||||
<property name="maven-snapshots-repository-url" value="https://oss.sonatype.org/content/repositories/snapshots/" />
|
||||
<property name="maven-staging-repository-id" value="sonatype-nexus-staging" />
|
||||
<property name="maven-staging-repository-url" value="https://oss.sonatype.org/service/local/staging/deploy/maven2/" />
|
||||
|
||||
<!-- import environment variables -->
|
||||
<property environment="env"/>
|
||||
|
||||
<target name="clean">
|
||||
<delete dir="${build}"/>
|
||||
<delete dir="${lib}"/>
|
||||
<delete dir="testdata/dot-out"/>
|
||||
<delete dir="${javadoc}"/>
|
||||
<delete dir="${dist}/lib"/>
|
||||
</target>
|
||||
|
||||
<target name="init">
|
||||
<!-- Create the time stamp -->
|
||||
|
|
@ -20,23 +79,201 @@
|
|||
<mkdir dir="${build}"/>
|
||||
<mkdir dir="${lib}"/>
|
||||
<mkdir dir="testdata/dot-out"/>
|
||||
<mkdir dir="${javadoc}"/>
|
||||
<mkdir dir="${dist}/lib"/>
|
||||
</target>
|
||||
|
||||
<target name="compile" depends="init"
|
||||
<target name="version">
|
||||
<exec executable="git"
|
||||
outputproperty="VERSION">
|
||||
<arg value="rev-parse"/>
|
||||
<arg value="--short=6"/>
|
||||
<arg value="HEAD"/>
|
||||
</exec>
|
||||
<echo>Version is ${VERSION}</echo>
|
||||
<echo file="src/main/java/org/umlgraph/doclet/Version.java">/* Automatically generated file */
|
||||
package org.umlgraph.doclet;
|
||||
class Version { public static String VERSION = "${VERSION}";}
|
||||
</echo>
|
||||
</target>
|
||||
|
||||
<target name="compile" depends="init,version"
|
||||
description="compile the source, build library " >
|
||||
<javac srcdir="${src}" destdir="${build}" excludes="gr/spinellis/umlgraph/doclet/RCS/*,gr/spinellis/umlgraph/test/RCS/*"/>
|
||||
<jar basedir="${build}" destfile="${lib}/UmlGraph.jar" includes="gr/spinellis/umlgraph/doclet/*.class"/>
|
||||
<javac srcdir="${src}" destdir="${build}" debug="true"
|
||||
deprecation="true" includeantruntime="false" >
|
||||
<compilerarg value="-Xlint"/>
|
||||
<classpath>
|
||||
<pathelement location="${env.JAVA_HOME}/lib/tools.jar"/>
|
||||
</classpath>
|
||||
</javac>
|
||||
<jar basedir="${build}" destfile="${lib}/UmlGraph.jar" includes="org/umlgraph/doclet/*.class">
|
||||
<manifest>
|
||||
<attribute name="Main-Class" value="org.umlgraph.doclet.UmlGraph"/>
|
||||
<attribute name="Class-Path" value="tools.jar"/>
|
||||
</manifest>
|
||||
</jar>
|
||||
</target>
|
||||
|
||||
<target name="test" depends="compile"
|
||||
description="run the regression tests" >
|
||||
<java classname="gr.spinellis.umlgraph.test.BasicTest" fork="true">
|
||||
<target name="testcompile" depends="init"
|
||||
description="compile the test code " >
|
||||
<javac srcdir="${testsrc}" destdir="${build}" debug="true"
|
||||
deprecation="true" includeantruntime="false" >
|
||||
<classpath>
|
||||
<pathelement location="${env.JAVA_HOME}/lib/tools.jar"/>
|
||||
<pathelement location="${build}"/>
|
||||
<pathelement location="${lib}/UmlGraph.jar"/>
|
||||
<pathelement location="${env.JAVA_HOME}/lib/tools.jar"/>
|
||||
</classpath>
|
||||
</java>
|
||||
<compilerarg value="-Xlint"/>
|
||||
</javac>
|
||||
</target>
|
||||
|
||||
<target name="test" depends="compile,testcompile"
|
||||
description="run the regression tests" >
|
||||
<!-- postpone failures, so we get to see the pngs -->
|
||||
<java classname="org.umlgraph.test.BasicTest" fork="true" resultproperty="BasicTest.exit">
|
||||
<classpath>
|
||||
<pathelement location="${env.JAVA_HOME}/lib/tools.jar"/>
|
||||
<pathelement location="${build}"/>
|
||||
<pathelement location="${lib}/UmlGraph.jar"/>
|
||||
</classpath>
|
||||
</java>
|
||||
<java classname="org.umlgraph.test.UmlDocTest" fork="true" resultproperty="UmlDocTest.exit">
|
||||
<classpath>
|
||||
<pathelement location="${env.JAVA_HOME}/lib/tools.jar"/>
|
||||
<pathelement location="${build}"/>
|
||||
<pathelement location="${lib}/UmlGraph.jar"/>
|
||||
</classpath>
|
||||
</java>
|
||||
<apply executable="dot" dest="${testout}" parallel="false">
|
||||
<arg value="-Tpng"/>
|
||||
<arg value="-o"/>
|
||||
<targetfile/>
|
||||
<srcfile/>
|
||||
<fileset dir="${testout}" includes="*.dot"/>
|
||||
<mapper type="glob" from="*.dot" to="*.png"/>
|
||||
</apply>
|
||||
<apply executable="dot" dest="${testref}" parallel="false">
|
||||
<arg value="-Tpng"/>
|
||||
<arg value="-o"/>
|
||||
<targetfile/>
|
||||
<srcfile/>
|
||||
<fileset dir="${testref}" includes="*.dot"/>
|
||||
<mapper type="glob" from="*.dot" to="*.png"/>
|
||||
</apply>
|
||||
<!-- postponed failure, so we get to see the pngs -->
|
||||
<fail message="BasicTest failed">
|
||||
<condition><not><equals arg1="0" arg2="${BasicTest.exit}"/></not></condition>
|
||||
</fail>
|
||||
<fail message="UmlDocTest failed">
|
||||
<condition><not><equals arg1="0" arg2="${UmlDocTest.exit}"/></not></condition>
|
||||
</fail>
|
||||
</target>
|
||||
|
||||
<target name="javadocs" depends="compile">
|
||||
<javadoc sourcepath="${src}" packagenames="org.umlgraph.doclet.*" destdir="${javadoc}" private="true">
|
||||
<doclet name="org.umlgraph.doclet.UmlGraphDoc" path="${lib}/UmlGraph.jar">
|
||||
<param name="-inferrel"/>
|
||||
<param name="-inferdep"/>
|
||||
<param name="-autosize"/>
|
||||
<param name="-collapsible"/>
|
||||
<param name="-hide" value="java.*"/>
|
||||
<param name="-collpackages" value="java.util.*"/>
|
||||
<param name="-qualify"/>
|
||||
<param name="-postfixpackage"/>
|
||||
<param name="-nodefontsize" value="9"/>
|
||||
<param name="-nodefontpackagesize" value="7"/>
|
||||
<param name="-link" value="http://docs.oracle.com/javase/7/docs/jdk/api/javadoc/doclet/"/>
|
||||
<param name="-link" value="http://download.oracle.com/javase/7/docs/api/"/>
|
||||
</doclet>
|
||||
</javadoc>
|
||||
</target>
|
||||
|
||||
<target name="pom" description="generate the pom.xml file with the correct version">
|
||||
<copy file="pom.template.xml"
|
||||
tofile="pom.xml"
|
||||
filtering="yes" overwrite="yes">
|
||||
<filterchain>
|
||||
<filterreader classname="org.apache.tools.ant.filters.ExpandProperties"/>
|
||||
</filterchain>
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<target name="dist" depends="compile" description="generate the distribution">
|
||||
<!-- build the main artifact -->
|
||||
<jar jarfile="${maven-jar}" basedir="${build}" />
|
||||
|
||||
<!-- build the javadoc artifact -->
|
||||
<javadoc sourcepath="${src}" destdir="${dist}/javadoc" />
|
||||
<jar jarfile="${maven-javadoc-jar}">
|
||||
<fileset dir="${dist}/javadoc" />
|
||||
</jar>
|
||||
|
||||
<!-- build the sources artifact -->
|
||||
<jar jarfile="${maven-sources-jar}">
|
||||
<fileset dir="${src}" />
|
||||
</jar>
|
||||
</target>
|
||||
|
||||
<target name="deploy" depends="dist,pom" description="deploy snapshot version to Maven snapshot repository">
|
||||
<!-- for this to work install http://maven.apache.org/ant-tasks/download.html into ant/lib -->
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-deploy-plugin:2.6:deploy-file" />
|
||||
<arg value="-Durl=${maven-snapshots-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-snapshots-repository-id}" />
|
||||
<arg value="-DpomFile=pom.xml" />
|
||||
<arg value="-Dfile=${maven-jar}" />
|
||||
</artifact:mvn>
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-deploy-plugin:2.6:deploy-file" />
|
||||
<arg value="-Durl=${maven-snapshots-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-snapshots-repository-id}" />
|
||||
<arg value="-DpomFile=pom.xml" />
|
||||
<arg value="-Dfile=${maven-sources-jar}" />
|
||||
<arg value="-Dclassifier=sources" />
|
||||
</artifact:mvn>
|
||||
|
||||
<!-- sign and deploy the javadoc artifact -->
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-deploy-plugin:2.6:deploy-file" />
|
||||
<arg value="-Durl=${maven-snapshots-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-snapshots-repository-id}" />
|
||||
<arg value="-DpomFile=pom.xml" />
|
||||
<arg value="-Dfile=${maven-javadoc-jar}" />
|
||||
<arg value="-Dclassifier=javadoc" />
|
||||
</artifact:mvn>
|
||||
</target>
|
||||
|
||||
<!-- before this, update project version (both build.xml and pom.xml) from SNAPSHOT to RELEASE -->
|
||||
<target name="stage" depends="dist,pom" description="deploy release version to Maven staging repository">
|
||||
<!-- sign and deploy the main artifact -->
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-gpg-plugin:1.3:sign-and-deploy-file" />
|
||||
<arg value="-Durl=${maven-staging-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-staging-repository-id}" />
|
||||
<arg value="-DpomFile=pom.xml" />
|
||||
<arg value="-Dfile=${maven-jar}" />
|
||||
<arg value="-Pgpg" />
|
||||
</artifact:mvn>
|
||||
|
||||
<!-- sign and deploy the sources artifact -->
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-gpg-plugin:1.3:sign-and-deploy-file" />
|
||||
<arg value="-Durl=${maven-staging-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-staging-repository-id}" />
|
||||
<arg value="-DpomFile=pom.xml" />
|
||||
<arg value="-Dfile=${maven-sources-jar}" />
|
||||
<arg value="-Dclassifier=sources" />
|
||||
<arg value="-Pgpg" />
|
||||
</artifact:mvn>
|
||||
|
||||
<!-- sign and deploy the javadoc artifact -->
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-gpg-plugin:1.3:sign-and-deploy-file" />
|
||||
<arg value="-Durl=${maven-staging-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-staging-repository-id}" />
|
||||
<arg value="-DpomFile=pom.xml" />
|
||||
<arg value="-Dfile=${maven-javadoc-jar}" />
|
||||
<arg value="-Dclassifier=javadoc" />
|
||||
<arg value="-Pgpg" />
|
||||
</artifact:mvn>
|
||||
</target>
|
||||
|
||||
</project>
|
||||
|
|
|
|||
|
|
@ -0,0 +1,5 @@
|
|||
bib.xml
|
||||
fmtcache
|
||||
*.dot
|
||||
*.gif
|
||||
*.err
|
||||
|
|
@ -0,0 +1,80 @@
|
|||
# usage-example for the comment extensions to the
|
||||
# "Pic macros for drawing UML sequence diagrams"
|
||||
#
|
||||
# (C) Copyright 2005 Sebastian Setzer
|
||||
#
|
||||
# Permission to use, copy, and distribute this software and its
|
||||
# documentation for any purpose and without fee is hereby granted,
|
||||
# provided that the above copyright notice appear in all copies and that
|
||||
# both that copyright notice and this permission notice appear in
|
||||
# supporting documentation.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
|
||||
# WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
|
||||
# MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
|
||||
#
|
||||
#
|
||||
|
||||
.PS
|
||||
copy "sequence.pic";
|
||||
|
||||
# Define the objects
|
||||
actor(U, "");
|
||||
object(G,"g:GUI");
|
||||
placeholder_object(Dummy1); # more space
|
||||
placeholder_object(D);
|
||||
step();
|
||||
|
||||
# Message sequences
|
||||
active(G);
|
||||
step();
|
||||
|
||||
create_message(G,D,"db:DB");
|
||||
active(D);
|
||||
step();
|
||||
inactive(D);
|
||||
|
||||
async(); # use asynchrone messages (not-filled arrowheads)
|
||||
|
||||
comment(D,C,down 1 right, wid 1 ht 0.7 "waiting for" "condition" "dbMailbox")
|
||||
|
||||
message(U,G,"openBrowser");
|
||||
message(G,D,"query()"); active(D);
|
||||
message(D,G,"result"); inactive(D);
|
||||
|
||||
connect_to_comment(D,C)
|
||||
|
||||
message(U,G,"scroll");
|
||||
message(G,D,"query()"); active(D);
|
||||
message(D,G,"result"); inactive(D);
|
||||
|
||||
connect_to_comment(D,C)
|
||||
|
||||
message(U,G,"Exit");
|
||||
step();
|
||||
begin_frame(G,F,"OnExit");
|
||||
message(G,D,"shutdown()"); inactive(G); active(D);
|
||||
comment(G,C,down .2 right .2, wid 2 ht 0.25 "wait for cond. dbShutdown")
|
||||
step();
|
||||
comment(D,C,right, wid 2 ht 1 \
|
||||
"all queries preceeding the" \
|
||||
"shutdown in the mailbox" \
|
||||
"are answered already." \
|
||||
"DbQuery-Objects can" \
|
||||
"be destroyed")
|
||||
message(D,G,"done"); inactive(D); active(G);
|
||||
|
||||
sync();
|
||||
destroy_message(G,D,"");
|
||||
|
||||
step();
|
||||
end_frame(D,F);
|
||||
|
||||
step();
|
||||
inactive(G);
|
||||
|
||||
# Complete the lifelines
|
||||
step();
|
||||
complete(G);
|
||||
complete(U);
|
||||
.PE
|
||||
|
|
@ -0,0 +1,44 @@
|
|||
#
|
||||
#
|
||||
|
||||
ROOT=/cygdrive/c
|
||||
PIC2PLOT=pic2plot
|
||||
GS=gs
|
||||
DESTDIR=/dds/pubs/web/home/umlgraph
|
||||
NOTETOOLS=/dds/pubs/Courses/tools
|
||||
GIF := $(shell sed -n 's/.*<img *src *= *"\([^.]*\.gif\)".*/\1/p' *.xml)
|
||||
XML := $(wildcard *.xml)
|
||||
DOC?=snapshot-doc
|
||||
|
||||
.SUFFIXES:.java .dot .ps .gif .pic .eps .png
|
||||
|
||||
.java.dot:
|
||||
javadoc -docletpath ../lib/UmlGraph.jar -doclet org.umlgraph.doclet.UmlGraph -private $<
|
||||
mv graph.dot $@
|
||||
|
||||
.dot.eps:
|
||||
dot -Teps -o$@ $<
|
||||
|
||||
.dot.gif:
|
||||
dot -Tgif $< -o$@
|
||||
|
||||
.pic.eps:
|
||||
perl -p -e 'BEGIN {binmode(STDOUT);} s/\r//' $< | $(PIC2PLOT) -Teps >$@
|
||||
|
||||
# Could also use -Tgif, but going through Ghostscript produces a much better
|
||||
# anti-aliased image
|
||||
.pic.gif:
|
||||
perl -p -e 'BEGIN {binmode(STDOUT);} s/\r//' $< | \
|
||||
$(PIC2PLOT) -Tps | \
|
||||
$(GS) -q -r360 -dNOPAUSE -sDEVICE=pnm -sOutputFile=- - -c quit | \
|
||||
pnmcrop | \
|
||||
pnmscale 0.25 | \
|
||||
ppmtogif >$@
|
||||
|
||||
|
||||
all: sequence.pic $(GIF) $(XML)
|
||||
sh $(ROOT)/$(NOTETOOLS)/coursebib.sh bib
|
||||
echo "Drawing UML Diagrams with UMLGraph" | /c/Perl/bin/perl $(NOTETOOLS)/thread.pl -n -h html -r -p ../index.html index ${DESTDIR}/${DOC}
|
||||
|
||||
sequence.pic: ../sequence.pic
|
||||
perl -p -e 'BEGIN {binmode(STDOUT);} s/\r//' $< >$@
|
||||
|
After Width: | Height: | Size: 4.3 KiB |
|
|
@ -0,0 +1,42 @@
|
|||
// Author: Vadim Nasardinov
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @assoc "1..1" - "0..n" Adapter
|
||||
* @assoc "" - "0..n" ObjectType
|
||||
* @assoc "" - "0..n" ObjectMap
|
||||
* @assoc "" - "0..n" Table
|
||||
* @assoc "" - "0..n" DataOperation
|
||||
**/
|
||||
class Root {
|
||||
private Map m_adapters;
|
||||
private List m_types;
|
||||
private List m_maps;
|
||||
private List m_tables;
|
||||
private List m_ops;
|
||||
|
||||
public Adapter getAdapter(Class klass) {}
|
||||
}
|
||||
|
||||
class Adapter {
|
||||
public Root getRoot();
|
||||
}
|
||||
|
||||
abstract class Element {
|
||||
Root getRoot() {}
|
||||
}
|
||||
|
||||
class ObjectType extends Element {}
|
||||
|
||||
/**
|
||||
* @has "1..1" - "1..1" ObjectType
|
||||
**/
|
||||
class ObjectMap extends Element {
|
||||
private ObjectType m_type;
|
||||
}
|
||||
|
||||
class Table extends Element {}
|
||||
|
||||
class DataOperation extends Element {}
|
||||
|
After Width: | Height: | Size: 7.3 KiB |
|
|
@ -0,0 +1,66 @@
|
|||
// Author: Vadim Nasardinov
|
||||
// Author: Andrea Aime
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @assoc "1..1" - "0..n" Adapter
|
||||
* @assoc "" - "0..n" ObjectType
|
||||
* @assoc "" - "0..n" ObjectMap
|
||||
* @assoc "" - "0..n" Table
|
||||
* @assoc "" - "0..n" DataOperation
|
||||
**/
|
||||
class Root {
|
||||
private Map m_adapters;
|
||||
private List m_types;
|
||||
private List m_maps;
|
||||
private List m_tables;
|
||||
private List m_ops;
|
||||
|
||||
public Adapter getAdapter(Class klass) {}
|
||||
}
|
||||
|
||||
class Adapter {
|
||||
public Root getRoot();
|
||||
}
|
||||
|
||||
abstract class Element {
|
||||
Root getRoot() {}
|
||||
}
|
||||
|
||||
class ObjectType extends Element {}
|
||||
|
||||
/**
|
||||
* @has "1..1" - "1..1" ObjectType
|
||||
**/
|
||||
class ObjectMap extends Element {
|
||||
private ObjectType m_type;
|
||||
}
|
||||
|
||||
class Table extends Element {}
|
||||
|
||||
class DataOperation extends Element {}
|
||||
|
||||
/**
|
||||
* @hidden
|
||||
* @opt nodefontname luxisr
|
||||
* @opt nodefontabstractname luxisri
|
||||
* @opt edgefontname luxisr
|
||||
* @opt nodefontsize 8
|
||||
* @opt edgefontsize 8
|
||||
* @opt nodefillcolor LemonChiffon
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/**
|
||||
* @view
|
||||
* @opt attributes
|
||||
* @opt operations
|
||||
*/
|
||||
class DetailedView {}
|
||||
|
||||
/**
|
||||
* @view
|
||||
*/
|
||||
class Overview {}
|
||||
|
|
@ -0,0 +1,59 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<p>
|
||||
UMLGraph was developed and is being maintained by
|
||||
<a href="http://www.spinellis.gr">Diomidis Spinellis</a>.
|
||||
Andrea Aime has contributed the functionality for
|
||||
adding UML diagrams to javadoc pages, for inferring relationships,
|
||||
and for multiple diagram views.
|
||||
</p>
|
||||
<p>
|
||||
In addition,
|
||||
the following individuals have contributed useful comments and code.
|
||||
UMLGraph would not be in its current state without their contributions.
|
||||
</p>
|
||||
<ul>
|
||||
<li>Nascif Abousalh-Neto</li>
|
||||
<li>Roger Alexander</li>
|
||||
<li>Panagiotis Astithas</li>
|
||||
<li>Bernd Blacha</li>
|
||||
<li>Yves Bossel</li>
|
||||
<li>Maxim Butov</li>
|
||||
<li>David P. Caldwell</li>
|
||||
<li>Anthony Callegaro</li>
|
||||
<li>Cimballi</li>
|
||||
<li>Dirk Datzert</li>
|
||||
<li>Christophe Deneux</li>
|
||||
<li>Nick Efthymiou</li>
|
||||
<li>Georgios Gousios</li>
|
||||
<li>Antti Hakala</li>
|
||||
<li>Art Hampton</li>
|
||||
<li>Alan Jeffrey</li>
|
||||
<li>Øyvind Jergan</li>
|
||||
<li>Scott Johnson</li>
|
||||
<li>Gunho Kim</li>
|
||||
<li>Nikita Kozlov</li>
|
||||
<li>Trustin Lee</li>
|
||||
<li>Joshua Lim</li>
|
||||
<li>Stefano Martina</li>
|
||||
<li>Vadim Nasardinov</li>
|
||||
<li>Laird Nelson</li>
|
||||
<li>Bernd Onasch</li>
|
||||
<li>Sébastien Pierre</li>
|
||||
<li>Olek Poplavskyy</li>
|
||||
<li>Alessandro Riva</li>
|
||||
<li>Arnaud Rogues</li>
|
||||
<li>Soraya Santana de la Fe</li>
|
||||
<li>Jonathan R. Santos</li>
|
||||
<li>Jan Schlüter</li>
|
||||
<li>Erich Schubert</li>
|
||||
<li>Sebastian Setzer</li>
|
||||
<li>Jörn Guy Süß</li>
|
||||
<li>Andreas Studer</li>
|
||||
<li>Przemyslaw Szufel</li>
|
||||
<li>Ivan F. Villanueva B.</li>
|
||||
<li>Przemyslaw Wesolek</li>
|
||||
<li>Franz Wilhelmstoetter</li>
|
||||
<li>Zhigang Xie</li>
|
||||
</ul>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,37 @@
|
|||
/*
|
||||
* Advanced relationships
|
||||
* UML User Guide p. 137
|
||||
*/
|
||||
|
||||
/**
|
||||
* @opt attributes
|
||||
* @opt operations
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
class Controller {}
|
||||
class EmbeddedAgent {}
|
||||
class PowerManager {}
|
||||
|
||||
/**
|
||||
* @extends Controller
|
||||
* @extends EmbeddedAgent
|
||||
* @navassoc - - - PowerManager
|
||||
*/
|
||||
class SetTopController implements URLStreamHandler {
|
||||
int authorizationLevel;
|
||||
void startUp() {}
|
||||
void shutDown() {}
|
||||
void connect() {}
|
||||
}
|
||||
|
||||
/** @depend - <friend> - SetTopController */
|
||||
class ChannelIterator {}
|
||||
|
||||
interface URLStreamHandler {
|
||||
void OpenConnection();
|
||||
void parseURL();
|
||||
void setURL();
|
||||
void toExternalForm();
|
||||
}
|
||||
|
|
@ -0,0 +1,42 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
To run the UMLGraph doclet from <em>ant</em>, use a rule,
|
||||
like the following.
|
||||
<fmtcode ext="xml">
|
||||
<target name="uml" depends="prepare">
|
||||
<property name="uml.dir" value="${basedir}/uml"/>
|
||||
<property name="src.uml.dir" value="${src.dir}/uml"/>
|
||||
<mkdir dir="${uml.dir}"/>
|
||||
<path id="uml.source.path">
|
||||
<pathelement path="${src.uml.dir}/"/>
|
||||
<pathelement path="${src.java.dir}"/>
|
||||
</path>
|
||||
<javadoc sourcepathref="uml.source.path" packagenames="*" package="true">
|
||||
<doclet name="org.umlgraph.doclet.UmlGraph" path="${basedir}/lib/UmlGraph.jar">
|
||||
<param name="-d" value="${uml.dir}"/>
|
||||
</doclet>
|
||||
</javadoc>
|
||||
<apply executable="dot" dest="${uml.dir}" parallel="false">
|
||||
<arg value="-Tpng"/>
|
||||
<arg value="-o"/>
|
||||
<targetfile/>
|
||||
<srcfile/>
|
||||
<fileset dir="${uml.dir}" includes="*.dot"/>
|
||||
<mapper type="glob" from="*.dot" to="*.png"/>
|
||||
</apply>
|
||||
</target>
|
||||
</fmtcode>
|
||||
<h2>Notes</h2>
|
||||
<ul>
|
||||
<li>When you pass the <code>packagenames</code> option to
|
||||
<em>javadoc</em>, the default (unnamed) package (and the
|
||||
<code>UMLOptions</code> class
|
||||
located in it) is ignored.
|
||||
In such cases you should include the <code>UMLOptions</code> class
|
||||
within a named package.</li>
|
||||
|
||||
<li>The above invocation will generated a single class
|
||||
diagram. If multiple view generation is required you should add
|
||||
the <code>views</code> option.</li>
|
||||
</ul>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
|
||||
/**
|
||||
* Associations with visibility
|
||||
* UML User Guide p. 145
|
||||
*
|
||||
* @opt horizontal
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/** @assoc * - "*\n\n+user " User */
|
||||
class UserGroup {}
|
||||
|
||||
/** @navassoc "1\n\n+owner\r" - "*\n\n+key" Password */
|
||||
class User{}
|
||||
|
||||
class Password{}
|
||||
|
|
@ -0,0 +1,123 @@
|
|||
@Article{GKNK93,
|
||||
author = "Emden R. Gasner and Eleftherios Koutsofios and Stephen C. North and Kiem-Phong Vo",
|
||||
Title="A Technique for Drawing Directed Graphs",
|
||||
Journal=ieeese,
|
||||
Pages="124--230",
|
||||
Volume="19",
|
||||
Number="3",
|
||||
Month=may,
|
||||
Year="1993"
|
||||
}
|
||||
|
||||
@Article{Spi03e,
|
||||
Title="On the Declarative Specification of Models",
|
||||
Author="Diomidis Spinellis",
|
||||
Journal="IEEE Software",
|
||||
Month="March/April",
|
||||
Year=2003,
|
||||
Volume=20,
|
||||
Pages="94--96",
|
||||
Number=2,
|
||||
URL="http://www.dmst.aueb.gr/dds/pubs/jrnl/2003-IEEESW-umlgraph/html/article.html"
|
||||
}
|
||||
|
||||
@Book {Spi03i,
|
||||
Author="Diomidis Spinellis",
|
||||
Title="Code Reading: The Open Source Perspective",
|
||||
Publisher="Addison-Wesley",
|
||||
Address="Boston, MA",
|
||||
URL="http://www.spinellis.gr/codereading",
|
||||
Year=2003
|
||||
}
|
||||
|
||||
@TechReport {TRPIC,
|
||||
Author="Brian W. Kernighan",
|
||||
Title="{PIC}---A Graphics Language for typesetting: Revised User Manual",
|
||||
Type="Computer Science Technical Report",
|
||||
Note="Available online at \url{http://cm.bell-labs.com/cm/cs/cstr}",
|
||||
Number="116",
|
||||
Month=dec,
|
||||
Year="1984",
|
||||
Institution="Bell Laboratories",
|
||||
Address="Murray Hill, NJ"
|
||||
}
|
||||
|
||||
@Book {FS00,
|
||||
Author="Martin Fowler and Kendall Scott",
|
||||
Title="{UML} Distilled: Applying the Standard Object Modeling Language",
|
||||
Publisher="Addison-Wesley",
|
||||
ISBN="0-201-65783-X",
|
||||
Address="Boston, MA",
|
||||
Edition="second",
|
||||
Year=2000
|
||||
}
|
||||
|
||||
@Book{BRJ99,
|
||||
Title="The Unified Modeling Language User Guide",
|
||||
Author="Grady Booch and James Rumbaugh and Ivar Jacobson",
|
||||
Publisher="Addison-Wesley",
|
||||
Address="Reading, MA",
|
||||
Year="1999",
|
||||
ISBN="0-201-57168-4"
|
||||
}
|
||||
|
||||
@Book{RJB99,
|
||||
Title="The Unified Modeling Language Reference Manual",
|
||||
Author="James Rumbaugh and Ivar Jacobson and Grady Booch",
|
||||
Publisher="Addison-Wesley",
|
||||
Address="Reading, MA",
|
||||
Year="1999",
|
||||
ISBN="0-201-30998-X",
|
||||
Where="dds-CD1"
|
||||
}
|
||||
|
||||
@Book {Spi06,
|
||||
Author="Diomidis Spinellis",
|
||||
Title="Code Quality: The Open Source Perspective",
|
||||
Publisher="Addison-Wesley",
|
||||
Address="Boston, MA",
|
||||
URL="http://www.spinellis.gr/codequality",
|
||||
XISBN="0-321-16607-8",
|
||||
Year=2006
|
||||
}
|
||||
|
||||
@Misc{Shoe06,
|
||||
Title="{UML} Diagrams Using {G}raphviz {D}ot",
|
||||
Month=apr,
|
||||
Year=2006,
|
||||
URL="http://www.ffnn.nl/pages/articles/media/uml-diagrams-using-graphviz-dot.php",
|
||||
Note="Available online \url{http://www.ffnn.nl/pages/articles/media/uml-diagrams-using-graphviz-dot.php}",
|
||||
Author="Frank Schoep"
|
||||
}
|
||||
|
||||
@TechReport{OMG02,
|
||||
Author="{Object Management Group}",
|
||||
Title="Human-Usable Textual Notation ({HUTN}) Specification",
|
||||
Note="Available online \url{http://www.omg.org/docs/ptc/02-12-01.pdf}",
|
||||
URL="http://www.omg.org/docs/ptc/02-12-01.pdf",
|
||||
Number="ptc/02-12-01",
|
||||
Month=dec,
|
||||
Year=2002,
|
||||
Institution="OMG Inc.",
|
||||
Address="Needham, MA"
|
||||
}
|
||||
|
||||
@Misc{Mir08,
|
||||
Title="Reverse-engineer Source Code into UML Diagrams",
|
||||
Month=aug,
|
||||
Year=2008,
|
||||
URL="http://java.dzone.com/articles/reverse-engineer-source-code-u",
|
||||
Note="Available online \url{http://java.dzone.com/articles/reverse-engineer-source-code-u}",
|
||||
Author="Meera Subbarao"
|
||||
}
|
||||
|
||||
@CONFERENCE{SG16,
|
||||
author={Seifermann, S. and Groenda, H.},
|
||||
title={Survey on textual notations for the Unified Modeling Language},
|
||||
journal={MODELSWARD 2016 - Proceedings of the 4th International Conference on Model-Driven Engineering and Software Development},
|
||||
year={2016},
|
||||
pages={28--39},
|
||||
note={cited By 0},
|
||||
url={https://www.cooperate-project.de/images/publications/MODELSWARD2016.pdf},
|
||||
document_type={Conference Paper},
|
||||
}
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
|
||||
class Tyre {}
|
||||
class Engine {}
|
||||
class Body {}
|
||||
|
||||
/**
|
||||
* @composed 1 - 4 Tyre
|
||||
* @composed 1 - 1 Engine
|
||||
* @composed 1 - 1 Body
|
||||
*/
|
||||
class Car {}
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
/*
|
||||
* Interface and generalization relationships in Jakarta Catalina
|
||||
*/
|
||||
|
||||
/**
|
||||
* @opt nodefontname "Arial"
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions{}
|
||||
|
||||
class HttpResponseBase
|
||||
extends ResponseBase
|
||||
implements HttpResponse, HttpServletResponse {}
|
||||
|
||||
abstract class HttpResponseWrapper
|
||||
extends ResponseWrapper
|
||||
implements HttpResponse {}
|
||||
|
||||
class HttpResponseFacade
|
||||
extends ResponseFacade
|
||||
implements HttpServletResponse {}
|
||||
|
||||
abstract class ResponseWrapper implements Response {}
|
||||
abstract interface HttpResponse extends Response {}
|
||||
abstract class ResponseBase implements Response, ServletResponse {}
|
||||
abstract interface HttpServletResponse {}
|
||||
class ResponseFacade implements ServletResponse {}
|
||||
|
||||
abstract interface ServletResponse {}
|
||||
abstract interface Response {}
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
<?xml version="1.0" encoding="ISO-8859-7" ?>
|
||||
<notes>
|
||||
One specifies a class diagram using the Java syntax complemented by
|
||||
<a href="http://java.sun.com/j2se/javadoc/"><em>javadoc</em></a>
|
||||
tags.
|
||||
Running the UmlGraph doclet on the specification will generate
|
||||
a
|
||||
<a href="http://www.graphviz.org/">Graphviz</a>
|
||||
diagram specification that can be automatically processed to
|
||||
create PNG, SVG, EMF, Postscript, GIF, JPEG, fig, or Framemaker drawings.
|
||||
<p />
|
||||
The following is an example of a specification and the resulting UML class
|
||||
diagram:
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
class Person {
|
||||
String Name;
|
||||
}
|
||||
|
||||
class Employee extends Person {}
|
||||
|
||||
class Client extends Person {}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="class-eg.gif" alt="Simple UML class diagram" />
|
||||
</td></tr></table>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,78 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The UMLGraph class diagrams allows you to model
|
||||
<ul>
|
||||
<li>classes (specified as Java classes)
|
||||
</li>
|
||||
<li>
|
||||
active classes, components, nodes, use cases,
|
||||
collaborations, and packages
|
||||
(specified as Java classes with an <code>@opt shape</code> tag)
|
||||
</li>
|
||||
<li>attributes (specified as Java class fields)
|
||||
</li>
|
||||
<li>operations (specified as Java class methods)
|
||||
</li>
|
||||
<li>stereotypes (using the <code>@stereotype</code> <em>name</em> tag)
|
||||
</li>
|
||||
<li>tagged values (using the <code>@tagvalue</code> <em>name</em> <em>value</em> tag)
|
||||
</li>
|
||||
<li>implementation relationships (specified using the Java <code>implements</code> declaration)
|
||||
</li>
|
||||
<li>generalization relationships (specified using the Java <code>extends</code> declaration or (for multiple inheritance) the <em>javadoc</em> <code>@extends</code> tag)
|
||||
</li>
|
||||
<li>association relationships (specified using the <em>javadoc</em> <code>@assoc</code> tag) </li>
|
||||
<li>navigable (directed) association relationships (specified using the <em>javadoc</em> <code>@navassoc</code> tag) </li>
|
||||
<li>aggregation relationships (specified using the <em>javadoc</em> <code>@has</code> tag) </li>
|
||||
<li>navigable aggregation relationships (specified using the <em>javadoc</em> <code>@navhas</code> tag) </li>
|
||||
<li>composition relationships (specified using the <em>javadoc</em> <code>@composed</code> tag) </li>
|
||||
<li>navigable composition relationships (specified using the <em>javadoc</em> <code>@navcomposed</code> tag) </li>
|
||||
<li>dependency relationships (specified using the <em>javadoc</em> <code>@depend</code> tag)
|
||||
</li>
|
||||
</ul>
|
||||
All relationship tags apart from <code>@extends</code> take four arguments:
|
||||
<ol>
|
||||
<li> The source adornments (role, multiplicity, and visibility)
|
||||
</li>
|
||||
<li> The relationship name
|
||||
</li>
|
||||
<li> The target adornments (role, multiplicity, and visibility)
|
||||
</li>
|
||||
<li> The target class
|
||||
</li>
|
||||
</ol>
|
||||
Arguments can be space-separated, or enclosed in quotes if they
|
||||
need to contain the space character.
|
||||
The - character is used as a placeholder to denote empty arguments.
|
||||
You can use the \n sequence to separate the first three adornments
|
||||
in separate centered lines;
|
||||
the \l and \r sequences can also be used to generate left and right
|
||||
aligned lines.
|
||||
You can use the < and > characters in the relationship name
|
||||
to enclose stereotype names.
|
||||
These will be automatically enclosed in guillemots.
|
||||
Note that a relationship's target class is not implicitly
|
||||
defined; it should also be specified using the Java class syntax.
|
||||
The target can be specified by simple name, java class lookup rules
|
||||
(imports and visibility) will be used to determine the actual class.
|
||||
The following is an example of a relationship
|
||||
specification and the resulting UML diagram:
|
||||
<table>
|
||||
<tr><td>
|
||||
<pre>
|
||||
class Tyre {}
|
||||
class Engine {}
|
||||
class Body {}
|
||||
|
||||
/**
|
||||
* @composed 1 - 4 Tyre
|
||||
* @composed 1 - 1 Engine
|
||||
* @composed 1 - 1 Body
|
||||
*/
|
||||
class Car {}
|
||||
</pre>
|
||||
</td><td>
|
||||
<img src="car.gif" alt="UML relationship diagram" />
|
||||
</td></tr></table>
|
||||
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
In UMLGraph you can easily add a note (comment) to an element,
|
||||
using the <code>@note</code> tag.
|
||||
The corresponding text will be split into lines, as specified in the note.
|
||||
Multiple tags can be used to add more notes to the same element.
|
||||
More complicated, (one to many) relationships can be established
|
||||
by creating an element with a note shape, setting its contents
|
||||
to its comment text through the <code>@opt commentname</code> tag,
|
||||
and associating it with other elements with the <code>@assoc</code>
|
||||
tag.
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* @opt shape node
|
||||
* @note Located in the
|
||||
* machine room
|
||||
* @note Sun Blade 6048
|
||||
* @depend - - - MapLocation
|
||||
* @depend - - - DataMine
|
||||
*/
|
||||
class Server{}
|
||||
|
||||
/** @opt shape component */
|
||||
class MapLocation {}
|
||||
|
||||
/** @opt shape component */
|
||||
class DataMine {}
|
||||
|
||||
/**
|
||||
* CPU-munching
|
||||
* components that must
|
||||
* run on this server
|
||||
* @opt shape note
|
||||
* @opt commentname
|
||||
* @assoc - - - MapLocation
|
||||
* @assoc - - - DataMine
|
||||
*/
|
||||
class munchComment {}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="note.gif" alt="UML note example" />
|
||||
</td></tr></table>
|
||||
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,132 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
UMLGraph's input follows the Java syntax and semantics.
|
||||
However,
|
||||
since the main purpose of UMLGraph is the declarative specification of
|
||||
UML diagrams there is no need to flesh-out each class's methods,
|
||||
to completely specify each class, or to specify package information.
|
||||
You only specify the details you want to appear on the graph.
|
||||
If you wish your (Java) implementation to evolve together with the
|
||||
design feel free to include code or additional details.
|
||||
You can hide these details from the UML diagram using the <em>javadoc</em>
|
||||
<code>@hidden</code> tag applied to classes, methods, and fields.
|
||||
In theory you can also use UMLGraph to reverse engineer existing
|
||||
Java code.
|
||||
Note however that UMLGraph was not originally designed for this purpose;
|
||||
the resulting graphs may be large and unwieldy.
|
||||
<p />
|
||||
There are various ways to invoke UMLGraph,
|
||||
each providing a different balance between convenience and flexibility.
|
||||
<h2>Option 1: Using the Supplied Script</h2>
|
||||
This is the simplest option.
|
||||
If <code>umlgraph</code> (or <code>umlgraph.bat</code>) is correctly
|
||||
installed,
|
||||
you can run UMLGraph by simply specifying the basename of
|
||||
the Java file containing the diagram specification and the file type of
|
||||
the generated diagram (e.g. gif, ps, png, svg).
|
||||
Example:
|
||||
<fmtcode ext="sh">
|
||||
umlgraph Test png
|
||||
</fmtcode>
|
||||
Any additional UMLGraph or <em>javadoc</em> arguments can be added at
|
||||
the end of the command line.
|
||||
This command will read the specification file (e.g. Test.java) and
|
||||
generate directly a diagram of the appropriate type
|
||||
(e.g. Test.png).
|
||||
<h2>Option 2: Running Java</h2>
|
||||
This option provides the maximum flexibility.
|
||||
In order to run, <em>javadoc</em> needs to access <code>tools.jar</code>.
|
||||
You can accomplish this in two ways.
|
||||
<ol>
|
||||
<li>
|
||||
Specify the location of <code>tools.jar</code> as a part of Java's classpath
|
||||
and specify the full name of the UMLGraph doclet as an argument to Java.
|
||||
This is an invocation example under Windows
|
||||
<fmtcode ext="bat">
|
||||
java -classpath "lib/UmlGraph.jar;c:\program files\java\jdk1.6.0_02\lib\Tools.jar"
|
||||
org.umlgraph.doclet.UmlGraph -package Test.java
|
||||
</fmtcode>
|
||||
and under Unix
|
||||
<fmtcode ext="sh">
|
||||
java -classpath '/usr/share/lib/UmlGraph.jar:/opt/Java-1.6/lib/tools.jar' \
|
||||
org.umlgraph.doclet.UmlGraph -package Test.java
|
||||
</fmtcode>
|
||||
</li>
|
||||
<li> Place the <code>UmlGraph.jar</code>
|
||||
file in a directory that also contains the Java SDK <code>tools.jar</code> file.
|
||||
You can accomplish this either by copying <code>UmlGraph.jar</code> to the SDK
|
||||
<code>lib</code> directory where <code>tools.jar</code> resides,
|
||||
or by copying the JDK <code>tools.jar</code> file into the directory
|
||||
where you installed UMLGraph.
|
||||
You then run
|
||||
<fmtcode ext="sh">
|
||||
java -jar /path/to/UmlGraph.jar yourfile1.java ...
|
||||
</fmtcode>
|
||||
</li>
|
||||
</ol>
|
||||
You can use any of the <em>javadoc</em> general options;
|
||||
<code>-private</code> is usually needed to avoid having to explicitly
|
||||
specify public elements.
|
||||
Example:
|
||||
<fmtcode ext="sh">
|
||||
java -jar /usr/jvm/java-1.5.0/lib/UmlGraph.jar -private Simple.java
|
||||
</fmtcode>
|
||||
<p />
|
||||
To generate a diagram of all classes in the package specify as arguments
|
||||
to the Java invocation the name of the package and the directory where
|
||||
it resides.
|
||||
The following example generates a diagram of all UMLGraph classes.
|
||||
<fmtcode ext="sh">
|
||||
java -classpath ... org.umlgraph.doclet.UmlGraph -sourcepath src/main/java org.umlgraph.doclet
|
||||
</fmtcode>
|
||||
<p />
|
||||
Specifying some packages before the list of source files will designate
|
||||
those packages as <em>local</em>.
|
||||
When you specify a package list,
|
||||
the SVG output UMLgraph generates will contain
|
||||
local hyperlinks for the local classes
|
||||
and hyperlinks to the Sun Java API documentation for all other classes.
|
||||
<p />
|
||||
|
||||
<h2>Option 3: Running Javadoc</h2>
|
||||
Alternatively, you can also run <em>UMLGraph</em> from within <em>javadoc</em>.
|
||||
This can be useful if your IDE provides additional support for running <em>javadoc</em>.
|
||||
In this case you run
|
||||
<em>javadoc</em> with arguments <code>-doclet org.umlgraph.doclet.UmlGraph</code>
|
||||
<code>-docletpath /path/to/UmlGraph.jar</code>
|
||||
and append at the end the file(s) that contain your diagram
|
||||
specification.
|
||||
Example:
|
||||
<fmtcode ext="sh">
|
||||
javadoc -docletpath UmlGraph.jar -doclet org.umlgraph.doclet.UmlGraph -private Simple.java
|
||||
</fmtcode>
|
||||
|
||||
<h2>Running Dot</h2>
|
||||
The last two options, will generate the UML diagram in
|
||||
<em>Graphviz</em> <em>dot</em> format.
|
||||
This is a text file that can be processed by the <em>Graphviz</em> <em>dot</em>
|
||||
program to layout and draw the graph.
|
||||
<em>javadoc</em> will create by default a file named <code>graph.dot</code>
|
||||
in the current directory.
|
||||
A command line like the following will convert the <code>graph.dot</code>
|
||||
file into Postscript:
|
||||
<fmtcode ext="sh">
|
||||
dot -Tps -ograph.ps graph.dot
|
||||
</fmtcode>
|
||||
or PNG
|
||||
<fmtcode ext="sh">
|
||||
dot -Tpng -ograph.png graph.dot
|
||||
</fmtcode>
|
||||
Refer to the <em>dot</em> documentation for information on creating other file formats
|
||||
or adjusting the UMLGraph output.
|
||||
<p />
|
||||
You also can pipe the result of <em>UMLGraph</em> directly into <em>dot</em>:
|
||||
<fmtcode ext="sh">
|
||||
java -jar /.../UmlGraph.jar -private -output - Simple.java | dot -Tgif -ograph.gif
|
||||
</fmtcode>
|
||||
<p />
|
||||
Note that when you use <em>dot</em> for generating SVG diagrams your
|
||||
should specify the <code>-outputencoding UTF-8</code> option to UMLGraph.
|
||||
This option will correctly render the stereotype guillemot characters
|
||||
in the <em>dot</em> output and the corresponding SVG file.
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,45 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
Since the options are really a part of the generated graph you
|
||||
want in many cases to include them in the diagram specification.
|
||||
You can do that by adding <em>javadoc</em> <code>@opt</code> tags in front
|
||||
of a class named <code>UMLOptions</code>, as in the following example:
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* @opt horizontal
|
||||
* @opt all
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
</fmtcode>
|
||||
<p />
|
||||
Similarly, you can also globally specify options for all the note elements.
|
||||
through a class named <code>UMLNoteOptions</code>, as in the following example:
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* @hidden
|
||||
* @opt nodefontcolor "blue"
|
||||
*/
|
||||
class UMLNoteOptions{}
|
||||
</fmtcode>
|
||||
<p />
|
||||
|
||||
You can also change the UMLGraph operation on a per-class basis by
|
||||
using <code>@opt</code> attributes on individual classes.
|
||||
In this case the <code>@opt</code> specification temporarily overrides
|
||||
the particular global setting for the class being processed.
|
||||
|
||||
<p/>Finally, you can reset an option to its default value by prefixing it
|
||||
with an exclamation mark. For example:
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* @opt !attributes
|
||||
* @opt !nodefontsize
|
||||
*/
|
||||
class MyClass {}
|
||||
</fmtcode>
|
||||
|
||||
will disable attribute listing for MyClass, and reset the node font size
|
||||
to its default value (10).
|
||||
</notes>
|
||||
|
||||
|
|
@ -0,0 +1,193 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
A number of options control the operation of UMLGraph
|
||||
class diagram generator.
|
||||
These can be specified on the command line, and most can also
|
||||
be specified through javadoc <code>@opt</code> tags within the diagram, affecting all or some elements.
|
||||
Most have a negated version by prefixing an exclamation mark.
|
||||
<p/>
|
||||
<h2>What Gets Drawn</h2> <!-- {{{1 -->
|
||||
<dl>
|
||||
<dt>-all</dt><dd>Same as
|
||||
<code>-attributes</code>
|
||||
<code>-operations</code>
|
||||
<code>-visibility</code>
|
||||
<code>-types</code>
|
||||
<code>-enumerations</code>
|
||||
<code>-enumconstants</code>
|
||||
</dd>
|
||||
<dt>-attributes</dt><dd>Show class attributes (Java fields) </dd>
|
||||
<dt>-commentname</dt><dd>Name the element using the text in the javadoc comment, instead of the name of its class. </dd>
|
||||
<dt>-constructors</dt><dd>Show a class's constructors </dd>
|
||||
<dt>-enumconstants</dt><dd>When showing enumerations, also show the values they can take. </dd>
|
||||
<dt>-enumerations</dt><dd>Show enumarations as separate stereotyped primitive types. </dd>
|
||||
<dt>-hide</dt><dd>Specify entities to hide from the graph.
|
||||
Matching is done using a non-anchored regular match.
|
||||
For instance, "<code>-hide (Big|\.)Widget</code>" would hide "<code>com.foo.widgets.Widget</code>" and
|
||||
"<code>com.foo.widgets.BigWidget</code>". Can also be used without arguments,
|
||||
in this case it will hide everything (useful in the context of views
|
||||
to selectively unhide some portions of the graph, see the view chapter for
|
||||
further details). </dd>
|
||||
<dt>-include</dt><dd>Match classes to include with a non-anchored match. This is weaker than
|
||||
the <code>-hide</code> option, but can be used to include classes from foreign packages
|
||||
in the package view (which would by default filter to only include package members).</dd>
|
||||
<dt>-operations</dt><dd>Show class operations (Java methods) </dd>
|
||||
<dt>-qualify</dt><dd>Produce fully-qualified class names. </dd>
|
||||
<dt>-qualifyGenerics</dt><dd>Use fully-qualified class names in Java generics.</dd>
|
||||
<dt>-types</dt><dd>Add type information to attributes and operations </dd>
|
||||
<dt>-view</dt><dd>Specify the fully qualified name of a class that contains
|
||||
a view definition. Only the class diagram specified by this view will be generated.
|
||||
<br/>See the views chapter for more details. </dd>
|
||||
<dt>-views</dt><dd>Generate a class diagram for every view found in the source path. </dd>
|
||||
<dt>-visibility</dt><dd>Adorn class elements according to their visibility (private, public, protected, package) </dd>
|
||||
</dl>
|
||||
<h2>Visual Appearance</h2> <!-- {{{1 -->
|
||||
<dl>
|
||||
<dt>-bgcolor</dt><dd>Specify the graph's background color. </dd>
|
||||
<dt>-autosize</dt><dd>Fits generated graph to the width of the page/window. Defaults to true. </dd>
|
||||
<dt>-collapsible</dt><dd>Enhance the javadoc HTML files containing UML diagrams with Javascript that provides a link for showing the (initially collapsed) diagrams. </dd>
|
||||
<dt>-edgecolor</dt><dd>Specify the color for drawing edges. </dd>
|
||||
<dt>-edgefontcolor</dt><dd>Specify the font color to use for edge labels. </dd>
|
||||
<dt>-edgefontname</dt><dd>Specify the font name to use for edge labels. </dd>
|
||||
<dt>-edgefontsize</dt><dd>Specify the font size to use for edge labels. </dd>
|
||||
<dt>-horizontal</dt><dd>Layout the graph in the horizontal direction. </dd>
|
||||
<dt>-nodefillcolor</dt><dd>Specify the color to use to fill the shapes. </dd>
|
||||
<dt>-nodefontabstractname</dt><dd>Specify the font name to use inside abstract class nodes. </dd>
|
||||
<dt>-nodefontclassabstractname</dt><dd>Specify the font name use for the class name of abstract classes. </dd>
|
||||
<dt>-nodefontclassname</dt><dd>Specify the font name to use for the class names. </dd>
|
||||
<dt>-nodefontclasssize</dt><dd>Specify the font size to use for the class names. </dd>
|
||||
<dt>-nodefontcolor</dt><dd>Specify the font color to use inside nodes. </dd>
|
||||
<dt>-nodefontname</dt><dd>Specify the font name to use inside nodes. </dd>
|
||||
<dt>-nodefontpackagename</dt><dd>Specify the font name to use for the package names (used only when the package name is postfixed, see -postfixpackage). </dd>
|
||||
<dt>-nodefontpackagesize</dt><dd>Specify the font size to use for the package names (used only when it package name is postfixed, see -postfixpackage). </dd>
|
||||
<dt>-nodefontsize</dt><dd>Specify the font size to use inside nodes. </dd>
|
||||
<dt>-nodefonttagname</dt><dd>Specify the font name to use for the tag names. </dd>
|
||||
<dt>-nodefonttagsize</dt><dd>Specify the font size to use for the tag names. </dd>
|
||||
<dt>-nodesep</dt><dd>Specify the horizontal separation between the class nodes (0.25 by default). Decreasing this can make a diagram more compact.</dd>
|
||||
<dt>-noguillemot</dt><dd>Specify that guillemot characters should not be used to denote special terms like "interface" and stereotype names. This is used on some platforms to circumvent problems associated with displaying non-ASCII characters. </dd>
|
||||
<dt>-postfixpackage</dt><dd>When using qualified class names, put the package name in the line after the class name, in order to reduce the width of class nodes. </dd>
|
||||
<dt>-ranksep</dt><dd>Specify the vertical separation between the class nodes (0.5 by default). Decreasing this can make a diagram more compact.</dd>
|
||||
<dt>-shape</dt><dd>Specify the shape to use for the rendered element(s).
|
||||
The following UML shapes are available:
|
||||
<ul>
|
||||
<li>class (default)</li>
|
||||
<li>node</li>
|
||||
<li>component</li>
|
||||
<li>package</li>
|
||||
<li>collaboration</li>
|
||||
<li>usecase</li>
|
||||
<li>activeclass</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
<p />
|
||||
All colors can be either a symbolic name (e.g. blue),
|
||||
a triple specifying hue-saturation-brightness as values 0-1
|
||||
(e.g. ".13 0.9 1"),
|
||||
or a triple specifying red-green-blue values as hexadecimal
|
||||
digits prefixed by a # (e.g. "#ff8020").
|
||||
The symbolic color names are derived from the X Windows System;
|
||||
you can find a complete list in the
|
||||
<a href="http://www.graphviz.org/doc/info/colors.html">Graphviz documentation</a>
|
||||
<p />
|
||||
Font names are passed directly to the dot graph generation back-end.
|
||||
In general the Postcript standard names Times, Helvetica, Courier, and
|
||||
Symbol are safe to use.
|
||||
<h2>Relationship Inference</h2> <!-- {{{1 -->
|
||||
<dl>
|
||||
<dt>-collpackages</dt><dd>Specify the classes that will be treated as
|
||||
containers for one to many relationships when inference is enabled.
|
||||
Matching is done using a non-anchored regular match. Empty by default.
|
||||
</dd>
|
||||
<dt>-inferdep</dt><dd>Try to automatically infer dependencies between classes by inspecting
|
||||
methods and fields. See the class diagram inference chapter for more details. Disabled by default.
|
||||
</dd>
|
||||
<dt>-inferdepinpackage</dt><dd>Enable or disable dependency inference among classes in the
|
||||
same package. This option is disabled by default, because classes in the same package are supposed
|
||||
to be related anyway, and also because there's no working mechanism to actually detect all
|
||||
of these dependencies since imports are not required to use classes in the same package.
|
||||
</dd>
|
||||
<dt>-inferdepvis</dt><dd>Specifies the lowest visibility level of elements used to infer
|
||||
dependencies among classes. Possible values are private, package, protected, public, in this
|
||||
order. The default value is private. Use higher levels to limit the number of inferred dependencies.
|
||||
</dd>
|
||||
<dt>-inferrel</dt><dd>Try to automatically infer relationships between classes by inspecting
|
||||
field values. See the class diagram inference chapter for further details. Disabled by default.
|
||||
</dd>
|
||||
<dt>-inferreltype</dt><dd>The type of relationship inferred when -inferrel is activated.
|
||||
Defaults to "navassoc" (see the class modelling chapter for a list of relationship types).
|
||||
</dd>
|
||||
<dt>-useimports</dt><dd>Will also use imports to infer dependencies.
|
||||
Disabled by default, since it does not work properly if there are multiple
|
||||
classes in the same source file (will add dependencies to every class in
|
||||
the source file).
|
||||
</dd>
|
||||
</dl>
|
||||
<h2>API Hyperlinks</h2> <!-- {{{1 -->
|
||||
<dl>
|
||||
<dt>-apidocmap</dt><dd>Specify the file name of the URL mapping table.
|
||||
The is a standard Java property file, where the property name is a regular
|
||||
expression (as defined in the java.util.regex package) and the property value is
|
||||
an URL "root" as described above.
|
||||
This table is used to resolved external class names (class names that do not
|
||||
belong to the current package being processed by UMLGraph). If no file is provided,
|
||||
external classes will just be mapped to the on-line Java API documentation.
|
||||
</dd>
|
||||
<dt>-apidocroot</dt><dd>Specify the URL that should be used as the "root" for local classes.
|
||||
This URL will be used as a prefix, to which the page name for the local class or
|
||||
package will be appended (following the JavaDoc convention).
|
||||
For example, if the value <code>http://www.acme.org/apidocs</code> is
|
||||
provided, the class <code>org.acme.util.MyClass</code> will be mapped to the URL
|
||||
<code>http://www.acme.org/apidocs/org/acme/util/MyClass.html</code>.
|
||||
This URL will then be added to .dot diagram and can be surfaced in the
|
||||
final class diagram by setting the output to SVG, or by creating an HTML page
|
||||
that associates the diagram static image (a .gif or .png) with a client-side
|
||||
image map.
|
||||
</dd>
|
||||
<dt>-link</dt><dd>A clone of the standard doclet
|
||||
<a href="http://java.sun.com/j2se/1.5.0/docs/tooldocs/windows/javadoc.html#link">-link</a>
|
||||
option, allows UMLGraph to generate links from class symbols to their external javadoc
|
||||
documentation (image maps are automatically generated in UMLGraphDoc, you'll have to generate them
|
||||
manually with graphviz if using UMLGraph).
|
||||
</dd>
|
||||
</dl>
|
||||
<h2>Operation</h2> <!-- {{{1 -->
|
||||
<dl>
|
||||
<dt>-compact</dt><dd>Generate compact dot files, that is, print HTML labels
|
||||
in a single line instead of "pretty printing" them. Useful if the dot file
|
||||
has to be manipulated by an automated tool
|
||||
(e.g., the UMLGraph regression test suite).
|
||||
</dd>
|
||||
<dt>-d</dt><dd>Specify the output directory (defaults to the current directory).
|
||||
</dd>
|
||||
<dt>-dotexecutable</dt><dd>Specify the path of the <em>dot</em> executable.
|
||||
</dd>
|
||||
<dt>-linkoffline</dt><dd>Specify
|
||||
links to javadoc-generated documentation for external referenced classes.
|
||||
The <code>-linkoffline</code> option takes two arguments:
|
||||
the first for the string to be embedded in the <code>href</code>
|
||||
links, the second telling it where to find the <code>package-list</code>.
|
||||
Example:
|
||||
<pre>
|
||||
-linkoffline http://developer.android.com/reference file:/home/doc/android/
|
||||
</pre>
|
||||
See the <em>javadoc</em> documentation for more details.
|
||||
</dd>
|
||||
<dt>-output</dt><dd>Specify the output file (default <code>graph.dot</code>).
|
||||
If the output directory is provided, -output can only specify a file name,
|
||||
otherwise a full path is accepted as well.
|
||||
If the filename specified is a dash, then the results are printed on the
|
||||
standard output, and can be directly piped into <em>dot</em>.
|
||||
Note that, in order to avoid <em>javadoc</em> messages to contaminate
|
||||
UMLGraph's output, you must execute UMLGraph directly as a jar,
|
||||
not through <em>javadoc</em>.
|
||||
</dd>
|
||||
<dt>-outputencoding</dt><dd>Specify the output encoding character set (default <code>ISO-8859-1</code>).
|
||||
When using <em>dot</em> to generate SVG diagrams you should specify
|
||||
<code>UTF-8</code> as the output encoding, to have guillemots correctly
|
||||
appearing in the resulting SVG.
|
||||
</dd>
|
||||
</dl>
|
||||
<!-- Footer {{{1 -->
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,51 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
UmlGraphDoc is a standard doclet wrapper that combines
|
||||
the standard doclet output (javadoc documentation) along with auto-generated
|
||||
class diagrams for both packages and classes.
|
||||
|
||||
The UmlGraphDoc process is driven by all the parameters that can be specified for
|
||||
UMLGraph and the standard doclet; each will be passed to the appropriate
|
||||
doclet.
|
||||
|
||||
Diagram generation is based on the idea of context:
|
||||
<ul>
|
||||
<li>for packages, the diagram contains all of the classes in the package itself</li>
|
||||
<li>for classes, the set of classes somehow related to the current class</li>
|
||||
</ul>
|
||||
|
||||
The actual content of the diagrams depends on the kind of relations declared on the
|
||||
class files (with the UMLGraph javadoc annotations) and/or on the kind of automated
|
||||
inference that UMLGraph is allowed to use.
|
||||
|
||||
UMLGraph javadocs are now generated with UmlGraphDoc with the following ant target:
|
||||
|
||||
<fmtcode ext="xml">
|
||||
<target name="javadocs" depends="compile">
|
||||
<javadoc sourcepath="${src}" packagenames="org.umlgraph.doclet.*" destdir="${javadoc}"
|
||||
private="true">
|
||||
<doclet name="org.umlgraph.doclet.UmlGraphDoc" path="${lib}/UMLGraph.jar">
|
||||
<param name="-inferrel"/>
|
||||
<param name="-inferdep"/>
|
||||
<param name="-hide" value="java.*"/>
|
||||
<param name="-collpackages" value="java.util.*"/>
|
||||
<param name="-qualify"/>
|
||||
<param name="-postfixpackage"/>
|
||||
<param name="-nodefontsize" value="9"/>
|
||||
<param name="-nodefontpackagesize" value="7"/>
|
||||
<param name="-link" value="http://java.sun.com/j2se/1.5.0/docs/guide/javadoc/doclet/spec"/>
|
||||
<param name="-link" value="http://java.sun.com/j2se/1.5/docs/api"/>
|
||||
</doclet>
|
||||
</javadoc>
|
||||
</target>
|
||||
</fmtcode>
|
||||
|
||||
When generating documentation with UmlGraphDoc you will encounter
|
||||
at some point the "fur ball" effect: some central classes that
|
||||
have very complex context diagrams.
|
||||
To reduce this, you can avoid dependency inference
|
||||
altogheter, or reduce the number of inferred dependencies by using the -inferdepvis options.
|
||||
|
||||
If you find that this is not enough and have suggestions on how to improve the situation further,
|
||||
we are eager to listen.
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,47 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
/*
|
||||
* Advanced relationships
|
||||
* UML User Guide p. 137
|
||||
*/
|
||||
|
||||
/**
|
||||
* @opt attributes
|
||||
* @opt operations
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
class Controller {}
|
||||
class EmbeddedAgent {}
|
||||
class PowerManager {}
|
||||
|
||||
/**
|
||||
* @extends Controller
|
||||
* @extends EmbeddedAgent
|
||||
* @navassoc - - - PowerManager
|
||||
*/
|
||||
class SetTopController implements URLStreamHandler {
|
||||
int authorizationLevel;
|
||||
void startUp() {}
|
||||
void shutDown() {}
|
||||
void connect() {}
|
||||
}
|
||||
|
||||
/** @depend - <friend> - SetTopController */
|
||||
class ChannelIterator {}
|
||||
|
||||
interface URLStreamHandler {
|
||||
void OpenConnection();
|
||||
void parseURL();
|
||||
void setURL();
|
||||
void toExternalForm();
|
||||
}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="advrel.gif" alt="UML diagram showing dependency and navigation relationships" />
|
||||
</td></tr></table>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* Associations with visibility
|
||||
* UML User Guide p. 145
|
||||
*
|
||||
* @opt horizontal
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/** @assoc * - "*\n\n+user " User */
|
||||
class UserGroup {}
|
||||
|
||||
/** @navassoc "1\n\n+owner\r" - "*\n\n+key" Password */
|
||||
class User{}
|
||||
|
||||
class Password{}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="assoc.gif" alt="UML diagram showing association types" />
|
||||
</td></tr></table>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<fmtcode ext="java">
|
||||
/*
|
||||
* Interface and generalization relationships in Jakarta Catalina
|
||||
*/
|
||||
|
||||
class HttpResponseBase
|
||||
extends ResponseBase
|
||||
implements HttpResponse, HttpServletResponse {}
|
||||
|
||||
abstract class HttpResponseWrapper
|
||||
extends ResponseWrapper
|
||||
implements HttpResponse {}
|
||||
|
||||
class HttpResponseFacade
|
||||
extends ResponseFacade
|
||||
implements HttpServletResponse {}
|
||||
|
||||
abstract class ResponseWrapper implements Response {}
|
||||
abstract interface HttpResponse extends Response {}
|
||||
abstract class ResponseBase implements Response, ServletResponse {}
|
||||
abstract interface HttpServletResponse {}
|
||||
class ResponseFacade implements ServletResponse {}
|
||||
|
||||
abstract interface ServletResponse {}
|
||||
abstract interface Response {}
|
||||
</fmtcode>
|
||||
<img src="catalina.gif" alt="UML diagram of representative Cataline classes" /><br />
|
||||
</notes>
|
||||
|
||||
|
|
@ -0,0 +1,91 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* @opt edgecolor "yellow"
|
||||
* @opt nodefontname "Times"
|
||||
* @opt bgcolor ".7 .9 1"
|
||||
* @opt nodefillcolor "#a0a0a0"
|
||||
* @opt nodefontsize 14
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions{}
|
||||
|
||||
/**
|
||||
* @opt nodefontname "Helvetica-Bold"
|
||||
* @opt nodefontcolor "white"
|
||||
* @composed - - - Red
|
||||
* @composed - - - Green
|
||||
* @composed - - - Blue
|
||||
* @opt attributes
|
||||
* @opt visibility
|
||||
* @opt types
|
||||
*/
|
||||
class Pixel {
|
||||
private int x, y;
|
||||
public void setColor(ColorValue v) {}
|
||||
}
|
||||
|
||||
/** @opt nodefillcolor red */
|
||||
class Red {}
|
||||
|
||||
/** @opt nodefillcolor green */
|
||||
class Green {}
|
||||
|
||||
/** @opt nodefillcolor blue */
|
||||
class Blue {}
|
||||
|
||||
/** @hidden */
|
||||
class ColorValue{}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="color.gif" alt="UML diagram demonstrating the use of colors" />
|
||||
</td></tr>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
package net.sf.whatever.test;
|
||||
|
||||
/**
|
||||
* @hidden
|
||||
* @opt postfixpackage
|
||||
* @opt edgefontname arialbd
|
||||
* @opt nodefontname arial
|
||||
* @opt nodefontsize 9
|
||||
* @opt nodefontabstract ariali
|
||||
* @opt nodefontclassname arialbd
|
||||
* @opt nodefontclassabstractname arialbi
|
||||
* @opt nodefonttagsize 6
|
||||
* @opt nodefonttagname ariali
|
||||
* @opt nodefontpackagesize 8
|
||||
* @opt operations
|
||||
* @opt attributes
|
||||
* @opt qualify
|
||||
* @opt types
|
||||
*/
|
||||
class UMLOptions{}
|
||||
|
||||
/**
|
||||
* @stereotype base
|
||||
* @tagvalue since 1.0
|
||||
*/
|
||||
abstract class AbstractBase {
|
||||
/** @tagvalue since 1.5 */
|
||||
private int field;
|
||||
public abstract void abstractMethod();
|
||||
public int concreteMethod() { return 1; }
|
||||
}
|
||||
|
||||
/**
|
||||
* @composed 1 has * from.Outer.Space.AlienClass
|
||||
*/
|
||||
class Composite extends AbstractBase {}
|
||||
|
||||
public class Style extends AbstractBase {}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="style.png" alt="UML diagram demonstrating the use of fonts" />
|
||||
</td></tr>
|
||||
</table>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The following was generated by annotating the
|
||||
<a href="https://github.com/istlab/Alitheia-Core/tree/master/alitheia/core/src/main/java/eu/sqooss/service/db">source code</a> of the
|
||||
<a href="https://github.com/istlab/Alitheia-Core/">Alitheia Core</a> project.
|
||||
Georgios Gousios, who created it, wrote:
|
||||
<blockquote>
|
||||
<p>
|
||||
I've used UMLgraph to generate an E-R diagram out of the DAOs we use in Alitheia Core. I've just annotated a few classes with @assoc tags, removed the super class DAObject from all entities with sed, did some tweaking by hand in the .dot output, et voila, an E-R depicting almost 30 classes in less than 30 minutes!
|
||||
</p>
|
||||
</blockquote>
|
||||
<p />
|
||||
<img src="er-sqo-oss.png" alt="UML diagram showing an entity relationship diagram" />
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,35 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* Attribute and operation visility
|
||||
* UML User Guide p. 123
|
||||
*
|
||||
* @opt operations
|
||||
* @opt attributes
|
||||
* @opt types
|
||||
* @opt visibility
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/** @hidden */
|
||||
class Tool {}
|
||||
|
||||
class Toolbar {
|
||||
protected Tool currentSelection;
|
||||
protected Integer toolCount;
|
||||
public void pickItem(Integer i) {}
|
||||
public void addTool(Tool t) {}
|
||||
public void removeTool(Integer i) {}
|
||||
public Tool getTool() {}
|
||||
protected void checkOrphans() {}
|
||||
private void compact() {}
|
||||
}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="vis.gif" alt="UML diagram showing attribute and operation visility" />
|
||||
</td></tr></table>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,37 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
/*
|
||||
* Generalisation
|
||||
* UML User Guide p. 141
|
||||
*/
|
||||
|
||||
/* Basic categorisations */
|
||||
class Asset {}
|
||||
class InterestBearingItem {}
|
||||
class InsurableItem {}
|
||||
|
||||
/* Asset types */
|
||||
/**
|
||||
* @extends InsurableItem
|
||||
* @extends InterestBearingItem
|
||||
*/
|
||||
class BankAccount extends Asset {}
|
||||
/** @extends InsurableItem */
|
||||
class RealEstate extends Asset {}
|
||||
class Security extends Asset {}
|
||||
|
||||
/* Securities */
|
||||
class Stock extends Security {}
|
||||
class Bond extends Security {}
|
||||
|
||||
/* Bank accounts */
|
||||
class CheckingAccount extends BankAccount {}
|
||||
class SavingsAccount extends BankAccount {}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="general.gif" alt="UML diagram showing generalization relationships" />
|
||||
</td></tr></table>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,48 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* @opt inferrel
|
||||
* @opt collpackages java.util.*
|
||||
* @opt inferdep
|
||||
* @opt inferdepinpackage
|
||||
* @opt hide java.*
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
class Person {
|
||||
House[] houses;
|
||||
List<Dog> dogs;
|
||||
|
||||
public Room getFavouriteRoom(House house) {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @opt inferreltype composed
|
||||
*/
|
||||
class House {
|
||||
Map<String, Room> nameRoomMap;
|
||||
}
|
||||
|
||||
class Room {}
|
||||
|
||||
class Dog {
|
||||
Person owner;
|
||||
}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="infer.png" alt="UML diagram with relationship inference" />
|
||||
</td></tr></table>
|
||||
|
||||
<p/>In this diagram we enabled both relationship and dependency inference.<br/>
|
||||
To make sure Person.dogs and Person.friends are interpreted as one to many relationship
|
||||
the <code>collpackage</code> option has to be specified.
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,123 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
Vadim Nasardinov noted that an advantage of UMLGraph over many
|
||||
GUI-oriented UML drawing tools is the ability
|
||||
to generate different views of a diagram
|
||||
from the same source description.
|
||||
The following two diagrams were generated from the same source;
|
||||
a Makefile illustrates a way to organize this process.
|
||||
<h2>Class Overview</h2>
|
||||
<img src="Root-small.png" alt="Class overview" />
|
||||
|
||||
<h2>Detailed Class View</h2>
|
||||
<img src="Root.png" alt="Detailed class view" />
|
||||
|
||||
<h2>Java Description</h2>
|
||||
<fmtcode ext="java">
|
||||
// Author: Vadim Nasardinov
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @assoc "1..1" - "0..n" Adapter
|
||||
* @assoc "" - "0..n" ObjectType
|
||||
* @assoc "" - "0..n" ObjectMap
|
||||
* @assoc "" - "0..n" Table
|
||||
* @assoc "" - "0..n" DataOperation
|
||||
**/
|
||||
class Root {
|
||||
private Map m_adapters;
|
||||
private List m_types;
|
||||
private List m_maps;
|
||||
private List m_tables;
|
||||
private List m_ops;
|
||||
|
||||
public Adapter getAdapter(Class klass) {}
|
||||
}
|
||||
|
||||
class Adapter {
|
||||
public Root getRoot();
|
||||
}
|
||||
|
||||
abstract class Element {
|
||||
Root getRoot() {}
|
||||
}
|
||||
|
||||
class ObjectType extends Element {}
|
||||
|
||||
/**
|
||||
* @has "1..1" - "1..1" ObjectType
|
||||
**/
|
||||
class ObjectMap extends Element {
|
||||
private ObjectType m_type;
|
||||
}
|
||||
|
||||
class Table extends Element {}
|
||||
|
||||
class DataOperation extends Element {}
|
||||
</fmtcode>
|
||||
<h2>Makefile</h2>
|
||||
<fmtcode ext="mak">
|
||||
# Author: Vadim Nasardinov (vadimn@redhat.com)
|
||||
# Since: 2004-05-26
|
||||
# See: http://www.spinellis.gr/umlgraph/doc/ceg-mv.html
|
||||
|
||||
# Requires: graphviz
|
||||
# Requires: javadoc
|
||||
# Requires: JAVA_HOME/lib/tools.jar
|
||||
|
||||
.PHONY : clean all dot png
|
||||
|
||||
UMLGRAPH := /var/vadim/binaries/UMLGraph-4.8
|
||||
uml_graph := $(UMLGRAPH)/lib/UmlGraph.jar
|
||||
|
||||
java_files := $(shell find diagrams -name *.java)
|
||||
dot_files := $(subst .java,.dot,$(java_files))
|
||||
dot_files := $(foreach dot, $(dot_files), build/$(dot))
|
||||
dot_files += $(subst .dot,-small.dot,$(dot_files))
|
||||
|
||||
png_files := $(subst .dot,.png,$(dot_files))
|
||||
|
||||
jd:=javadoc
|
||||
jd_flags := -docletpath $(uml_graph) -doclet org.umlgraph.doclet.UmlGraph -private
|
||||
|
||||
jd_flags += -nodefontsize 9 -edgefontsize 9
|
||||
jd_flags += -nodefillcolor LemonChiffon
|
||||
detailed_flags := -attributes -operations -types
|
||||
|
||||
all: png
|
||||
|
||||
clean:
|
||||
rm -rf build
|
||||
|
||||
build/%.dot : %.java
|
||||
mkdir -p $(dir $@)
|
||||
$(jd) $(jd_flags) $(detailed_flags) -output $@ $<
|
||||
|
||||
build/%-small.dot : %.java
|
||||
mkdir -p $(dir $@)
|
||||
$(jd) $(jd_flags) -output $@ $<
|
||||
|
||||
%.png : %.dot
|
||||
dot -Nheight=0.2 -Elabelfontcolor=DarkSlateBlue -Elabelfontsize=8 -Tpng -o $@ $<
|
||||
|
||||
build/%.png : %.fig
|
||||
mkdir -p $(dir $@)
|
||||
fig2dev -L png -S 4 $< $@
|
||||
|
||||
dot: $(dot_files)
|
||||
|
||||
png: $(png_files)
|
||||
|
||||
build/%.png : %.png
|
||||
mkdir -p $(dir $@)
|
||||
cp $< $@
|
||||
|
||||
# Example usage:
|
||||
# make debug-java_files
|
||||
# make debug-png_files
|
||||
debug-%:
|
||||
@echo $* is $($*)
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,79 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
/*
|
||||
* Schema model
|
||||
* UML User Guide p. 112
|
||||
*/
|
||||
|
||||
/**
|
||||
* @opt operations
|
||||
* @opt attributes
|
||||
* @opt types
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/* Define some types we use */
|
||||
/** @hidden */
|
||||
class Name {}
|
||||
/** @hidden */
|
||||
class Number {}
|
||||
|
||||
/**
|
||||
* @has 1..* Member * Student
|
||||
* @composed 1..* Has 1..* Department
|
||||
*/
|
||||
class School {
|
||||
Name name;
|
||||
String address;
|
||||
Number phone;
|
||||
void addStudent() {}
|
||||
void removeStudent() {}
|
||||
void getStudent() {}
|
||||
void getAllStudents() {}
|
||||
void addDepartment() {}
|
||||
void removeDepartment() {}
|
||||
void getDepartment() {}
|
||||
void getAllDepartments() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @has 1..* AssignedTo 1..* Instructor
|
||||
* @assoc 1..* - 1..* Course
|
||||
* @assoc 0..* - "0..1 chairperson" Instructor
|
||||
*/
|
||||
class Department {
|
||||
Name name;
|
||||
void addInstructor() {}
|
||||
void removeInstructor() {}
|
||||
void getInstructor() {}
|
||||
void getAllInstructors() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @assoc * Attends * Course
|
||||
*/
|
||||
class Student {
|
||||
Name name;
|
||||
Number studentID;
|
||||
}
|
||||
|
||||
class Course {
|
||||
Name name;
|
||||
Number courseID;
|
||||
}
|
||||
|
||||
/**
|
||||
* @assoc 1..* Teaches * Course
|
||||
*/
|
||||
class Instructor {
|
||||
Name name;
|
||||
}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="schema.gif" alt="UML diagram showing a database scheme model" />
|
||||
</td></tr></table>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,74 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* @hidden
|
||||
* @opt nodefontcolor "blue"
|
||||
*/
|
||||
class UMLNoteOptions{}
|
||||
|
||||
/**
|
||||
* Structural Things
|
||||
* @opt commentname
|
||||
* @note Notes can
|
||||
* be extended to
|
||||
* span multiple lines
|
||||
*/
|
||||
class Structural{}
|
||||
|
||||
/**
|
||||
* spelling.java
|
||||
* @opt shape component
|
||||
* @opt commentname
|
||||
* @note Component
|
||||
*/
|
||||
class Component extends Structural{}
|
||||
|
||||
/** @opt shape node */
|
||||
class Node extends Structural{}
|
||||
|
||||
/**
|
||||
* Chain of
|
||||
* responsibility
|
||||
* @opt shape collaboration
|
||||
* @opt commentname
|
||||
* @note Collaboration
|
||||
*/
|
||||
class Collaboration extends Structural{}
|
||||
|
||||
/**
|
||||
* Place order
|
||||
* @opt shape usecase
|
||||
* @opt commentname
|
||||
* @note Use Case
|
||||
*/
|
||||
class UseCase extends Structural{}
|
||||
|
||||
/**
|
||||
* Business rules
|
||||
* @opt shape package
|
||||
* @opt commentname
|
||||
* @note Package
|
||||
*/
|
||||
class Package{}
|
||||
|
||||
/**
|
||||
* @opt all
|
||||
* @note Class
|
||||
*/
|
||||
class Counter extends Structural {
|
||||
static public int counter;
|
||||
public int getCounter();
|
||||
}
|
||||
|
||||
/**
|
||||
* @opt shape activeclass
|
||||
* @opt all
|
||||
* @note Active Class
|
||||
*/
|
||||
class RunningCounter extends Counter{}
|
||||
|
||||
</fmtcode>
|
||||
<p/>
|
||||
<img src="shapes.gif" alt="UML diagram showing the shapes supported by UMLGraph" />
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="java">
|
||||
/*
|
||||
* Class stereotypes and tagged values
|
||||
* UML User Guide p. 439
|
||||
*/
|
||||
|
||||
/**
|
||||
* @opt attributes
|
||||
* @opt operations
|
||||
* @opt types
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/** @hidden */
|
||||
class Action {}
|
||||
|
||||
/**
|
||||
* @stereotype container
|
||||
* @tagvalue version 3.2
|
||||
*/
|
||||
class ActionQueue {
|
||||
void add(Action a) {};
|
||||
/** @tagvalue version 1.0 */
|
||||
void add(Action a, int n) {};
|
||||
void remove(int n) {};
|
||||
/** @stereotype query */
|
||||
int length() {};
|
||||
/** @stereotype "helper functions" */
|
||||
void reorder() {};
|
||||
}
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="classadd.gif" alt="UML diagram of class stereotypes and tagged values" />
|
||||
</td></tr></table>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,91 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The makefile-based multiple view example can be generated by using internal
|
||||
view support by means of the following sources (note the use of UmlOptions
|
||||
to set the common appearance options, and the views to generate multiple
|
||||
diagrams at different detail level).
|
||||
|
||||
<fmtcode ext="java">
|
||||
// Author: Vadim Nasardinov
|
||||
// Author: Andrea Aime
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @assoc "1..1" - "0..n" Adapter
|
||||
* @assoc "" - "0..n" ObjectType
|
||||
* @assoc "" - "0..n" ObjectMap
|
||||
* @assoc "" - "0..n" Table
|
||||
* @assoc "" - "0..n" DataOperation
|
||||
**/
|
||||
class Root {
|
||||
private Map m_adapters;
|
||||
private List m_types;
|
||||
private List m_maps;
|
||||
private List m_tables;
|
||||
private List m_ops;
|
||||
|
||||
public Adapter getAdapter(Class klass) {}
|
||||
}
|
||||
|
||||
class Adapter {
|
||||
public Root getRoot();
|
||||
}
|
||||
|
||||
abstract class Element {
|
||||
Root getRoot() {}
|
||||
}
|
||||
|
||||
class ObjectType extends Element {}
|
||||
|
||||
/**
|
||||
* @has "1..1" - "1..1" ObjectType
|
||||
**/
|
||||
class ObjectMap extends Element {
|
||||
private ObjectType m_type;
|
||||
}
|
||||
|
||||
class Table extends Element {}
|
||||
|
||||
class DataOperation extends Element {}
|
||||
|
||||
/**
|
||||
* @hidden
|
||||
* @opt nodefontname luxisr
|
||||
* @opt nodefontabstractname luxisri
|
||||
* @opt edgefontname luxisr
|
||||
* @opt nodefontsize 8
|
||||
* @opt edgefontsize 8
|
||||
* @opt nodefillcolor LemonChiffon
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/**
|
||||
* @view
|
||||
* @opt attributes
|
||||
* @opt operations
|
||||
*/
|
||||
class DetailedView {}
|
||||
|
||||
/**
|
||||
* @view
|
||||
*/
|
||||
class Overview {}
|
||||
</fmtcode>
|
||||
|
||||
and by invoking the following commands (assuming UmlGraph.jar is in the
|
||||
current directory):
|
||||
|
||||
<fmtcode ext="bat">
|
||||
javadoc -doclet org.umlgraph.doclet.UmlGraph -private -docletpath UmlGraph.jar -views RootViews.java
|
||||
dot -Tpng -o root-small.png Overview.dot
|
||||
dot -Tpng -o root.png DetailedView.dot
|
||||
</fmtcode>
|
||||
|
||||
The javadoc invocation asks UMLGraph to build a diagram for every view (-views)
|
||||
contained in the RootViews.java file. Notably, there's no class RootViews
|
||||
in the source file: this is not needed to make javadoc work on a single
|
||||
class. Respecting the java rules for file and class naming is anyway advised
|
||||
in any real situation.
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,108 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
Views are especially interesting in big projects, since they allow to
|
||||
generate package specific diagrams and overview diagrams in a quick and
|
||||
consistent way. <br/>
|
||||
|
||||
As an example we include a few class diagrams that have been generated
|
||||
from the <a href="http://jakarta.apache.org/commons/dbcp">DBCP connection pool</a>,
|
||||
without altering the sources and using association and dependency inference
|
||||
instead.<br/>
|
||||
|
||||
The base view defines commons options, in particular the use of inference,
|
||||
common class coloring and class visibility (in particular, we hide the
|
||||
java runtime classes, with the exclusion of a few java.sql classes).
|
||||
To avoid visual clutter, we have first shown the java.sql package contents, and
|
||||
then hid selected classes.
|
||||
The <code>Overview</code> view provides a full view of the DBCP package,
|
||||
generating quite a big diagram (click on the diagram to show a full size version).<br/>
|
||||
|
||||
<fmtcode ext="java">
|
||||
package org.apache.commons;
|
||||
|
||||
/**
|
||||
* @view
|
||||
* @opt inferrel
|
||||
* @opt inferdep
|
||||
* @opt useimports
|
||||
*
|
||||
* @match class .*
|
||||
* @opt nodefillcolor LightGray
|
||||
*
|
||||
* @match class org.apache.commons.*
|
||||
* @opt nodefillcolor PaleGreen
|
||||
*
|
||||
* @match class org.apache.commons.dbcp.*
|
||||
* @opt nodefillcolor LemonChiffon
|
||||
*
|
||||
* @match class java.*|org.xml.*
|
||||
* @opt hide
|
||||
*
|
||||
* @match class java.sql.*
|
||||
* @opt !hide
|
||||
*
|
||||
* @match class java.sql\.(Ref|Time|Timestamp|Array|Date|Time|Clob|Blob|SQLException|.*MetaData.*|SQLWarning)
|
||||
* @opt hide
|
||||
*/
|
||||
public abstract class BaseView {
|
||||
}
|
||||
|
||||
/**
|
||||
* @view
|
||||
*/
|
||||
public class Overview extends BaseView {
|
||||
}
|
||||
</fmtcode>
|
||||
|
||||
<a href="dbcp-overview-full.png"><img src="dbcp-overview-small.png" alt="Overview"/></a>
|
||||
|
||||
<p/>The <code>CommonsDbcp</code> view concentrates on the content of org.apache.commons.dbcp
|
||||
package, hiding other packages and subpackages available in the sources
|
||||
(click on the diagram to show a full size version).<br/>
|
||||
|
||||
<fmtcode ext="java">
|
||||
package org.apache.commons;
|
||||
|
||||
/**
|
||||
* @view
|
||||
*
|
||||
* @match class org.apache.commons.*
|
||||
* @opt hide
|
||||
*
|
||||
* @match class org.apache.commons.dbcp..*
|
||||
* @opt !hide
|
||||
*
|
||||
* @match class org.apache.commons.dbcp..*\..*
|
||||
* @opt hide
|
||||
*/
|
||||
public class CommonsDbcp extends BaseView {}
|
||||
</fmtcode>
|
||||
|
||||
<a href="dbcp-full.png"><img src="dbcp-small.png" alt="Overview"/></a>
|
||||
|
||||
<p/>Finally, the <code>Statement</code> view shows only the Statement related
|
||||
classes and their dependencies.
|
||||
|
||||
<fmtcode ext="java">
|
||||
package org.apache.commons;
|
||||
|
||||
/**
|
||||
* @view
|
||||
*
|
||||
* @match class org.apache.commons.*
|
||||
* @opt hide
|
||||
*
|
||||
* @match class org.apache.commons.dbcp\..*Statement.*
|
||||
* @opt !hide
|
||||
*
|
||||
* @match class org.apache.commons.dbcp..*\..*
|
||||
* @opt hide
|
||||
*/
|
||||
public class Statement extends BaseView {
|
||||
}
|
||||
</fmtcode>
|
||||
|
||||
<img src="dbcp-statement.png" alt="Statement"/>
|
||||
|
||||
</notes>
|
||||
|
||||
|
|
@ -0,0 +1,84 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
Views are special classes that allow the generation of a custom class
|
||||
diagram based on a set of diagram global options and a set of option
|
||||
overrides for classes matching user specified conditions.
|
||||
|
||||
The <code>@view</code> tag, marks a class used to describe a single class diagram.
|
||||
The general syntax for defining a view is:
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* @view
|
||||
* @opt viewOption1
|
||||
* @opt viewOption2
|
||||
* ...
|
||||
* @match matchtype regularExpression
|
||||
* @opt option1.1 [argument]
|
||||
* @opt option1.2 [argument]
|
||||
* ...
|
||||
* @match matchtype regularExpression
|
||||
* @opt option2.1 [argument]
|
||||
* @opt option2.2 [argument]
|
||||
* ...
|
||||
*/
|
||||
</fmtcode>
|
||||
|
||||
The @match tags allow to specify option overrides for classes that satisfy
|
||||
the match condition. The match types are:
|
||||
<ul>
|
||||
<li><i>class</i>: matches class names using a regular expression.</li>
|
||||
<li><i>subclass</i>: first looks for the base classes using the specified
|
||||
regular expression, then matches the whole inheritance hierarchy of these
|
||||
classes. The base classes are included in the match as well.</li>
|
||||
<li><i>interface</i>: first looks for interfaces using the specified
|
||||
regular expression, then matches every class that implements them,
|
||||
either directly or indirectly. The interfaces are included in the match
|
||||
as well.</li>
|
||||
<li><i>context</i>: looks for classes using a regular expression,
|
||||
then matches every class that's directly connected to them.</li>
|
||||
</ul>
|
||||
|
||||
<p/>The <i>class</i> match type is intended to be used with a regular
|
||||
expression, the others are usually performed against a class/interface
|
||||
name rather than a real regular expression, but the syntax allows for
|
||||
a regular expression to retain some flexibility (for example, a regular
|
||||
expression can be used to match multiple classes, as in "(A|B|C)").<br/>
|
||||
Refer to the <a href="http://java.sun.com/j2se/1.5.0/docs/api/java/util/regex/Pattern.html">Pattern</a>
|
||||
API docs for details on regular expression specifications.
|
||||
|
||||
<p/>Matches will be evaluted in the order of specification, each applying
|
||||
its overrides to the current options. This means that options for a
|
||||
specific class are built in the following order, where each item overrides
|
||||
only the options specified locally, leaving the other options intact:
|
||||
<ul>
|
||||
<li>Command line options</li>
|
||||
<li>UMLOptions options</li>
|
||||
<li>View options</li>
|
||||
<li>Match overrides, in the order they are specified, and only for
|
||||
the classes that satisfy the match conditions</li>
|
||||
</ul>
|
||||
|
||||
<p/>Each view will generate a .dot file whose name is the name of the view,
|
||||
unless the "output" option is specified to override it. Along with the "-views"
|
||||
parameter on the command line, this allows for multiple views to be generated
|
||||
in a single doclet invocation.
|
||||
|
||||
<h2>View inheritance</h2>
|
||||
|
||||
View classes can inherit from other view classes, allowing views to
|
||||
share a set of common matches. The standard java inheritance mechanism
|
||||
is used to specify inheritance.<br/>
|
||||
Abstract view classes won't be used to generate diagrams, the common
|
||||
idiom is to declare a base abstract view to share common options and
|
||||
overrides, and have concrete view classes that extend for diagram generation.
|
||||
|
||||
<p/>When using view inheritance the option building order is:
|
||||
<ul>
|
||||
<li>Command line options</li>
|
||||
<li>UMLOptions options</li>
|
||||
<li>Base view options</li>
|
||||
<li>View options</li>
|
||||
<li>Base view match overrides</li>
|
||||
<li>View match overrides</li>
|
||||
</ul>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
|
||||
/**
|
||||
* @opt nodefillcolor ".13 .9 1"
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions{}
|
||||
|
||||
class Person {
|
||||
String Name;
|
||||
}
|
||||
|
||||
class Employee extends Person {}
|
||||
|
||||
class Client extends Person {}
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
/*
|
||||
* Class stereotypes and tagged values
|
||||
* UML User Guide p. 439
|
||||
*/
|
||||
|
||||
/**
|
||||
* @opt attributes
|
||||
* @opt operations
|
||||
* @opt types
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/** @hidden */
|
||||
class Action {}
|
||||
|
||||
/**
|
||||
* @stereotype container
|
||||
* @tagvalue version 3.2
|
||||
*/
|
||||
class ActionQueue {
|
||||
void add(Action a) {};
|
||||
/** @tagvalue version 1.0 */
|
||||
void add(Action a, int n) {};
|
||||
void remove(int n) {};
|
||||
/** @stereotype query */
|
||||
int length() {};
|
||||
/** @stereotype "helper functions" */
|
||||
void reorder() {};
|
||||
}
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
|
||||
/**
|
||||
* @opt edgecolor "yellow"
|
||||
* @opt nodefontname "Times"
|
||||
* @opt bgcolor ".7 .9 1"
|
||||
* @opt nodefillcolor "#a0a0a0"
|
||||
* @opt nodefontsize 14
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions{}
|
||||
|
||||
/**
|
||||
* @opt nodefontname "Arial"
|
||||
* @opt nodefontcolor "white"
|
||||
* @composed - - - Red
|
||||
* @composed - - - Green
|
||||
* @composed - - - Blue
|
||||
* @opt attributes
|
||||
* @opt operations
|
||||
* @opt visibility
|
||||
* @opt types
|
||||
*/
|
||||
class Pixel {
|
||||
private int x, y;
|
||||
public void setColor(ColorValue v) {}
|
||||
}
|
||||
|
||||
/** @opt nodefillcolor red */
|
||||
class Red {}
|
||||
|
||||
/** @opt nodefillcolor green */
|
||||
class Green {}
|
||||
|
||||
/** @opt nodefillcolor blue */
|
||||
class Blue {}
|
||||
|
||||
/** @hidden */
|
||||
class ColorValue{}
|
||||
|
After Width: | Height: | Size: 60 KiB |
|
After Width: | Height: | Size: 91 KiB |
|
After Width: | Height: | Size: 57 KiB |
|
After Width: | Height: | Size: 66 KiB |
|
After Width: | Height: | Size: 8.6 KiB |
|
|
@ -0,0 +1,45 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
Here are other programs or efforts that build on UMLGraph's
|
||||
code or ideas.
|
||||
<ul>
|
||||
<li> <a href="http://maven-plugins.sourceforge.net/maven-dotuml-plugin/">Dotuml</a>
|
||||
integrates UMLGraph into <a href="http://maven.apache.org/">Maven</a>.</li>
|
||||
<li> The <a href="http://www.primordion.com/Xholon/index.html">Xholon</a>
|
||||
framework for building loosely-organized systems
|
||||
captures object interactions at runtime,
|
||||
and creates UML 2.0 sequence diagrams using UMLGraph.</li>
|
||||
<li> <a href="http://phpcallgraph.sourceforge.net/">phpCallGraph</a>
|
||||
can output its analysis in UMLGraph format, allowing the
|
||||
automatic production of UML sequence diagrams from PHP code.</li>
|
||||
<li> <a href="http://lightuml.sourceforge.net/">LightUML</a>
|
||||
integrates UMLGraph into <a href="http://www.eclipse.org">Eclipse</a>.</li>
|
||||
<li> <a href="http://ruby-uml.rubyforge.org/">ruby-uml</a>
|
||||
traces aspects of an application
|
||||
using UMLGraph to generate sequence and class diagrams.</li>
|
||||
<li> The Politecnico Di Torino SoftEng group has extended UMLGraph into
|
||||
the <a href="http://softeng.polito.it/projects/XUG/">XUG</a>
|
||||
reverse engineering tool.</li>
|
||||
<li> Adam Feuer's
|
||||
<a href="http://www.python.org/pypi/PyUMLGraph">PyUMLGraph</a>
|
||||
system applies the concept to Python programs.</li>
|
||||
<li> The <a href="http://moinmo.in/">MoinMoin</a> Wiki engine
|
||||
uses UMLGraph to provide
|
||||
<a href="http://moinmo.in/ParserMarket/UmlSequence">support for UML sequence diagrams</a>.</li>
|
||||
<li> The <a href="http://jbrugge.com/glean/">Glean</a>
|
||||
framework for generating feedback on a team's source code
|
||||
supports the scripting of UMLGraph.</li>
|
||||
<li> W. Goesgens has <a href="http://wiki.ioslo.net/dokuwiki/graphviz#plugging_umlgraph_infront_of_graphviz">documented here</a> a way to use
|
||||
UMLGraph diagrams in
|
||||
<a href="http://wiki.splitbrain.org/wiki:dokuwiki">DokuWiki</a>.</li>
|
||||
<li> Mykhaylo Sorochan has built on top of UMLGraph a
|
||||
<a href="http://macroexpand.org/doku.php/articles:uml-sequence-diagram-dsl-txl:start">higher-level domain-specific language for specifying UML sequence diagrams</a>.</li>
|
||||
<li>
|
||||
<a href="http://sketchlet.sourceforge.net/">Sketchlet</a> is using UMLGraph as a widget plugin. You can find a video about the Sketchlet UMLGraph widget usage at <a href="http://www.youtube.com/watch?v=H6lrgSYyzE0">http://www.youtube.com/watch?v=H6lrgSYyzE0</a>.
|
||||
</li>
|
||||
<li>
|
||||
<a href="http://argouml-graphviz.tigris.org/">argouml-graphviz</a>
|
||||
is a plugin to let ArgoUML generate graphviz files.
|
||||
</li>
|
||||
</ul>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,58 @@
|
|||
# UML Distilled: Figure 5-2 p. 70
|
||||
#
|
||||
#
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
boxwid = 1.3;
|
||||
|
||||
# Define the objects
|
||||
pobject(X);
|
||||
pobject(T);
|
||||
pobject(C);
|
||||
pobject(A1);
|
||||
pobject(A2);
|
||||
|
||||
# Message sequences
|
||||
cmessage(X,T,"a: Transaction");
|
||||
active(T);
|
||||
async();
|
||||
cmessage(T,C,"a: TransCoord");
|
||||
inactive(T);
|
||||
active(C);
|
||||
cmessage(C,A1,"a1: TransCheck");
|
||||
active(A1);
|
||||
cmessage(C,A2,"a2: TransCheck");
|
||||
active(A2);
|
||||
message(A1,C,"ok");
|
||||
sync();
|
||||
step();
|
||||
active(C);
|
||||
message(C,C,"all done?");
|
||||
inactive(C);
|
||||
async();
|
||||
step();
|
||||
delete(A1);
|
||||
inactive(C);
|
||||
step();
|
||||
message(A2,C,"ok");
|
||||
active(C);
|
||||
sync();
|
||||
step();
|
||||
active(C);
|
||||
message(C,C,"all done?");
|
||||
inactive(C);
|
||||
async();
|
||||
step();
|
||||
delete(A2);
|
||||
message(C,T,"beValid");
|
||||
inactive(C);
|
||||
active(T);
|
||||
step();
|
||||
|
||||
complete(T);
|
||||
complete(C);
|
||||
|
||||
.PE
|
||||
|
|
@ -0,0 +1,67 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The following diagram, based on the diagram appearing on p. 70 of
|
||||
UML Distilled, contains self calls, object activation,
|
||||
self-deleted objects, and asynchronous messages.
|
||||
<h2>Diagram</h2>
|
||||
<img src="dist-52.gif" alt="UML Distilled: Concurrent processes and activations" />
|
||||
<h2>Diagram Source Code</h2>
|
||||
<fmtcode ext="pic">
|
||||
# UML Distilled: Figure 5-2 p. 70
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
boxwid = 1.3;
|
||||
|
||||
# Define the objects
|
||||
pobject(X);
|
||||
pobject(T);
|
||||
pobject(C);
|
||||
pobject(A1);
|
||||
pobject(A2);
|
||||
|
||||
# Message sequences
|
||||
cmessage(X,T,"a: Transaction");
|
||||
active(T);
|
||||
async();
|
||||
cmessage(T,C,"a: TransCoord");
|
||||
inactive(T);
|
||||
active(C);
|
||||
cmessage(C,A1,"a1: TransCheck");
|
||||
active(A1);
|
||||
cmessage(C,A2,"a2: TransCheck");
|
||||
active(A2);
|
||||
message(A1,C,"ok");
|
||||
sync();
|
||||
step();
|
||||
active(C);
|
||||
message(C,C,"all done?");
|
||||
inactive(C);
|
||||
async();
|
||||
step();
|
||||
delete(A1);
|
||||
inactive(C);
|
||||
step();
|
||||
message(A2,C,"ok");
|
||||
active(C);
|
||||
sync();
|
||||
step();
|
||||
active(C);
|
||||
message(C,C,"all done?");
|
||||
inactive(C);
|
||||
async();
|
||||
step();
|
||||
delete(A2);
|
||||
message(C,T,"beValid");
|
||||
inactive(C);
|
||||
active(T);
|
||||
step();
|
||||
|
||||
complete(T);
|
||||
complete(C);
|
||||
|
||||
.PE
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,67 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The following diagram, illustrates the operating system calls of
|
||||
a typical DNS query.
|
||||
It will appear in the book
|
||||
<a href="http://www.spinellis.gr/codequality">Code Quality: The Open Source Perspective</a> (Addison-Wesley 2006).
|
||||
The diagram was the original motivation behind the UMLGraph sequence diagram
|
||||
drawing facility.
|
||||
<h2>Diagram</h2>
|
||||
<img src="dnsq.gif" alt="DNS Query Messages" />
|
||||
<h2>Diagram Source Code</h2>
|
||||
<fmtcode ext="pic">
|
||||
#/usr/bin/pic2plot -Tps
|
||||
#
|
||||
# Run as pic filename | groff | ps2eps
|
||||
#
|
||||
# DNS query collaboration diagram
|
||||
#
|
||||
#
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
boxwid = 1.3;
|
||||
|
||||
# Define the objects
|
||||
object(B,":Web Browser");
|
||||
object(W,":Workstation Kernel");
|
||||
object(S,":Server Kernel");
|
||||
object(D,":DNS Server");
|
||||
step();
|
||||
|
||||
# Message sequences
|
||||
active(B);
|
||||
active(D);
|
||||
active(W);
|
||||
active(S);
|
||||
message(D,S,"select");
|
||||
inactive(D);
|
||||
message(B,W,"socket");
|
||||
message(B,W,"connect");
|
||||
message(B,W,"sendto");
|
||||
message(W,W,"send packet");
|
||||
message(W,S,"DNS A query");
|
||||
message(B,W,"recvfrom");
|
||||
inactive(B);
|
||||
message(S,S,"receive packet");
|
||||
rmessage(S,D,"select returns");
|
||||
active(D);
|
||||
message(D,S,"recvfrom");
|
||||
message(D,S,"sendto");
|
||||
message(S,S,"send packet");
|
||||
message(S,W,"DNS A reply");
|
||||
message(W,W,"receive packet");
|
||||
rmessage(W,B,"recvfrom returns");
|
||||
active(B);
|
||||
message(B,W,"close");
|
||||
|
||||
complete(B);
|
||||
complete(W);
|
||||
complete(S);
|
||||
complete(D);
|
||||
|
||||
.PE
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,53 @@
|
|||
#/usr/bin/pic2plot -Tps
|
||||
#
|
||||
# Run as pic filename | groff | ps2eps
|
||||
#
|
||||
# DNS query collaboration diagram
|
||||
#
|
||||
#
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
boxwid = 1.3;
|
||||
|
||||
# Define the objects
|
||||
object(B,":Web Browser");
|
||||
object(W,":Workstation Kernel");
|
||||
object(S,":Server Kernel");
|
||||
object(D,":DNS Server");
|
||||
step();
|
||||
|
||||
# Message sequences
|
||||
active(B);
|
||||
active(D);
|
||||
active(W);
|
||||
active(S);
|
||||
message(D,S,"select");
|
||||
inactive(D);
|
||||
message(B,W,"socket");
|
||||
message(B,W,"connect");
|
||||
message(B,W,"sendto");
|
||||
message(W,W,"send packet");
|
||||
message(W,S,"DNS A query");
|
||||
message(B,W,"recvfrom");
|
||||
inactive(B);
|
||||
message(S,S,"receive packet");
|
||||
rmessage(S,D,"select returns");
|
||||
active(D);
|
||||
message(D,S,"recvfrom");
|
||||
message(D,S,"sendto");
|
||||
message(S,S,"send packet");
|
||||
message(S,W,"DNS A reply");
|
||||
message(W,W,"receive packet");
|
||||
rmessage(W,B,"recvfrom returns");
|
||||
active(B);
|
||||
message(B,W,"close");
|
||||
|
||||
complete(B);
|
||||
complete(W);
|
||||
complete(S);
|
||||
complete(D);
|
||||
|
||||
.PE
|
||||
|
After Width: | Height: | Size: 103 KiB |
|
|
@ -0,0 +1,236 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
|
||||
<!--
|
||||
To update the table of contents execute the following vim command from a register
|
||||
/^<h2>Contents
jjma/ul>
kmb/^$
"qyy:g/^<h2><a name/s,<h2><a name="\([^>]*\)>\(.*\)</a></h2>,<li> <a href="\#\1>\2</a></li>,|y Q|u
'ad'b"qP
|
||||
-->
|
||||
|
||||
<h2>Contents</h2>
|
||||
<ul>
|
||||
|
||||
<li> <a href="#cmdline">What is the command line sequence to generate a UMLGraph class diagram?</a></li>
|
||||
<li> <a href="#utfsvg">Why are the SVG diagrams dot generates malformed?</a></li>
|
||||
<li> <a href="#antialias">How can I improve the quality of the bitmap images I generate?</a></li>
|
||||
<li> <a href="#layout">How can I improve the layout of my class diagrams?</a></li>
|
||||
<li> <a href="#mclass">A class appears multiple times in a class diagram. Why?</a></li>
|
||||
<li> <a href="#static">Shouldn't static fields appear underlined?</a></li>
|
||||
<li> <a href="#winpic">Where can I find a <em>pic2plot</em> executable for Windows?</a></li>
|
||||
<li> <a href="#cr">Under Windows the output of <em>pic2plot</em> appears empty. Why?</a></li>
|
||||
<li> <a href="#maven">I have a problem with Maven's Dotuml plugin. Can you help me?</a></li>
|
||||
<li> <a href="#autopic">How can I make the UMLGraph doclet generate sequence diagrams?</a></li>
|
||||
<li> <a href="#unnamed">Why do the options specified in the <code>UMLOptions</code> class stop working, when I pass the <code>packagenames</code> option to <em>javadoc</em>?</a></li>
|
||||
<li> <a href="#tiger">Why doesn't UMLGraph run under Mac OS X?</a></li>
|
||||
<li> <a href="#cpp">Can I create UML class diagrams from C++ code?</a></li>
|
||||
<li> <a href="#ClassCastException">How can I get around a UMLGraphDoc crash with a ClassCastException?</a></li>
|
||||
<li> <a href="#license">Under what license is UMLGraph distributed?</a></li>
|
||||
<li> <a href="#classnotfound">Why do I get an exception java.lang.NoClassDefFoundError: com/sun/tools/javadoc/Main?</a></li>
|
||||
<li> <a href="#truncxml">How can I prevent clipped SVG images in sequence diagrams?</a></li>
|
||||
<li> <a href="#private">How can I instruct UMLGraph to include private fields in its output?</a></li>
|
||||
</ul>
|
||||
|
||||
<h2><a name="cmdline">What is the command line sequence to generate a UMLGraph class diagram?</a></h2>
|
||||
Assuming that you diagram's description is in the file Diag.java,
|
||||
issue the command:
|
||||
<fmtcode ext="sh">
|
||||
umlgraph Diag png
|
||||
java -jar path-to/UmlGraph.jar -package -output - Diag.java | dot -Tpng -oDiag.png Diag.dot
|
||||
</fmtcode>
|
||||
In the above you can change <code>png</code> to another file format,
|
||||
and add more UMLGraph switches at the end of the line.
|
||||
<p />
|
||||
|
||||
|
||||
<h2><a name="utfsvg">Why are the SVG diagrams dot generates malformed?</a></h2>
|
||||
UMLGraph uses guillemot characters for representing the angle brackets around
|
||||
stereotypes, as in «interface».
|
||||
By default these are encoded as ISO-8859-1 characters, which are illegal
|
||||
in the UTF-8 output that dot generates for SVG.
|
||||
When using dot to generate SVG output, you should also specify
|
||||
<code>-outputencoding utf8</code> to UMLGraph.
|
||||
|
||||
<h2><a name="antialias">How can I improve the quality of the bitmap images I generate?</a></h2>
|
||||
|
||||
Both
|
||||
<em>dot</em> and
|
||||
<em>pic2plot</em> can directly produce bitmap images in
|
||||
formats like GIF, PNG and PNM.
|
||||
However, if you want to produce presentation-quality output
|
||||
the a vector output format like Postscript or SVG is preferable.
|
||||
If you do require a bitmap format, it might be worth to create
|
||||
it at a higher resolution from a Postscript image, and then downsample it.
|
||||
This procedure (used for the diagrams appearing on the UMLGraph web site)
|
||||
will create an antialiased image of a higher quality than what the default
|
||||
bitmap output options produce.
|
||||
The following pipeline is an example of how you can achieve this
|
||||
effect:
|
||||
<fmtcode ext="sh">
|
||||
dot -Tps FILENAME.dot |
|
||||
gs -q -r360 -dNOPAUSE -sDEVICE=pnm -sOutputFile=- - -c quit |
|
||||
pnmcrop |
|
||||
pnmscale 0.25 |
|
||||
ppmtogif >FILENAME.gif
|
||||
</fmtcode>
|
||||
(David Griffiths reports that he had to add to the <em>gs</em> command
|
||||
<code>-sPAPERSIZE=a4</code> or
|
||||
<code>-dDEVICEHEIGHTPOINTS=1000</code> to avoid getting
|
||||
his results chopped-off.)
|
||||
|
||||
<p />
|
||||
One other possibility for converting the sequence diagram into Postscript
|
||||
is to pass it through <em>pic</em> and <em>groff</em>.
|
||||
Tools like <em>ps2epsi</em> and <em>ps2eps</em> can then be used to
|
||||
convert the Postscript into encapsulated Postscript.
|
||||
Of course, <em>groff</em> users will just use the <em>pic</em>
|
||||
program as part of their processing pipeline.
|
||||
|
||||
<h2><a name="layout">How can I improve the layout of my class diagrams?</a></h2>
|
||||
Try manipulating the <em>dot</em> parameters ratio, minlen, ranksep, and
|
||||
nodesep.
|
||||
For example, Arnaud Rogues recommends running <em>dot</em> with
|
||||
command-line arguments as follows.
|
||||
<fmtcode ext="sh">
|
||||
dot -Gratio=0.7 -Eminlen=2
|
||||
</fmtcode>
|
||||
|
||||
<h2><a name="mclass">A class appears multiple times in a class diagram. Why?</a></h2>
|
||||
Most probably your class diagram uses packages, and you are not
|
||||
qualifying the classes with the respective package names in the
|
||||
tags you use.
|
||||
The tags are not smart enough to do the package resolution,
|
||||
so you will have to prepend the package name to the class,
|
||||
or avoid using packages.
|
||||
<p />
|
||||
<h3>Problematic Specification</h3>
|
||||
<fmtcode ext="java">
|
||||
package test;
|
||||
abstract class AbstractNode {}
|
||||
/** @composed 1 has * AbstractNode */
|
||||
class InnerNode extends AbstractNode {}
|
||||
class Leaf extends AbstractNode {}
|
||||
</fmtcode>
|
||||
<h3>First Approach: Class Name Qualified with the Package</h3>
|
||||
<fmtcode ext="java">
|
||||
package test;
|
||||
abstract class AbstractNode {}
|
||||
/** @composed 1 has * test.AbstractNode */
|
||||
class InnerNode extends AbstractNode {}
|
||||
class Leaf extends AbstractNode {}
|
||||
</fmtcode>
|
||||
<h3>Second Approach: No Package Specification</h3>
|
||||
<fmtcode ext="java">
|
||||
abstract class AbstractNode {}
|
||||
/** @composed 1 has * test.AbstractNode */
|
||||
class InnerNode extends AbstractNode {}
|
||||
class Leaf extends AbstractNode {}
|
||||
</fmtcode>
|
||||
|
||||
<h2><a name="static">Shouldn't static fields appear underlined?</a></h2>
|
||||
Yes they should.
|
||||
Unfortunately, <em>dot</em> does not (yet) support a way to underline
|
||||
single labels, and thus <em>UMLGraph</em> can not show the static fields
|
||||
underlined.
|
||||
|
||||
|
||||
<h2><a name="winpic">Where can I find a <em>pic2plot</em> executable for Windows?</a></h2>
|
||||
A port of <em>pic2plot</em> for Windows can be found in
|
||||
GNU PlotUtils, which is part of the
|
||||
<a href="http://gnuwin32.sourceforge.net/packages.html">GnuWin32</a>
|
||||
project.
|
||||
|
||||
<h2><a name="cr">Under Windows the output of <em>pic2plot</em> appears empty. Why?</a></h2>
|
||||
On Windows platforms note that the current version of
|
||||
<em>pic2plot</em> appears to be very picky about carriage return (CR - \r)
|
||||
characters (by default, CR is part of the platform's end of line sequence)
|
||||
appearing in its input file.
|
||||
Therefore, you will probably want to instruct your editor to create
|
||||
Unix-style files, or filter the files to remove the carriage return
|
||||
characters.
|
||||
The following Perl invocation is such a filter:
|
||||
<fmtcode ext="sh">
|
||||
perl -p -e "BEGIN {binmode(STDOUT);} s/\r//"
|
||||
</fmtcode>
|
||||
In addition, <em>pic2plot</em> appears to require that the last input file
|
||||
be properly terminated (with a newline).
|
||||
Apparently, some Windows editors may leave the last line unterminated,
|
||||
so if your editor is in this category it may be safer to add a blank line
|
||||
in the end.
|
||||
|
||||
<h2><a name="maven">I have a problem with Maven's Dotuml plugin. Can you help me?</a></h2>
|
||||
Sorry, I did not develop this plugin, and therefore can not offer help.
|
||||
Have a look at the project's documentation and mailing lists available through
|
||||
<a href="http://maven-plugins.sourceforge.net/maven-dotuml-plugin/">plugin web page</a>.
|
||||
|
||||
<h2><a name="autopic">How can I make the UMLGraph doclet generate sequence diagrams?</a></h2>
|
||||
You can't.
|
||||
You have to write the <em>pic</em> code for the sequence diagrams by hand.
|
||||
|
||||
<h2><a name="unnamed">Why do the options specified in the <code>UMLOptions</code> class stop working, when I pass the <code>packagenames</code> option to <em>javadoc</em>?</a></h2>
|
||||
When you pass the <code>packagenames</code> option to
|
||||
<em>javadoc</em>, the default (unnamed) package (and the
|
||||
<code>UMLOptions</code> class
|
||||
located in it) is ignored.
|
||||
In such cases you should include the <code>UMLOptions</code> class
|
||||
within a named package.
|
||||
|
||||
<h2><a name="tiger">Why doesn't UMLGraph run under Mac OS X?</a></h2>
|
||||
Make sure you are running Java 1.5 (run <code>java -version</code> to see).
|
||||
If you are not running 1.5 you may need to adjust the symbolic links
|
||||
in
|
||||
<code>/System/Library/Frameworks/JavaVM.framework/Versions</code>.
|
||||
|
||||
<h2><a name="cpp">Can I create UML class diagrams from C++ code?</a></h2>
|
||||
This <a href="http://www.spinellis.gr/blog/20060921/">blog entry</a> describes
|
||||
a simple solution that has worked for me.
|
||||
Depending on your requirements YMMV.
|
||||
|
||||
<h2><a name="ClassCastException">How can I get around a UMLGraphDoc crash with a ClassCastException?</a></h2>
|
||||
This happens due to a know <a href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6442982">javadoc bug</a>.
|
||||
By fixing the classpath used for the UNLGraph invocation you can avoid this
|
||||
problem.
|
||||
Olivier Duysens notes:
|
||||
<blockquote>
|
||||
<p>
|
||||
JBuilder users need to go to Preferences/Build/Ant,
|
||||
and tick the box "Use project libraries when running ant" to solve the issue.
|
||||
</p>
|
||||
</blockquote>
|
||||
|
||||
<h2><a name="license">Under what license is UMLGraph distributed?</a></h2>
|
||||
UMLGraph is distributed under the
|
||||
<a href="http://www.opensource.org/licenses/bsd-license.html">BSD license</a>
|
||||
(see the file LICENSE in the distribution).
|
||||
For uniformity with the rest of the web content appearing on this site,
|
||||
the web site of UMLGraph appears under a
|
||||
<a href="http://creativecommons.org/licenses/by-nc-nd/2.5/">Creative Commons Attribution-NonCommercial-NoDerivs 2.5</a>
|
||||
license.
|
||||
This affects only the UMLGraph home page; all other material
|
||||
(for example the documentation) is also part of the UMLGraph distribution,
|
||||
and can therefore be used under the BSD license.
|
||||
|
||||
<h2><a name="classnotfound">Why do I get an exception java.lang.NoClassDefFoundError: com/sun/tools/javadoc/Main?</a></h2>
|
||||
This exception will occur when you execute UMLGraph directly as a jar
|
||||
(not through<em>javadoc</em>), and the files UmlGraph.jar and tools.jar
|
||||
are not in the same directory.
|
||||
Either copy UmlGraph.jar in the directory where the tools.jar
|
||||
of the JDK distribution is located (and execute UmlGraph.jar from there),
|
||||
or copy tools.jar to the directory where UmlGraph.jar is located.
|
||||
(The file tools.jar is typically located in the lib directory
|
||||
of your JDK distribution.)
|
||||
|
||||
<h2><a name="truncxml">How can I prevent clipped SVG images in sequence diagrams?</a></h2>
|
||||
This appears to be a limitation of <em>pic2plot</em>.
|
||||
You can work around it, by increasing the width and height values appearing
|
||||
in the SVG XML file that <em>pic2plot</em> generates.
|
||||
<h2><a name="private">How can I instruct UMLGraph to include private fields in its output?</a></h2>
|
||||
You need to pass the <code>-private</code> flag to <em>javadoc</em>.
|
||||
Note that
|
||||
when processing code that includes annotations
|
||||
defined by libraries outside the core J2SE distribution,
|
||||
it is a good idea to include the library jars to the classpath.
|
||||
Otherwise, <em>javadoc</em> (and concequently UMLGraph)
|
||||
will fail to process the input classes correctly.
|
||||
This is <a href="http://forums.oracle.com/forums/thread.jspa?threadID=1521148">a known issue</a> with <em>javadoc</em>,
|
||||
but only manifests in certain occasions when running UMLGraph,
|
||||
for example when processing private class fields.
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
/*
|
||||
* Generalisation
|
||||
* UML User Guide p. 141
|
||||
*/
|
||||
|
||||
/* Basic categorisations */
|
||||
class Asset {}
|
||||
class InterestBearingItem {}
|
||||
class InsurableItem {}
|
||||
|
||||
/* Asset types */
|
||||
/**
|
||||
* @extends InsurableItem
|
||||
* @extends InterestBearingItem
|
||||
*/
|
||||
class BankAccount extends Asset {}
|
||||
/** @extends InsurableItem */
|
||||
class RealEstate extends Asset {}
|
||||
class Security extends Asset {}
|
||||
|
||||
/* Securities */
|
||||
class Stock extends Security {}
|
||||
class Bond extends Security {}
|
||||
|
||||
/* Bank accounts */
|
||||
class CheckingAccount extends BankAccount {}
|
||||
class SavingsAccount extends BankAccount {}
|
||||
|
|
@ -0,0 +1,75 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The following sequence diagram demonstrates the use of the frame and comment elements.
|
||||
<h2>Diagram</h2>
|
||||
<img src="GUI-DB.gif" alt="Database GUI interface" />
|
||||
<h2>Diagram Source Code</h2>
|
||||
<fmtcode ext="pic">
|
||||
# usage-example for the comment extensions to the
|
||||
# Written by Sebastian Setzer
|
||||
|
||||
.PS
|
||||
copy "sequence.pic";
|
||||
|
||||
# Define the objects
|
||||
actor(U, "");
|
||||
object(G,"g:GUI");
|
||||
placeholder_object(Dummy1); # more space
|
||||
placeholder_object(D);
|
||||
step();
|
||||
|
||||
# Message sequences
|
||||
active(G);
|
||||
step();
|
||||
|
||||
create_message(G,D,"db:DB");
|
||||
active(D);
|
||||
step();
|
||||
inactive(D);
|
||||
|
||||
async(); # use asynchrone messages (not-filled arrowheads)
|
||||
|
||||
comment(D,C,down 1 right, wid 1 ht 0.7 "waiting for" "condition" "dbMailbox")
|
||||
|
||||
message(U,G,"openBrowser");
|
||||
message(G,D,"query()"); active(D);
|
||||
message(D,G,"result"); inactive(D);
|
||||
|
||||
connect_to_comment(D,C)
|
||||
|
||||
message(U,G,"scroll");
|
||||
message(G,D,"query()"); active(D);
|
||||
message(D,G,"result"); inactive(D);
|
||||
|
||||
connect_to_comment(D,C)
|
||||
|
||||
message(U,G,"Exit");
|
||||
step();
|
||||
begin_frame(G,F,"OnExit");
|
||||
message(G,D,"shutdown()"); inactive(G); active(D);
|
||||
comment(G,C,down .2 right .2, wid 2 ht 0.25 "wait for cond. dbShutdown")
|
||||
step();
|
||||
comment(D,C,right, wid 2 ht 1 \
|
||||
"all queries preceeding the" \
|
||||
"shutdown in the mailbox" \
|
||||
"are answered already." \
|
||||
"DbQuery-Objects can" \
|
||||
"be destroyed")
|
||||
message(D,G,"done"); inactive(D); active(G);
|
||||
|
||||
sync();
|
||||
destroy_message(G,D,"");
|
||||
|
||||
step();
|
||||
end_frame(D,F);
|
||||
|
||||
step();
|
||||
inactive(G);
|
||||
|
||||
# Complete the lifelines
|
||||
step();
|
||||
complete(G);
|
||||
complete(U);
|
||||
.PE
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,48 @@
|
|||
<?xml version="1.0" ?>
|
||||
<index>
|
||||
<ch><ti>Introduction</ti><fi>intro</fi></ch>
|
||||
<ch><ti>Installation</ti><fi>install</fi></ch>
|
||||
<ch><ti>Class Diagrams</ti><fi>cd-intro</fi></ch>
|
||||
<ch><ti>Class Diagram Operations</ti><fi>cd-oper</fi></ch>
|
||||
<ch><ti>Class Modelling</ti><fi>cd-model</fi></ch>
|
||||
<ch><ti>Notes in Class Diagrams</ti><fi>cd-note</fi></ch>
|
||||
<ch><ti>Class Diagram Options</ti><fi>cd-opt</fi></ch>
|
||||
<ch><ti>Specifying class Diagram Options</ti><fi>cd-opt-spec</fi></ch>
|
||||
<ch><ti>Javadocs and UML class diagrams with UMLGraphDoc</ti><fi>cd-umldoc</fi></ch>
|
||||
<ch><ti>Class Diagram Views</ti><fi>views</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Shapes</ti><fi>ceg-shape</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Generalisation Relationships</ti><fi>ceg-gen</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Advanced Relationships</ti><fi>ceg-adv</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Relationships Inference</ti><fi>ceg-infer</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Schema</ti><fi>ceg-schema</fi></ch>
|
||||
<ch><ti>Class Diagram Example: ER</ti><fi>ceg-er</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Element Visibility</ti><fi>ceg-ev</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Association Types</ti><fi>ceg-at</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Real Example (Catalina Classes)</ti><fi>ceg-cat</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Class Stereotypes and Tagged Values</ti><fi>ceg-ster</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Fonts, Colors, Global and Local Options</ti><fi>ceg-color</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Multiple Views Through Command-Line Options</ti><fi>ceg-mv</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Built-in Support for Views</ti><fi>ceg-view-spec</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Views With Different Specification Details</ti><fi>ceg-view-details</fi></ch>
|
||||
<ch><ti>Class Diagram Example: Views for Different Packages</ti><fi>ceg-view-packages</fi></ch>
|
||||
<ch><ti>Running the Doclet from Ant</ti><fi>ant</fi></ch>
|
||||
<ch><ti>Sequence Diagrams</ti><fi>seq-intro</fi></ch>
|
||||
<ch><ti>Syntax of Sequence Diagram Definitions</ti><fi>seq-syntax</fi></ch>
|
||||
<ch><ti>Defining a Simple Sequence Diagram</ti><fi>seq-simple</fi></ch>
|
||||
<ch><ti>An Improved Sequence Diagram</ti><fi>seq-impr</fi></ch>
|
||||
<ch><ti>Creating and Destroying Objects</ti><fi>seq-cd</fi></ch>
|
||||
<ch><ti>Sequence Diagram Operations</ti><fi>seq-ops</fi></ch>
|
||||
<ch><ti>Sequence Diagram Variables</ti><fi>seq-var</fi></ch>
|
||||
<ch><ti>Sequence Diagram Example: Nested Activation and Complex Interactions</ti><fi>uml-appa</fi></ch>
|
||||
<ch><ti>Sequence Diagram Example: Concurrent Processes and Activations</ti><fi>dist-52</fi></ch>
|
||||
<ch><ti>Sequence Diagram Example: Create and Destroy</ti><fi>uml-182</fi></ch>
|
||||
<ch><ti>Sequence Diagram Example: Lifeline Constraints</ti><fi>uml-184</fi></ch>
|
||||
<ch><ti>Sequence Diagram Example: External Actor</ti><fi>uml-71</fi></ch>
|
||||
<ch><ti>Sequence Diagram Example: A DNS Query</ti><fi>dns</fi></ch>
|
||||
<ch><ti>Sequence Diagram Example: A Comments and Frames</ti><fi>gui-db</fi></ch>
|
||||
<ch><ti>Frequently Asked Questions</ti><fi>faq</fi></ch>
|
||||
<ch><ti>Bibliography</ti><fi>bib</fi></ch>
|
||||
<ch><ti>Projects Based on UMLGraph</ti><fi>deriv</fi></ch>
|
||||
<ch><ti>Version History</ti><fi>ver</fi></ch>
|
||||
<ch><ti>Acknowledgements</ti><fi>ack</fi></ch>
|
||||
</index>
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
/*
|
||||
* Relationship inference
|
||||
*/
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* @opt inferrel
|
||||
* @opt collpackages java.util.*
|
||||
* @opt inferdep
|
||||
* @opt inferdepinpackage
|
||||
* @opt hide java.*
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
class Person {
|
||||
House[] houses;
|
||||
List<Dog> dogs;
|
||||
|
||||
public Room getFavouriteRoom(House house) {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @opt inferreltype composed
|
||||
*/
|
||||
class House {
|
||||
Map<String, Room> nameRoomMap;
|
||||
}
|
||||
|
||||
class Room {}
|
||||
|
||||
class Dog {
|
||||
Person owner;
|
||||
}
|
||||
|
After Width: | Height: | Size: 1.4 KiB |
|
|
@ -0,0 +1,37 @@
|
|||
<?xml version="1.0" encoding="ISO-8859-7" ?>
|
||||
<notes>
|
||||
To install UmlGraph follow these steps.
|
||||
<ol>
|
||||
<li> Copy the files in <code>lib</code> to a directory you will
|
||||
use for storing UmlGraph's installation
|
||||
(for instance, <code>/usr/local/lib</code>).
|
||||
</li>
|
||||
<li> Copy the file <code>bin/umlgraph</code> (for Unix) or
|
||||
<code>bin/umlgraph.bat</code> (for Windows) to a directory
|
||||
of your execution path (for instance, <code>/usr/local/bin</code>).</li>
|
||||
<li> Adjust the above file, setting <code>UMLGRAPH_HOME</code> to
|
||||
point to the directory where you installed the UmlGraph library files.
|
||||
</li>
|
||||
</ol>
|
||||
<p>
|
||||
UMLGraph is implemented as a <em>javadoc</em> doclet (a program satisfying the
|
||||
doclet API that specifies the content and format of the output
|
||||
generated by the <em>javadoc</em> tool).
|
||||
Furthermore, the output of UmlGraph needs to be post-processed
|
||||
with the <em>Graphviz</em> <em>dot</em> program.
|
||||
Therefore, to draw class diagrams with UmlGraph class you will need to have
|
||||
<a href="http://java.sun.com/j2se/javadoc/"><em>javadoc</em></a>
|
||||
and
|
||||
<a href="http://www.graphviz.org/">Graphviz</a>
|
||||
installed on your computer.
|
||||
Both programs are freely available, from Sun and AT&T respectively,
|
||||
for many platforms including Unix and Windows.
|
||||
<em>Javadoc</em> is part of the Sun JDK, so a typical JDK installation will also
|
||||
include <em>javadoc</em>.
|
||||
</p>
|
||||
<p>
|
||||
To draw UML sequence diagrams you must also install the free
|
||||
<a href="http://www.gnu.org/software/plotutils/plotutils.html">GNU plotutils</a>
|
||||
system.
|
||||
</p>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
UMLGraph allows the declarative specification and drawing of
|
||||
UML class and sequence diagrams.
|
||||
The specification is done in text diagrams, that are then
|
||||
transformed into the appropriate graphical representations.
|
||||
<p />
|
||||
There is no rule specifying that models should appear in a graphical
|
||||
form. A model is a simplification of reality, so a model for a software
|
||||
artifact could really be an outline of that artifact; think of a class
|
||||
definition without code in the method bodies. However, we usually
|
||||
prefer to examine many of our models in a graphical representation: UML
|
||||
employs ten different diagrams for visualizing different perspectives
|
||||
of a system.
|
||||
<p />
|
||||
Designers typically create their model diagrams using a drawing editor.
|
||||
However, all drawing editors require the tedious placing and manipulation of drawing shapes on the canvas. The effort and the motor coordination skills required for this activity are mostly irrelevant to the end result: unlike architectural or mechanical engineering models the appearance of a software system's model diagram is only marginally related to the quality of the represented software design.
|
||||
<p />
|
||||
Computer power and automatic graph drawing algorithms have now
|
||||
sufficiently advanced so as to allow the automatic placement of graph
|
||||
nodes on the canvas and the near optimal routing of the respective
|
||||
edges. We can therefore design models using a declarative textual
|
||||
representation and subsequently view, publish, and share them in
|
||||
graphical form.
|
||||
UMLGraph's support for
|
||||
declaratively specifying class and sequence diagrams
|
||||
is part of an ongoing effort aiming to support all ten types of UML diagrams.
|
||||
<p />
|
||||
Creating models in a declarative, textual notation offers a number of advantages.
|
||||
<ul>
|
||||
<li> First of all, the model composition mechanism matches well both a programmer's high-level skills, the textual abstract formalization of concrete concepts, and the associated low-level skills, the manipulation of text using an editor and other text-based tools.</li>
|
||||
<li> The declarative notation, by being closer to the program's representation (the notation I experimented with is based on the Java syntax and semantics), forces the designer to distinguish between the model and the respective implementation, between the essential system characteristics and the trivial adornments.
|
||||
It is more difficult for designers to get away, as they often do now, with drawing for a model a nice picture of the implementation they have in mind.</li>
|
||||
<li> The declarative representation is also highly malleable, the existing visual structure does not hinder drastic changes, nor is effort wasted on the tidy arrangement of graph nodes a psychological barrier against massive design refactoring.</li>
|
||||
<li> Declarative models are also highly automatable: they can be easily generated from even higher-level descriptions by trivial scripts and tools operating on design process inputs such as database schemas, existing code, or structured requirements documents.</li>
|
||||
<li> With a declarative specification under the programmer's control a macro processors can be used for configuration management, allowing the same model to be used for generating diverse diagrams.</li>
|
||||
<li> Revision control and team integration activities can utilize the same proven tools and processes that are currently used for managing source code.
|
||||
Thus with a tool like Subversion or Git one can keep track of design revisions, create and merge branches, monitor model changes, and split work among a team.</li>
|
||||
<li> Finally, the declarative approach can readily utilize existing text processing tools for tasks that a drawing editor system may not provide.</li>
|
||||
</ul>
|
||||
Consider how your favorite model editor handles the following tasks and how you could handle them using a simple Perl script or a text-processing pipeline applied to the declarative model specification:
|
||||
<ul>
|
||||
<li>identify all classes containing a given field (as a prelude to an aspect-oriented cross-cut);</li>
|
||||
<li>count the total number of private fields in a given design;</li>
|
||||
<li>order methods appearing in multiple classes by their degree of commonality;</li>
|
||||
<li>identify differences between two designs.</li>
|
||||
</ul>
|
||||
All the above tasks can be easily performed in text files using Unix commands
|
||||
such as
|
||||
<em>grep</em>,
|
||||
<em>wc</em>,
|
||||
<em>grep ... | sort ...</em>, and
|
||||
<em>diff</em>.
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,33 @@
|
|||
/**
|
||||
* @opt nodefontname "Helvetica"
|
||||
* @opt edgefontname "Helvetica"
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions{}
|
||||
|
||||
/**
|
||||
* @opt shape node
|
||||
* @note Located in the
|
||||
* machine room
|
||||
* @note Sun Blade 6048
|
||||
* @depend - - - MapLocation
|
||||
* @depend - - - DataMine
|
||||
*/
|
||||
class Server{}
|
||||
|
||||
/** @opt shape component */
|
||||
class MapLocation {}
|
||||
|
||||
/** @opt shape component */
|
||||
class DataMine {}
|
||||
|
||||
/**
|
||||
* CPU-munching
|
||||
* components that must
|
||||
* run on this server
|
||||
* @opt shape note
|
||||
* @opt commentname
|
||||
* @assoc - - - MapLocation
|
||||
* @assoc - - - DataMine
|
||||
*/
|
||||
class munchComment {}
|
||||
|
|
@ -0,0 +1,69 @@
|
|||
/*
|
||||
* Schema model
|
||||
* UML User Guide p. 112
|
||||
*/
|
||||
|
||||
/**
|
||||
* @opt operations
|
||||
* @opt attributes
|
||||
* @opt types
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/* Define some types we use */
|
||||
/** @hidden */
|
||||
class Name {}
|
||||
/** @hidden */
|
||||
class Number {}
|
||||
|
||||
/**
|
||||
* @has 1..* Member * Student
|
||||
* @composed 1..* Has 1..* Department
|
||||
*/
|
||||
class School {
|
||||
Name name;
|
||||
String address;
|
||||
Number phone;
|
||||
void addStudent() {}
|
||||
void removeStudent() {}
|
||||
void getStudent() {}
|
||||
void getAllStudents() {}
|
||||
void addDepartment() {}
|
||||
void removeDepartment() {}
|
||||
void getDepartment() {}
|
||||
void getAllDepartments() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @has 1..* AssignedTo 1..* Instructor
|
||||
* @assoc 1..* - 1..* Course
|
||||
* @assoc 0..* - "0..1 chairperson" Instructor
|
||||
*/
|
||||
class Department {
|
||||
Name name;
|
||||
void addInstructor() {}
|
||||
void removeInstructor() {}
|
||||
void getInstructor() {}
|
||||
void getAllInstructors() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @assoc * Attends * Course
|
||||
*/
|
||||
class Student {
|
||||
Name name;
|
||||
Number studentID;
|
||||
}
|
||||
|
||||
class Course {
|
||||
Name name;
|
||||
Number courseID;
|
||||
}
|
||||
|
||||
/**
|
||||
* @assoc 1..* Teaches * Course
|
||||
*/
|
||||
class Instructor {
|
||||
Name name;
|
||||
}
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
#
|
||||
#
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
# Define the objects
|
||||
object(S,"s:Switch");
|
||||
object(P,"p:Pump");
|
||||
placeholder_object(F);
|
||||
step();
|
||||
active(S);
|
||||
active(P);
|
||||
|
||||
# Message sequences
|
||||
message(S,P,"run()");
|
||||
create_message(P,F,"f:Flow");
|
||||
active(F);
|
||||
message(S,P,"stop()");
|
||||
destroy_message(P,F);
|
||||
|
||||
step();
|
||||
complete(S);
|
||||
complete(P);
|
||||
|
||||
.PE
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
Objects do not always appear at the top of a UML sequence diagram;
|
||||
they are often constructed by other objects.
|
||||
In this case, a placeholder object is defined at the beginning
|
||||
of the diagram, to leave the appropriate space of the object.
|
||||
Later a create message will actually create an object with the
|
||||
given label.
|
||||
Any object can also receive a destroy message, that will stop
|
||||
its life.
|
||||
The lifeline of destroyed messages is not typically completed.
|
||||
<p />
|
||||
The following definition extends our previous diagram with a
|
||||
dynamically created flow object.
|
||||
<fmtcode ext="pic">
|
||||
# Define the objects
|
||||
object(S,"s:Switch");
|
||||
object(P,"p:Pump");
|
||||
placeholder_object(F);
|
||||
step();
|
||||
active(S);
|
||||
active(P);
|
||||
|
||||
# Message sequences
|
||||
message(S,P,"run()");
|
||||
create_message(P,F,"f:Flow");
|
||||
active(F);
|
||||
message(S,P,"stop()");
|
||||
destroy_message(P,F);
|
||||
|
||||
# Object completion
|
||||
step();
|
||||
complete(S);
|
||||
complete(P);
|
||||
</fmtcode>
|
||||
<p />
|
||||
The resultant diagram is<br />
|
||||
<img src="seq-cd.gif" alt="Sequence diagram with object construction and destruiction" />
|
||||
<p />
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,32 @@
|
|||
# UML User Guide: Appendix A,p. 436
|
||||
#
|
||||
#
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
# Define the objects
|
||||
object(O,"o:Toolkit");
|
||||
placeholder_object(P);
|
||||
step();
|
||||
|
||||
# Message sequences
|
||||
active(O);
|
||||
step();
|
||||
active(O);
|
||||
message(O,O,"callbackLoop()");
|
||||
inactive(O);
|
||||
create_message(O,P,"p:Peer");
|
||||
message(O,P,"handleExpose()");
|
||||
active(P);
|
||||
return_message(P,O,"");
|
||||
inactive(P);
|
||||
destroy_message(O,P);
|
||||
inactive(O);
|
||||
|
||||
# Complete the lifelines
|
||||
step();
|
||||
complete(O);
|
||||
|
||||
.PE
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
#
|
||||
#
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
# Define the objects
|
||||
object(S,"s:Switch");
|
||||
object(P,"p:Pump");
|
||||
step();
|
||||
active(S);
|
||||
active(P);
|
||||
|
||||
# Message sequences
|
||||
message(S,P,"run()");
|
||||
message(S,P,"stop()");
|
||||
|
||||
step();
|
||||
complete(S);
|
||||
complete(P);
|
||||
|
||||
.PE
|
||||
|
|
@ -0,0 +1,33 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
Let us try to improve the simple sequence diagram.
|
||||
<fmtcode ext="pic">
|
||||
# Object definition
|
||||
object(S,"s:Switch");
|
||||
object(P,"p:Pump");
|
||||
step();
|
||||
active(S);
|
||||
active(P);
|
||||
|
||||
# Message exchange
|
||||
message(S,P,"run()");
|
||||
message(S,P,"stop()");
|
||||
|
||||
# Object lifeline completion
|
||||
step();
|
||||
complete(S);
|
||||
complete(P);
|
||||
</fmtcode>
|
||||
Here, we have manually advanced the timeline of our diagrams
|
||||
with a <code>step();</code> call after we defined the objects,
|
||||
to provide them with a bit of breathing space.
|
||||
We also added a similar step call at the end of the diagram.
|
||||
Finally, we made both objects active, after their definition.
|
||||
Calling active on a given object will change the drawing of its
|
||||
lifeline, from the dashed format indicating an inactive object,
|
||||
to a thick swimming-lane, active object, format.
|
||||
<p />
|
||||
The resultant diagram is<br />
|
||||
<img src="seq-impr.gif" alt="Improved sequence diagram" />
|
||||
<p />
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,50 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
One specifies a sequence diagram using <em>pic</em> macros to define
|
||||
objects and method invocations.
|
||||
The <a href="http://www.gnu.org/software/plotutils/plotutils.html">GNU plotutils</a>
|
||||
<em>pic2plot</em> program can then process the sequence diagram to create a
|
||||
PNG, PNM, (pseudo)GIF, SVG, AI, Postscript, CGM, FIG, PCL, HPGL, Regis, or TEK
|
||||
drawing.
|
||||
<p />
|
||||
The following is an example of a specification and the resulting UML sequence
|
||||
diagram:
|
||||
<table>
|
||||
<tr><td>
|
||||
<fmtcode ext="pic">
|
||||
.PS
|
||||
copy "sequence.pic";
|
||||
|
||||
# Define the objects
|
||||
object(O,"o:Toolkit");
|
||||
placeholder_object(P);
|
||||
step();
|
||||
|
||||
# Message sequences
|
||||
active(O);
|
||||
step();
|
||||
active(O);
|
||||
message(O,O,"callbackLoop()");
|
||||
inactive(O);
|
||||
create_message(O,P,"p:Peer");
|
||||
message(O,P,"handleExpose()");
|
||||
active(P);
|
||||
return_message(P,O,"");
|
||||
inactive(P);
|
||||
destroy_message(O,P);
|
||||
inactive(O);
|
||||
|
||||
# Complete the lifelines
|
||||
step();
|
||||
complete(O);
|
||||
.PE
|
||||
</fmtcode>
|
||||
</td><td>
|
||||
<img src="seq-eg.gif" alt="Simple UML sequence diagram" />
|
||||
</td></tr></table>
|
||||
The diagram is drawn from its source code specification using a command
|
||||
like:
|
||||
<fmtcode ext="sh">
|
||||
pic2plot -Tgif FILENAME.pic >FILENAME.gif
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,115 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<notes>
|
||||
The following calls can be used to define a sequence diagram.
|
||||
<dl>
|
||||
<dt>object(name,label);</dt>
|
||||
<dd>Defines an object with the given name, labeled on the diagram
|
||||
as specified.</dd>
|
||||
<dt>placeholder_object(name)</dt>
|
||||
<dd>Defines a place where the named object will later be
|
||||
created.
|
||||
Can also be written as <code>pobject</code>.
|
||||
</dd>
|
||||
<dt>actor(name,label);</dt>
|
||||
<dd>Defines an actor with the given name, labeled on the diagram
|
||||
as specified.
|
||||
Actors are typically used instead of objects to indicate operations
|
||||
initiated by human actions. </dd>
|
||||
<dt>complete(name);</dt>
|
||||
<dd>Completes the lifeline of a given object (or actor)
|
||||
by drawing its lifeline to the bottom of the diagram.</dd>
|
||||
<dt>message(from_object,to_object,label)</dt>
|
||||
<dd>Draws a message between two objects, with the given label.
|
||||
Self messages (where an objects sends a message to itself)
|
||||
are supported.
|
||||
</dd>
|
||||
<dt>return_message(from_object,to_object,label)</dt>
|
||||
<dd>Draws a return message between two objects, with the given label.
|
||||
Can also be written as <code>rmessage</code>.
|
||||
</dd>
|
||||
<dt>create_message(from_object,to_object,object_label);</dt>
|
||||
<dd>Has from_object create the to_object, labeled
|
||||
with object_label.
|
||||
The message is labeled with the <code>«create»</code> stereotype.
|
||||
Can also be written as <code>cmessage</code>.
|
||||
</dd>
|
||||
<dt>destroy_message(from_object,to_object);</dt>
|
||||
<dd>Sends a message
|
||||
labeled with the <code>«destroy»</code> stereotype
|
||||
from the from_object to the to_object.
|
||||
The object to_object is marked as destroyed, with an X at the
|
||||
end of its lifeline.
|
||||
The object's lifeline need not be otherwise completed.
|
||||
Can also be written as <code>dmessage</code>.
|
||||
</dd>
|
||||
<dt>active(object);</dt>
|
||||
<dd>Changes the object's status to active, and
|
||||
changes its lifeline drawing style correspondingly.
|
||||
An active call in an already active object will result
|
||||
in a swimlane showing a nested object activation.</dd>
|
||||
<dt>inactive(object);</dt>
|
||||
<dd>Changes the object's status to inactive, and
|
||||
changes its lifeline drawing style correspondingly.
|
||||
An inactive call on a nested object invocation will
|
||||
result in showing a simple active swimlane.</dd>
|
||||
<dt>delete(object);</dt>
|
||||
<dd>The object deletes itself, drawing an X at the end
|
||||
of its lifeline.
|
||||
The object's lifeline need not be otherwise completed.
|
||||
</dd>
|
||||
<dt>lifeline_constraint(object,label);</dt>
|
||||
<dd>Displays a constraint label (typically given inside curly braces)
|
||||
for the given object.
|
||||
The constraint will appear on the right of the object's lifeline
|
||||
at the time it appears.
|
||||
Can also be used to place an message label on the left of a
|
||||
message arrow, rather than its center.
|
||||
Can also be written as <code>lconstraint</code>.
|
||||
</dd>
|
||||
<dt>lconstraint_below(object,label);</dt>
|
||||
<dd>same as <code>lconstraint</code>,
|
||||
but it will be shown below the current line instead of above.
|
||||
</dd>
|
||||
<dt>object_constraint(label)</dt>
|
||||
<dd>Displays an object constraint (typically given inside curly braces)
|
||||
for the last object defined.
|
||||
Can also be written as <code>oconstraint</code>.
|
||||
</dd>
|
||||
<dt>step();</dt>
|
||||
<dd>Steps the time by a single increment, extending all
|
||||
lifelines.</dd>
|
||||
<dt>async();</dt>
|
||||
<dd>All subsequent messages are asynchronous and will
|
||||
be drawn correspondingly.</dd>
|
||||
<dt>sync();</dt>
|
||||
<dd>All subsequent messages are synchronous and will
|
||||
be drawn correspondingly.</dd>
|
||||
<dt>begin_frame(left_object,name,label_text);</dt>
|
||||
<dd>Begins a frame with the upper left corner at
|
||||
<code>left_object</code> column and the current line.
|
||||
The specified <code>label_text</code> is shown in the upper left corner.
|
||||
</dd>
|
||||
<dt>end_frame(right_object,name);</dt>
|
||||
<dd>Ends a frame with the lower right corner at
|
||||
<code>right_object</code> column and the current line.
|
||||
The name must correspond to a <code>begin_frame</code>'s name.
|
||||
</dd>
|
||||
<dt>comment(object,[name],[line_movement],[box_size] text);</dt>
|
||||
<dd>Displays a comment about the object.
|
||||
The name can be used with
|
||||
<code>connect_to_comment(object2,name);</code> to get additional
|
||||
connecting lines to the comment.
|
||||
<code>line_movement</code> changes the position of the comment and
|
||||
<code>box_size</code> its size. Note that there's no comma between
|
||||
<code>box_size</code> and <code>text</code>.
|
||||
<code>text</code> is the (multiline) comment-text that will be displayed.
|
||||
<code>name</code>, <code>line_movement</code> and <code>box_size</code> are optional
|
||||
(but the commas must still appear).
|
||||
</dd>
|
||||
<dt>connect_to_comment(object2,name);</dt>
|
||||
<dd>See <code>comment</code>.
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
</notes>
|
||||
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
#
|
||||
#
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
# Define the objects
|
||||
object(S,"s:Switch");
|
||||
object(P,"p:Pump");
|
||||
|
||||
# Message sequences
|
||||
message(S,P,"run()");
|
||||
message(S,P,"stop()");
|
||||
|
||||
complete(S);
|
||||
complete(P);
|
||||
|
||||
.PE
|
||||
|
|
@ -0,0 +1,48 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
A sequence diagram is defined in three main phases:
|
||||
<ol>
|
||||
<li> Object definition </li>
|
||||
<li> Message exchange </li>
|
||||
<li> Object lifeline completion</li>
|
||||
</ol>
|
||||
The following is an example of a very simple UMLGraph
|
||||
sequence diagram
|
||||
(from now on we will ommit the <code>.PS/.PE</code> and
|
||||
<code>copy "sequence.pic";</code>
|
||||
elements.)
|
||||
<fmtcode ext="pic">
|
||||
.PS
|
||||
copy "sequence.pic";
|
||||
|
||||
# Object definition
|
||||
object(S,"s:Switch");
|
||||
object(P,"p:Pump");
|
||||
|
||||
# Message exchange
|
||||
message(S,P,"run()");
|
||||
message(S,P,"stop()");
|
||||
|
||||
# Object lifeline completion
|
||||
complete(S);
|
||||
complete(P);
|
||||
|
||||
.PE
|
||||
</fmtcode>
|
||||
The above code, defines two objects, S and P,
|
||||
labeled as "s:Switch" and "p:Pump".
|
||||
Objects are placed in the diagram from left to right, in the
|
||||
order they are defined.
|
||||
All defined objects are initially inactive.
|
||||
<p />
|
||||
The code then sends a messages from S to P labeled "run()",
|
||||
and another one labeled "stop()".
|
||||
Each message automatically advances the sequence diagram timeline by a
|
||||
single step.
|
||||
<p />
|
||||
Finally, the code completes the lifelines of the two objects.
|
||||
<p />
|
||||
The resultant diagram is<br />
|
||||
<img src="seq-simple.gif" alt="Simple sequence diagram" />
|
||||
<p />
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,47 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
Sequence diagrams consist of objects, their lifelines
|
||||
(also known as smimming lanes),
|
||||
and the exchanged messages.
|
||||
Sequence diagrams are defined in UMLGraph using the <em>pic</em>
|
||||
syntax.
|
||||
<p />
|
||||
A sequence diagram file must start with the sequence:
|
||||
<fmtcode ext="pic">
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
</fmtcode>
|
||||
The <code>.PS</code> marks the beginning of <em>pic</em> commands.
|
||||
The sequence
|
||||
<code>copy "sequence.pic";</code>
|
||||
loads the macros defining the sequence diagram operations.
|
||||
The file <code>sequence.pic</code>, part of the UMLGraph distribution,
|
||||
must exist in the directory where <em>pic2plot</em> will be executed.
|
||||
<p />
|
||||
Sequence diagram files must end with the sequence:
|
||||
<fmtcode ext="pic">
|
||||
.PE
|
||||
</fmtcode>
|
||||
<p />
|
||||
The sequence diagrams are defined by calling function-like <em>pic</em>
|
||||
macros.
|
||||
Each function call is terminated with a semicolon.
|
||||
Space is not significant between macro calls; on the other hand
|
||||
adding a space character between a macro's arguments can lead
|
||||
to surprises and should be avoided.
|
||||
Objects are referenced using variable-like alphanumeric identifiers.
|
||||
Strings are enclosed in double quotes.
|
||||
<p />
|
||||
As an example, the following defines an object <code>O</code>
|
||||
that will be identified in the diagram as
|
||||
<code>o:Toolkit</code>
|
||||
<fmtcode ext="pic">
|
||||
object(O,"o:Toolkit");
|
||||
</fmtcode>
|
||||
<p />
|
||||
Comments start with a <code>#</code> character.
|
||||
<fmtcode ext="pic">
|
||||
# This is a comment
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The value of
|
||||
<em>pic</em> variables can sometimes be modified by assignment
|
||||
to achieve a better-looking result.
|
||||
The following two lines change the width of the object boxes to
|
||||
1.1" and the spacing between objects
|
||||
to 0.5".
|
||||
<fmtcode ext="pic">
|
||||
boxwid = 1.1;
|
||||
movewid = 0.5;
|
||||
</fmtcode>
|
||||
The following variables can be redefined to change the layout of
|
||||
a drawing.
|
||||
<p />
|
||||
<table border = "1">
|
||||
<tr><th>Variable Name</th><th>Default Value</th><th>Operation</th></tr>
|
||||
<tr><td>boxht</td><td>0.3</td><td>Object box height</td></tr>
|
||||
<tr><td>boxwid</td><td>0.75</td><td>Object box width</td></tr>
|
||||
<tr><td>awid</td><td>0.1</td><td>Active lifeline width</td></tr>
|
||||
<tr><td>spacing</td><td>0.25</td><td>Spacing between messages</td></tr>
|
||||
<tr><td>movewid</td><td>0.75</td><td>Spacing between objects</td></tr>
|
||||
<tr><td>dashwid</td><td>0.05</td><td>Interval for dashed lines</td></tr>
|
||||
<tr><td>maxpswid</td><td>11</td><td>Maximum width of picture</td></tr>
|
||||
<tr><td>maxpsht</td><td>11</td><td>Maximum height of picture</td></tr>
|
||||
<tr><td>underline</td><td>1</td><td>Underline the name of objects</td></tr>
|
||||
</table>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,406 @@
|
|||
#/usr/bin/pic2plot -Tps
|
||||
#
|
||||
# Pic macros for drawing UML sequence diagrams
|
||||
#
|
||||
# (C) Copyright 2004-2005 Diomidis Spinellis.
|
||||
#
|
||||
# Permission to use, copy, and distribute this software and its
|
||||
# documentation for any purpose and without fee is hereby granted,
|
||||
# provided that the above copyright notice appear in all copies and that
|
||||
# both that copyright notice and this permission notice appear in
|
||||
# supporting documentation.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
|
||||
# WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
|
||||
# MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
|
||||
#
|
||||
#
|
||||
|
||||
|
||||
# Default parameters (can be redefined)
|
||||
|
||||
# Spacing between messages
|
||||
spacing = 0.25;
|
||||
# Active box width
|
||||
awid = .1;
|
||||
# Box height
|
||||
boxht = 0.3;
|
||||
# Commend folding
|
||||
corner_fold=awid
|
||||
# Comment distance
|
||||
define comment_default_move {up 0.25 right 0.25};
|
||||
# Comment height
|
||||
comment_default_ht=0.5;
|
||||
# Comment width
|
||||
comment_default_wid=1;
|
||||
# Underline object name
|
||||
underline=1;
|
||||
|
||||
# Create a new object(name,label)
|
||||
define object {
|
||||
$1: box $2; move;
|
||||
# Could also underline text with \mk\ul\ul\ul...\rt
|
||||
if (underline) then {
|
||||
line from $1.w + (.1, -.07) to $1.e + (-.1, -.07);
|
||||
}
|
||||
move to $1.e;
|
||||
move right;
|
||||
# Active is the level of activations of the object
|
||||
# 0 : inactive : draw thin line swimlane
|
||||
# 1 : active : draw thick swimlane
|
||||
# > 1: nested : draw nested swimlane
|
||||
active_$1 = 0;
|
||||
lifestart_$1 = $1.s.y;
|
||||
}
|
||||
|
||||
# Create a new external actor(name,label)
|
||||
define actor {
|
||||
$1: [
|
||||
XSEQC: circle rad 0.06;
|
||||
XSEQL: line from XSEQC.s down .12;
|
||||
line from XSEQL.start - (.15,.02) to XSEQL.start + (.15,-.02);
|
||||
XSEQL1: line from XSEQL.end left .08 down .15;
|
||||
XSEQL2: line from XSEQL.end right .08 down .15;
|
||||
line at XSEQC.n invis "" "" "" $2;
|
||||
]
|
||||
move to $1.e;
|
||||
move right;
|
||||
active_$1 = 0;
|
||||
lifestart_$1 = $1.s.y - .05;
|
||||
}
|
||||
|
||||
# Create a new placeholder object(name)
|
||||
define placeholder_object {
|
||||
$1: box invisible;
|
||||
move;
|
||||
move to $1.e;
|
||||
move right;
|
||||
active_$1 = 0;
|
||||
lifestart_$1 = $1.s.y;
|
||||
}
|
||||
|
||||
define pobject {
|
||||
placeholder_object($1);
|
||||
}
|
||||
|
||||
define extend_lifeline {
|
||||
if (active_$1 > 0) then {
|
||||
# draw the left edges of the boxes
|
||||
move to ($1.x - awid/2, Here.y);
|
||||
for level = 1 to active_$1 do {
|
||||
line from (Here.x, lifestart_$1) to Here;
|
||||
move right awid/2
|
||||
}
|
||||
|
||||
# draw the right edge of the innermost box
|
||||
move right awid/2;
|
||||
line from (Here.x, lifestart_$1) to Here;
|
||||
} else {
|
||||
line from ($1.x, lifestart_$1) to ($1.x, Here.y) dashed;
|
||||
}
|
||||
lifestart_$1 = Here.y;
|
||||
}
|
||||
|
||||
# complete(name)
|
||||
# Complete the lifeline of the object with the given name
|
||||
define complete {
|
||||
extend_lifeline($1)
|
||||
if (active_$1) then {
|
||||
# draw bottom of all active boxes
|
||||
line right ((active_$1 + 1) * awid/2) from ($1.x - awid/2, Here.y);
|
||||
}
|
||||
}
|
||||
|
||||
# Draw a message(from_object,to_object,label)
|
||||
define message {
|
||||
down;
|
||||
move spacing;
|
||||
# Adjust so that lines and arrows do not fall into the
|
||||
# active box. Should be .5, but the arrow heads tend to
|
||||
# overshoot.
|
||||
if ($1.x <= $2.x) then {
|
||||
off_from = awid * .6;
|
||||
off_to = -awid * .6;
|
||||
} else {
|
||||
off_from = -awid * .6;
|
||||
off_to = awid * .6;
|
||||
}
|
||||
|
||||
# add half a box width for each level of nesting
|
||||
if (active_$1 > 1) then {
|
||||
off_from = off_from + (active_$1 - 1) * awid/2;
|
||||
}
|
||||
|
||||
# add half a box width for each level of nesting
|
||||
if (active_$2 > 1) then {
|
||||
off_to = off_to + (active_$2 - 1) * awid/2;
|
||||
}
|
||||
|
||||
if ($1.x == $2.x) then {
|
||||
arrow from ($1.x + off_from, Here.y) right then down .25 then left $3 ljust " " " " " " ;
|
||||
} else {
|
||||
arrow from ($1.x + off_from, Here.y) to ($2.x + off_to, Here.y) $3 " ";
|
||||
}
|
||||
}
|
||||
|
||||
# Display a lifeline constraint(object,label)
|
||||
define lifeline_constraint {
|
||||
off_from = awid;
|
||||
# add half a box width for each level of nesting
|
||||
if (active_$1 > 1) then {
|
||||
off_from = off_from + (active_$1 - 1) * awid/2;
|
||||
}
|
||||
|
||||
box at ($1.x + off_from, Here.y) invis $2 ljust " " ;
|
||||
}
|
||||
|
||||
define lconstraint {
|
||||
lifeline_constraint($1,$2);
|
||||
}
|
||||
|
||||
# Display an object constraint(label)
|
||||
# for the last object drawn
|
||||
define object_constraint {
|
||||
{ box invis with .s at last box .nw $1 ljust; }
|
||||
}
|
||||
|
||||
define oconstraint {
|
||||
object_constraint($1);
|
||||
}
|
||||
|
||||
# Draw a creation message(from_object,to_object,object_label)
|
||||
define create_message {
|
||||
down;
|
||||
move spacing;
|
||||
if ($1.x <= $2.x) then {
|
||||
off_from = awid * .6;
|
||||
off_to = -boxwid * .51;
|
||||
} else {
|
||||
off_from = -awid * .6;
|
||||
off_to = boxwid * .51;
|
||||
}
|
||||
|
||||
# add half a box width for each level of nesting
|
||||
if (active_$1 > 1) then {
|
||||
off_from = off_from + (active_$1 - 1) * awid/2;
|
||||
}
|
||||
|
||||
# See comment in destroy_message
|
||||
XSEQA: arrow from ($1.x + off_from, Here.y) to ($2.x + off_to, Here.y) "«create»" " ";
|
||||
if ($1.x <= $2.x) then {
|
||||
{ XSEQB: box $3 with .w at XSEQA.end; }
|
||||
} else {
|
||||
{ XSEQB: box $3 with .e at XSEQA.end; }
|
||||
}
|
||||
{
|
||||
line from XSEQB.w + (.1, -.07) to XSEQB.e + (-.1, -.07);
|
||||
}
|
||||
lifestart_$2 = XSEQB.s.y;
|
||||
move (spacing + boxht) / 2;
|
||||
}
|
||||
|
||||
define cmessage {
|
||||
create_message($1,$2,$3);
|
||||
}
|
||||
|
||||
# Draw an X for a given object
|
||||
define drawx {
|
||||
{
|
||||
line from($1.x - awid, lifestart_$1 - awid) to ($1.x + awid, lifestart_$1 + awid);
|
||||
line from($1.x - awid, lifestart_$1 + awid) to ($1.x + awid, lifestart_$1 - awid);
|
||||
}
|
||||
}
|
||||
|
||||
# Draw a destroy message(from_object,to_object)
|
||||
define destroy_message {
|
||||
down;
|
||||
move spacing;
|
||||
# The troff code is \(Fo \(Fc
|
||||
# The groff code is also \[Fo] \[Fc]
|
||||
# The pic2plot code is \Fo \Fc
|
||||
# See http://www.delorie.com/gnu/docs/plotutils/plotutils_71.html
|
||||
# To stay compatible with all we have to hardcode the characters
|
||||
message($1,$2,"«destroy»");
|
||||
complete($2);
|
||||
drawx($2);
|
||||
}
|
||||
|
||||
define dmessage {
|
||||
destroy_message($1,$2);
|
||||
}
|
||||
|
||||
# An object deletes itself: delete(object)
|
||||
define delete {
|
||||
complete($1);
|
||||
lifestart_$1 = lifestart_$1 - awid;
|
||||
drawx($1);
|
||||
}
|
||||
|
||||
# Draw a message return(from_object,to_object,label)
|
||||
define return_message {
|
||||
down;
|
||||
move spacing;
|
||||
# See comment in message
|
||||
if ($1.x <= $2.x) then {
|
||||
off_from = awid * .6;
|
||||
off_to = -awid * .6;
|
||||
} else {
|
||||
off_from = -awid * .6;
|
||||
off_to = awid * .6;
|
||||
}
|
||||
|
||||
# add half a box width for each level of nesting
|
||||
if (active_$1 > 1) then {
|
||||
off_from = off_from + (active_$1 - 1) * awid/2;
|
||||
}
|
||||
|
||||
# add half a box width for each level of nesting
|
||||
if (active_$2 > 1) then {
|
||||
off_to = off_to + (active_$2 - 1) * awid/2;
|
||||
}
|
||||
|
||||
arrow from ($1.x + off_from, Here.y) to ($2.x + off_to, Here.y) dashed $3 " ";
|
||||
}
|
||||
|
||||
define rmessage {
|
||||
return_message($1,$2,$3);
|
||||
}
|
||||
|
||||
# Object becomes active
|
||||
# Can be nested to show recursion
|
||||
define active {
|
||||
extend_lifeline($1);
|
||||
# draw top of new active box
|
||||
line right awid from ($1.x + (active_$1 - 1) * awid/2, Here.y);
|
||||
active_$1 = active_$1 + 1;
|
||||
}
|
||||
|
||||
# Object becomes inactive
|
||||
# Can be nested to show recursion
|
||||
define inactive {
|
||||
extend_lifeline($1);
|
||||
active_$1 = active_$1 - 1;
|
||||
# draw bottom of innermost active box
|
||||
line right awid from ($1.x + (active_$1 - 1) * awid/2, Here.y);
|
||||
}
|
||||
|
||||
# Time step
|
||||
# Useful at the beginning and the end
|
||||
# to show object states
|
||||
define step {
|
||||
down;
|
||||
move spacing;
|
||||
}
|
||||
|
||||
# Switch to asynchronous messages
|
||||
define async {
|
||||
arrowhead = 0;
|
||||
arrowwid = arrowwid * 2;
|
||||
}
|
||||
|
||||
# Switch to synchronous messages
|
||||
define sync {
|
||||
arrowhead = 1;
|
||||
arrowwid = arrowwid / 2;
|
||||
}
|
||||
|
||||
# same as lifeline_constraint, but Text and empty string are exchanged.
|
||||
define lconstraint_below{
|
||||
off_from = awid;
|
||||
# add half a box width for each level of nesting
|
||||
if (active_$1 > 1) then {
|
||||
off_from = off_from + (active_$1 - 1) * awid/2;
|
||||
}
|
||||
|
||||
box at ($1.x + off_from, Here.y) invis "" $2 ljust;
|
||||
}
|
||||
|
||||
# begin_frame(left_object,name,label_text);
|
||||
define begin_frame {
|
||||
# The lifeline will be cut here
|
||||
extend_lifeline($1);
|
||||
# draw the frame-label
|
||||
$2: box $3 invis with .n at ($1.x, Here.y);
|
||||
d = $2.e.y - $2.se.y;
|
||||
line from $2.ne to $2.e then down d left d then to $2.sw;
|
||||
# continue the lifeline below the frame-label
|
||||
move to $2.s;
|
||||
lifestart_$1 = Here.y;
|
||||
}
|
||||
|
||||
# end_frame(right_object,name);
|
||||
define end_frame {
|
||||
# dummy-box for the lower right corner:
|
||||
box invis "" with .s at ($1.x, Here.y);
|
||||
# draw the frame
|
||||
frame_wid = last box.se.x - $2.nw.x
|
||||
frame_ht = - last box.se.y + $2.nw.y
|
||||
box with .nw at $2.nw wid frame_wid ht frame_ht;
|
||||
# restore Here.y
|
||||
move to last box.s;
|
||||
}
|
||||
|
||||
# comment(object,[name],[line_movement], [box_size] text);
|
||||
define comment {
|
||||
old_y = Here.y
|
||||
# draw the first connecting line, at which's end the box wil be positioned
|
||||
move to ($1.x, Here.y)
|
||||
if "$3" == "" then {
|
||||
line comment_default_move() dashed;
|
||||
} else {
|
||||
line $3 dashed;
|
||||
}
|
||||
|
||||
# draw the box, use comment_default_xx if no explicit
|
||||
# size is given together with the text in parameter 4
|
||||
old_boxht=boxht;
|
||||
old_boxwid=boxwid;
|
||||
boxht=comment_default_ht;
|
||||
boxwid=comment_default_wid;
|
||||
if "$2" == "" then {
|
||||
box invis $4;
|
||||
} else {
|
||||
$2: box invis $4;
|
||||
}
|
||||
boxht=old_boxht;
|
||||
boxwid=old_boxwid;
|
||||
|
||||
# draw the frame of the comment
|
||||
line from last box.nw \
|
||||
to last box.ne - (corner_fold, 0) \
|
||||
then to last box.ne - (0, corner_fold) \
|
||||
then to last box.se \
|
||||
then to last box.sw \
|
||||
then to last box.nw ;
|
||||
line from last box.ne - (corner_fold, 0) \
|
||||
to last box.ne - (corner_fold, corner_fold) \
|
||||
then to last box.ne - (0, corner_fold) ;
|
||||
|
||||
# restore Here.y
|
||||
move to ($1.x, old_y)
|
||||
}
|
||||
|
||||
# connect_to_comment(object,name);
|
||||
define connect_to_comment {
|
||||
old_y = Here.y
|
||||
# start at the object
|
||||
move to ($1.x, Here.y)
|
||||
# find the best connection-point of the comment to use as line-end
|
||||
if $1.x < $2.w.x then {
|
||||
line to $2.w dashed;
|
||||
} else {
|
||||
if $1.x > $2.e.x then {
|
||||
line to $2.e dashed;
|
||||
} else {
|
||||
if Here.y < $2.s.y then {
|
||||
line to $2.s dashed;
|
||||
} else {
|
||||
if Here.y > $2.n.y then {
|
||||
line to $2.n dashed;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
# restore Here.y
|
||||
move to ($1.x, old_y)
|
||||
}
|
||||
|
|
@ -0,0 +1,67 @@
|
|||
/**
|
||||
* @hidden
|
||||
* @opt nodefontcolor "blue"
|
||||
*/
|
||||
class UMLNoteOptions{}
|
||||
|
||||
/**
|
||||
* Structural Things
|
||||
* @opt commentname
|
||||
* @note Notes can
|
||||
* be extended to
|
||||
* span multiple lines
|
||||
*/
|
||||
class Structural{}
|
||||
|
||||
/**
|
||||
* spelling.java
|
||||
* @opt shape component
|
||||
* @opt commentname
|
||||
* @note Component
|
||||
*/
|
||||
class Component extends Structural{}
|
||||
|
||||
/** @opt shape node */
|
||||
class Node extends Structural{}
|
||||
|
||||
/**
|
||||
* Chain of
|
||||
* responsibility
|
||||
* @opt shape collaboration
|
||||
* @opt commentname
|
||||
* @note Collaboration
|
||||
*/
|
||||
class Collaboration extends Structural{}
|
||||
|
||||
/**
|
||||
* Place order
|
||||
* @opt shape usecase
|
||||
* @opt commentname
|
||||
* @note Use Case
|
||||
*/
|
||||
class UseCase extends Structural{}
|
||||
|
||||
/**
|
||||
* Business rules
|
||||
* @opt shape package
|
||||
* @opt commentname
|
||||
* @note Package
|
||||
*/
|
||||
class Package{}
|
||||
|
||||
/**
|
||||
* @opt all
|
||||
* @note Class
|
||||
*/
|
||||
class Counter extends Structural {
|
||||
static public int counter;
|
||||
public int getCounter();
|
||||
}
|
||||
|
||||
/**
|
||||
* @opt shape activeclass
|
||||
* @opt all
|
||||
* @note Active Class
|
||||
*/
|
||||
class RunningCounter extends Counter{}
|
||||
|
||||
|
After Width: | Height: | Size: 3.3 KiB |
|
|
@ -0,0 +1,42 @@
|
|||
# UML User Guide: Figure 18-2
|
||||
#
|
||||
#
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
boxwid = 1.1;
|
||||
movewid = 0.5;
|
||||
|
||||
# Define the objects
|
||||
object(C,"c:Client");
|
||||
pobject(T);
|
||||
object(P,"p:ODBCProxy");
|
||||
|
||||
# Message sequences
|
||||
step();
|
||||
active(C);
|
||||
cmessage(C,T,":Transaction");
|
||||
oconstraint("{Transient}");
|
||||
step();
|
||||
message(C,T,"setActions(a,d,o)");
|
||||
active(T);
|
||||
message(T,P,"setValues(d,3.4)");
|
||||
active(P);
|
||||
step();
|
||||
inactive(P);
|
||||
message(T,P,"setValues(a,\"CO\")");
|
||||
active(P);
|
||||
rmessage(T,C,"committed");
|
||||
inactive(T);
|
||||
inactive(P);
|
||||
async(); dmessage(C,T);
|
||||
step();
|
||||
inactive(C);
|
||||
step();
|
||||
|
||||
complete(C);
|
||||
complete(P);
|
||||
|
||||
.PE
|
||||
|
|
@ -0,0 +1,51 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The following diagram, based on the one appearing on p. 247 of the
|
||||
UML User Guide, illustrates the dynamic creation and destruction of
|
||||
objects, an object constraint, and the changing of the focus of control.
|
||||
<h2>Diagram</h2>
|
||||
<img src="uml-182.gif" alt="UML User Guide: Figure 18-2, p. 247" />
|
||||
<h2>Diagram Source Code</h2>
|
||||
<fmtcode ext="pic">
|
||||
# UML User Guide: Figure 18-2
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
boxwid = 1.1;
|
||||
movewid = 0.5;
|
||||
|
||||
# Define the objects
|
||||
object(C,"c:Client");
|
||||
pobject(T);
|
||||
object(P,"p:ODBCProxy");
|
||||
|
||||
# Message sequences
|
||||
step();
|
||||
active(C);
|
||||
cmessage(C,T,":Transaction");
|
||||
oconstraint("{Transient}");
|
||||
step();
|
||||
message(C,T,"setActions(a,d,o)");
|
||||
active(T);
|
||||
message(T,P,"setValues(d,3.4)");
|
||||
active(P);
|
||||
step();
|
||||
inactive(P);
|
||||
message(T,P,"setValues(a,\"CO\")");
|
||||
active(P);
|
||||
rmessage(T,C,"committed");
|
||||
inactive(T);
|
||||
inactive(P);
|
||||
async(); dmessage(C,T);
|
||||
step();
|
||||
inactive(C);
|
||||
step();
|
||||
|
||||
complete(C);
|
||||
complete(P);
|
||||
|
||||
.PE
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,44 @@
|
|||
# UML User Guide: Figure 18-4
|
||||
#
|
||||
#
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
movewid = 0.5;
|
||||
|
||||
# Define the objects
|
||||
object(S,"s:Caller");
|
||||
object(W,":Switch");
|
||||
pobject(C);
|
||||
object(R,"r:Caller");
|
||||
|
||||
# Message sequences
|
||||
step();
|
||||
active(W);
|
||||
async(); message(S,W,"liftReceiver"); sync();
|
||||
active(S);
|
||||
message(W,S,"setDialTone()");
|
||||
async(); message(S,W,"*dialDigit(d)"); sync();
|
||||
lconstraint(W,"{dialing.executionTime < 30s}");
|
||||
active(W);
|
||||
message(W,W,"routeCalls(s,n)");
|
||||
inactive(W);
|
||||
cmessage(W,C,"c:Convers");
|
||||
active(C);
|
||||
message(C,R,"ring()");
|
||||
active(R);
|
||||
async(); message(R,C,"liftReceiver"); sync();
|
||||
message(C,W,"connect(r,s)");
|
||||
message(W,S,"connect(r)");
|
||||
# Specify label as a "constraint" to allign on W
|
||||
message(W,R,""); lconstraint(W,"connect(s)");
|
||||
step();
|
||||
|
||||
complete(S);
|
||||
complete(W);
|
||||
complete(C);
|
||||
complete(R);
|
||||
|
||||
.PE
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The following diagram, based on Figure 18-4 appearing on p. 252 of the
|
||||
UML User Guide, illustrates constraints on an object's lifeline,
|
||||
used both as genuine constraints, and to place a message label
|
||||
on a particular position.
|
||||
In addition, this diagram also uses nested activation.
|
||||
<h2>Diagram</h2>
|
||||
<img src="uml-184.gif" alt="UML User Guide: Figure 18-4, p. 252" />
|
||||
<h2>Diagram Source Code</h2>
|
||||
<fmtcode ext="pic">
|
||||
# UML User Guide: Figure 18-4
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
movewid = 0.5;
|
||||
|
||||
# Define the objects
|
||||
object(S,"s:Caller");
|
||||
object(W,":Switch");
|
||||
pobject(C);
|
||||
object(R,"r:Caller");
|
||||
|
||||
# Message sequences
|
||||
step();
|
||||
active(W);
|
||||
async(); message(S,W,"liftReceiver"); sync();
|
||||
active(S);
|
||||
message(W,S,"setDialTone()");
|
||||
async(); message(S,W,"*dialDigit(d)"); sync();
|
||||
lconstraint(W,"{dialing.executionTime < 30s}");
|
||||
active(W);
|
||||
message(W,W,"routeCalls(s,n)");
|
||||
inactive(W);
|
||||
cmessage(W,C,"c:Convers");
|
||||
active(C);
|
||||
message(C,R,"ring()");
|
||||
active(R);
|
||||
async(); message(R,C,"liftReceiver"); sync();
|
||||
message(C,W,"connect(r,s)");
|
||||
message(W,S,"connect(r)");
|
||||
# Specify label as a "constraint" to allign on W
|
||||
message(W,R,""); lconstraint(W,"connect(s)");
|
||||
step();
|
||||
|
||||
complete(S);
|
||||
complete(W);
|
||||
complete(C);
|
||||
complete(R);
|
||||
|
||||
.PE
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
# UML User Guide Figure 7-1.
|
||||
#
|
||||
#
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
actor(A,"");
|
||||
object(T,":OTaker");
|
||||
object(F,":OFulfill");
|
||||
step();
|
||||
|
||||
message(A,T,"submitOrder");
|
||||
message(T,F,"placeOrder");
|
||||
message(F,A,"acknowledgeOrder");
|
||||
|
||||
step();
|
||||
complete(A);
|
||||
complete(T);
|
||||
complete(F);
|
||||
|
||||
.PE
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The following diagram, based on Figure 7-1 appearing on p. 102 of the
|
||||
UML User Guide, illustrates an interaction diagram with an
|
||||
external actor.
|
||||
<h2>Diagram</h2>
|
||||
<img src="uml-71.gif" alt="UML User Guide: Figure 7-1, p. 102" />
|
||||
<h2>Diagram Source Code</h2>
|
||||
<fmtcode ext="pic">
|
||||
# UML User Guide Figure 7-1.
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
actor(A,"");
|
||||
object(T,":OTaker");
|
||||
object(F,":OFulfill");
|
||||
step();
|
||||
|
||||
message(A,T,"submitOrder");
|
||||
message(T,F,"placeOrder");
|
||||
message(F,A,"acknowledgeOrder");
|
||||
|
||||
step();
|
||||
complete(A);
|
||||
complete(T);
|
||||
complete(F);
|
||||
|
||||
.PE
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,39 @@
|
|||
# UML User Guide: Appendix A,p. 436
|
||||
#
|
||||
#
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
# Define the objects
|
||||
pobject(E,"External Messages");
|
||||
object(T,"t:thread");
|
||||
object(O,":Toolkit");
|
||||
pobject(P);
|
||||
|
||||
step();
|
||||
|
||||
# Message sequences
|
||||
message(E,T,"a1: run(3)");
|
||||
active(T);
|
||||
message(T,O,"run()");
|
||||
active(O);
|
||||
message(O,O,"callbackLoop()");
|
||||
cmessage(O,P,"p:Peer"," ");
|
||||
active(O);
|
||||
message(O,P,"handleExpose()");
|
||||
active(P);
|
||||
rmessage(P,O,"");
|
||||
inactive(P);
|
||||
inactive(O);
|
||||
dmessage(O,P);
|
||||
inactive(T);
|
||||
inactive(O);
|
||||
|
||||
step();
|
||||
|
||||
complete(T);
|
||||
complete(O);
|
||||
|
||||
.PE
|
||||
|
|
@ -0,0 +1,50 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
The following diagram, based on the one appearing on p. 436 of the
|
||||
UML User Guide, contains the most important elements
|
||||
of an interaction.
|
||||
It also uses nested
|
||||
<em>active</em> <em>inactive</em> calls to show a nested object activation.
|
||||
<h2>Diagram</h2>
|
||||
<img src="uml-appa.gif" alt="UML User Guide: Appendix A, p. 436" />
|
||||
<h2>Diagram Source Code</h2>
|
||||
<fmtcode ext="pic">
|
||||
# UML User Guide: Appendix A,p. 436
|
||||
|
||||
.PS
|
||||
|
||||
copy "sequence.pic";
|
||||
|
||||
# Define the objects
|
||||
pobject(E,"External Messages");
|
||||
object(T,"t:thread");
|
||||
object(O,":Toolkit");
|
||||
pobject(P);
|
||||
|
||||
step();
|
||||
|
||||
# Message sequences
|
||||
message(E,T,"a1: run(3)");
|
||||
active(T);
|
||||
message(T,O,"run()");
|
||||
active(O);
|
||||
message(O,O,"callbackLoop()");
|
||||
cmessage(O,P,"p:Peer"," ");
|
||||
active(O);
|
||||
message(O,P,"handleExpose()");
|
||||
active(P);
|
||||
rmessage(P,O,"");
|
||||
inactive(P);
|
||||
inactive(O);
|
||||
dmessage(O,P);
|
||||
inactive(T);
|
||||
inactive(O);
|
||||
|
||||
step();
|
||||
|
||||
complete(T);
|
||||
complete(O);
|
||||
|
||||
.PE
|
||||
</fmtcode>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,476 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
<dl>
|
||||
|
||||
<dt>Version 5.7 Under development </dt><dd>
|
||||
<ul>
|
||||
<li>The <code>@opt include</code> option can be used to include classes from
|
||||
foreign packages in the package view (unless hidden with <code>@opt hide</code>).</li>
|
||||
<li>You can now also use <code>@opt</code> in <code>package-info.java</code>.</li>
|
||||
<li>Added <code>-qualifyGenerics</code> option to separately control the inclusion of
|
||||
package names for the class (<code>-qualify</code>) and its generics. In particular
|
||||
this works well with <code>-qualify -postfixpackage</code> (and <code>-!qualifyGenerics</code>).<br />
|
||||
To get the old <code>-qualify</code> behavior, you need to add <code>-qualifyGenerics</code>,
|
||||
the default is off, and it will not inherit from <code>-qualify</code>.</li>
|
||||
<li>Better handling of complex names with generics and inner classes such as <code>pkg.Outer<T>.Inner</code>.</li>
|
||||
<li>Use <i> tags for italic, because the old font naming approach does not work with SVG anymore.
|
||||
Replace <code>-nodefontabstractname</code> and <code>-nodefontclassabstractname</code>
|
||||
with a simple flag <code>-nodefontabstractitalic</code> instead.</li>
|
||||
<li>Added <code>-hideprivateinner</code> to hide all private inner classes.</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 5.6 2012-05-31 </dt><dd>
|
||||
<ul>
|
||||
<li>Maven artifact deployment</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 5.5 2012-05-13 </dt><dd>
|
||||
<ul>
|
||||
<li>Added ability to make aggregate relationships (<code>@has</code> and
|
||||
<code>@composed</code>) navigable through the new <code>@navhas</code>
|
||||
and <code>@navcomposed</code> relationships.
|
||||
(Contributed by Alan Jeffrey.)</li>
|
||||
<li>Make UMLGraphDoc generation compatible with JDK 7
|
||||
(Contributed by Stefano Martina.)</li>
|
||||
<li>Moved project's source code repository hosting to
|
||||
<a href="https://github.com/dspinellis/UMLGraph">GitHub</a>.</li>
|
||||
<li>Various documentation improvements.</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 5.4 2011-01-08</dt><dd>
|
||||
<ul>
|
||||
<li>Make the generation of diamond shapes compatible with GraphViz 2.27.
|
||||
(Contributed by Soraya Santana de la Fe.)</li>
|
||||
<li>Make the diagram elements appearing in HTML content clickable.
|
||||
(Contributed by Bernd Onasch.)</li>
|
||||
<li>Fix to ensure that class images only appear once.
|
||||
(Contributed by Zhigang Xie.)</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 5.3 2010-05-24</dt><dd>
|
||||
<ul>
|
||||
<li>Sequence diagrams provide an option to specify whether objects are
|
||||
underlined or not.</li>
|
||||
<li>Documentation generated with UMLGraph will process correctly
|
||||
non-ASCII characters.
|
||||
(Fix contributed by Gunho Kim.)</li>
|
||||
<li>New <code>-dotexecutable</code> option allows the explicit specification of
|
||||
<em>dot</em>'s location.
|
||||
(Contributed by Laird Nelson.)</li>
|
||||
<li><em>UmlGraphDoc</em> will obey the options specified through
|
||||
<code>@opt</code> tags within Java files.
|
||||
(Contributed by Laird Nelson.)</li>
|
||||
<li>Use a logical font rather than a font file name for italics.
|
||||
This fixes a problem with unresolved fonts under Windows and
|
||||
modern versions of Graphviz.
|
||||
(Suggested by Przemyslaw Szufel.)</li>
|
||||
<li>Support for <em>javadoc</em>'s <code>-linkoffline</code> option.
|
||||
(Contributed by Nikita Kozlov.)</li>
|
||||
<li>Do not show relations of hidden fields.
|
||||
(Fix contributed by Cimballi.)</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 5.2 2008-12-03</dt><dd>
|
||||
<ul>
|
||||
<li> Corrected case of the tools.jar filename in the umlgraph shell script.
|
||||
(Reported by Øyvind Jergan).
|
||||
</li>
|
||||
<li> Fixed exception when an unknown class dependency is specified.
|
||||
(Reported by Jan Schlüter).
|
||||
</li>
|
||||
<li> Corrected NullPointerException occurring when no global options were
|
||||
available.
|
||||
(Fix supplied by Bernd Blacha.)</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 5.1 2008-08-27 </dt><dd>
|
||||
<ul>
|
||||
<li> Active classes now appear with a double vertical border, following UML2.</li>
|
||||
<li>Reorganized the documentation of class diagram options.</li>
|
||||
<li> New class diagram options <code>-nodesep</code> and <code>-ranksep</code>,
|
||||
which allow fine control of the generated diagram layout.
|
||||
(Patch submitted by Trustin Lee.)
|
||||
</li>
|
||||
<li> A class's title will appear as a tooltip in image files that support this
|
||||
feature.
|
||||
(Patch submitted by Anthony Callegaro.)
|
||||
</li>
|
||||
<li>
|
||||
Nested class hyperlinks to Javadoc documentation now work correctly.
|
||||
(Patch submitted by David P. Caldwell.)
|
||||
</li>
|
||||
<li>
|
||||
The guillemot characters are now output with their Unicode HTML numeric
|
||||
escapes instead of their HTML symbolic values.
|
||||
This makes the output work correctly on Mac OS X, and is also easier
|
||||
to validate with XML tools.
|
||||
(Patch submitted by Joshua Lim.)
|
||||
</li>
|
||||
<li>
|
||||
UmlGraphDoc now supports Javascript-collapsible UML diagrams.
|
||||
A new option <code>-collapsible</code> can be used to enable this
|
||||
feature.
|
||||
(Patch submitted by Franz Wilhelmstoetter.)
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 5.0 2007-11-29 </dt><dd>
|
||||
<ul>
|
||||
<li> All code now lives under <code>org.umlgraph</code>.
|
||||
This change requires corresponding modifications to the UMLGraph
|
||||
callers.</li>
|
||||
<li> Add support for six new shapes: node, component, package, collaboration,
|
||||
usecase, and activeclass.
|
||||
These shapes require GraphViz 2.16 or newer.
|
||||
</li>
|
||||
<li> A new <code>@note</code> tag allows the annotation of elements with comments.
|
||||
(Suggested by Sébastien Pierre.)
|
||||
</li>
|
||||
<li> A new <code>@commentname</code> option allows the naming of elements
|
||||
with the text of the <em>javadoc</em> comment.</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 4.9 2007-09-28 </dt><dd>
|
||||
<ul>
|
||||
<li> <b>Note that from this version UMLGraph requires JDK 6.</b></li>
|
||||
<li> Added installation instructions. </li>
|
||||
<li> Improved documentation for invoking UmlGraph. </li>
|
||||
<li> Command-line scripts for invoking UmlGraph from Windows and Unix. </li>
|
||||
<li> Test data is now compatible with the output of the JDK 6 javadoc</li>
|
||||
<li> Java 6.0 deprecated methods are marked in the code as such.</li>
|
||||
<li> The -noguillemot option now outputs escaped characters compatible
|
||||
with version 1.13 of Graphviz.
|
||||
(reported by Roger Alexander).</li>
|
||||
<li> Fix inferred relations of maps to primitive Java types.
|
||||
(reported by Przemyslaw Wesolek).</li>
|
||||
</ul></dd>
|
||||
|
||||
<dt>Version 4.8 2007-05-10 </dt><dd>
|
||||
<ul>
|
||||
<li> This is the last version compatible with Java 1.5.</li>
|
||||
<li> UmlGraph can now be invoked directly as a jar file. </li>
|
||||
<li> Support for sending results to the standard output for piping into <em>dot</em>. </li>
|
||||
<li> The distribution includes an example shell script and batch file for
|
||||
invoking UmlGraph. </li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 4.7 2007-03-26 </dt><dd>
|
||||
<ul>
|
||||
<li> Correct the build file for generating the UmlGraph
|
||||
javadocs under Unix (Dirk Datzert)</li>
|
||||
<li> Correct output of UmlGraphDoc path-relative file names under Windows
|
||||
(fix by: Panagiotis Astithas)</li>
|
||||
<li> Fix InvocationTargetException when a relative output file name is
|
||||
given (reported by: Georgios Gousios)</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 4.6 2007-02-05</dt><dd>
|
||||
<ul>
|
||||
<li>Portability fix so that UmlGraphDoc can now run again under Unix (bug introduced in version 4.5).</li>
|
||||
<li>Note: Image maps and the UmlGraphDoc tests will not work correctly with dot 2.12; see <a href="http://www.graphviz.org/bugs/b1069.html">this GraphViz problem report</a>.</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 4.5 2006-12-14</dt><dd>
|
||||
<ul>
|
||||
<li>Correct running of the UmlGraphDoc tests</li>
|
||||
<li>Correct the JavaDoc generation (Maxim Butov)</li>
|
||||
<li>Correct appearance of generic names (Ivan F. Villanueva B.)</li>
|
||||
<li>UmlGraphDoc now handles filenames with embedded spaces (reported and tested
|
||||
by Jörn Guy Süß and Christophe DENEUX)</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 4.4 2006-07-19 </dt><dd>
|
||||
<ul>
|
||||
<li>Major new functionality: UmlGraphDoc, a new doclet that can generate context and package
|
||||
class diagrams integrated with the standard javadoc output. Uses the same switches
|
||||
as UmlGraph. (Andrea Aime)</li>
|
||||
<li>Removed -verbose2 option, use the standard -quiet option instead to avoid UmlGraphDoc and
|
||||
UmlGraph printing notices. (Andrea Aime)</li>
|
||||
<li>Added a -inferdepvis option that allows to control which member of a class will be used
|
||||
for dependency inference. Acceptable values are private, package, protected and public.
|
||||
Makes sense when inferring dependencies without using -useimports.</li>
|
||||
<li>Added a -inferdepinpackage option that enables dependency inference among classes in the
|
||||
same package. This is disabled by default, since there is no reliable way to infer
|
||||
dependencies, and classes in the same package are supposed to be related anyway.</li>
|
||||
<li>Support the -link flag in the same way as the standard doclet, in order to populate
|
||||
the api doc map, used to generate image maps with links to associated external classes.
|
||||
</li>
|
||||
<li> Filter-out the static initializer method from classes (Andreas Studer)</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 4.3 2006-03-05 </dt><dd>
|
||||
<ul>
|
||||
<li> Now using HTML labels in dot files. This allows for a different font
|
||||
in each row of the class nodes. Added options
|
||||
to control fonts for class names, packages and tags. (Andrea Aime)
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 4.2 (internal release) </dt><dd>
|
||||
<ul>
|
||||
<li> Correct the handling of qualified class names following
|
||||
the extends keyword (Arnaud Rogues).</li>
|
||||
<li> Relationship inference support. When enabled UMLGraph will try to
|
||||
compute relationships and dependecies by field/method/import
|
||||
statements examination. (Andrea Aime)
|
||||
</li>
|
||||
<li> Standard class lookup for association targets. The target can be
|
||||
specified by name without the need to include the full package
|
||||
information, imports and standard visibility rules will be applied
|
||||
to determine the actual class (Andrea Aime)
|
||||
</li>
|
||||
<li> A <em>views</em> feature provides the ability to specify
|
||||
option overrides for classes satisfying specific conditions
|
||||
and to generate multiple diagrams in a single doclet invocation.
|
||||
See the new tags @view, @match and the command line
|
||||
parameters -d, -view, -views (Andrea Aime)</li>
|
||||
<li> Options can be reset to their default value using the "@opt !option"
|
||||
syntax (useful for local overrides and in views) (Andrea Aime)</li>
|
||||
<li> Javadoc documentation (Andrea Aime).</li>
|
||||
<li> Centralized option handling in the Option class (even for command line
|
||||
arguments) (Andrea Aime).</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 4.1 2005-11-15</dt><dd>
|
||||
<ul>
|
||||
<li> Major source code reorganization to move closer to the Java coding
|
||||
conventions.
|
||||
The user-visible change is that the doclet is now invoked as
|
||||
<fmtcode ext="sh">
|
||||
javadoc -docletpath UmlGraph.jar -doclet gr.spinellis.umlgraph.doclet.UmlGraph
|
||||
</fmtcode>
|
||||
</li>
|
||||
<li> Show package visibility for class members (Olek Poplavskyy). </li>
|
||||
<li> Prevent crash when processing erroneous relation specifications (Andrea Aime).</li>
|
||||
<li> Most loops were refarctored to use the typesafe Java 1.5 foreach construct. </li>
|
||||
<li> Fix Eclipse warning (Andrea Aime).</li>
|
||||
<li> Better control of class hiding.
|
||||
Now classes are hidden even when involved in a relationship with a visible class
|
||||
(Andrea Aime).</li>
|
||||
<li> Source code modifications to allow Java-based testing (Andrea Aime).</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 3.3 2005-10-19</dt><dd>
|
||||
<ul>
|
||||
<li> The sequence diagrams now include support for drawing
|
||||
comments and frames. (Contributed by Sebastian Setzer)</li>
|
||||
<li> The -noguillemot option will output two angle bracket pairs
|
||||
instead of round brackets around stereotypes.</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 3.2 2005-07-19</dt><dd>
|
||||
<ul>
|
||||
<li> Display the template arguments of generic classes inside angle brackets.
|
||||
Note that according to the UML specification these arguments should
|
||||
be displayed in a dashed box on the top right of the class.
|
||||
However, such a display is currently not possible in GraphViz.</li>
|
||||
<li> Display the type parameters of fields and method arguments. </li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 3.1 2005-03-26</dt><dd>
|
||||
<ul>
|
||||
<li> <b>Note that from this version UMLGraph requires Java 1.5.</b></li>
|
||||
<li> First step of the Java 1.5 transition; more will follow.</li>
|
||||
<li> The container code in the source was changed to use the Java 1.5 generics.</li>
|
||||
<li> Will display enumerations as a stereotyped primitive type.
|
||||
Two new options <code>-enumerations</code> and <code>-enumconstants</code>
|
||||
control the corresponding operation.</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.10 2004-11-19</dt><dd>
|
||||
<ul>
|
||||
<li> This is the last version compatible with Java 1.4.</li>
|
||||
<li> Corrected the interaction between the
|
||||
<code>-attributes</code> and
|
||||
<code>-operations</code> options and classes with no
|
||||
fields or methods.
|
||||
Many thanks to Jonathan Wright for this contribution. </li>
|
||||
<li>New documentation look, designed by George Zouganelis</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.9 2004-10-07</dt><dd>
|
||||
<ul>
|
||||
<li> Class diagrams can now include constructors, through the new
|
||||
<code>-constructors</code> option.</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.8 2004-08-09</dt><dd>
|
||||
<ul>
|
||||
<li> Fixes to support the Maven plugin.</li>
|
||||
<li> From this version onward, use the appropriate options to create
|
||||
documentation links; no hyperlinks are created by default.</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.7 2004-08-06</dt><dd>
|
||||
<ul>
|
||||
<li> The -noguillemot option will output round brackets around stereotypes,
|
||||
instead of angle brackets.
|
||||
The angle brackets appear to be breaking some programs.
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.6 2004-08-03</dt><dd>
|
||||
<ul>
|
||||
<li> <b>Note that from this version UMLGraph requires Java 1.4.</b></li>
|
||||
<li> Documentation example: multiple views from the same source.
|
||||
Many thanks to Vadim Nasardinov for this contribution. </li>
|
||||
<li> Documentation now includes a FAQ section. </li>
|
||||
<li> Documented the fact that package names must be explicitly
|
||||
specified in tags. Arne Bayer noticed the associated problem. </li>
|
||||
<li> Correct handling of multiple space in tags.
|
||||
Noted by Jeffrey M. Thompson which the help of
|
||||
<a href="http://findbugs.sourceforge.net/">FindBugs</a>.
|
||||
</li>
|
||||
<li> Completed customization of URL mapping. Now the mapping is fully
|
||||
configurable and can be controlled by the use of two new options:
|
||||
"-apiDocRoot" and -"apiDocMapFileName".
|
||||
This change allows the creation of "clickable"
|
||||
diagrams fully integrated with web-based documentation
|
||||
(for example JavaDoc pages).
|
||||
The upcoming UMLGraph Maven plugin will take full advantage of this feature.
|
||||
Implementation contributed by Nascif Abousalh-Neto
|
||||
</li>
|
||||
<li> The -hide argument now accepts regular expressions. </li>
|
||||
<li> Removed copy-pasted Java code that was introduced in version 1.24.</li>
|
||||
<li> Some dot edges were missing a semicolon. This is now fixed. </li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.5 2004-06-15</dt><dd>
|
||||
The object swimlanes in a sequence diagram
|
||||
can now show nested object invocations.
|
||||
This very useful and non-trivial change was contributed by Jonathan R. Santos.
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.4 2004-05-29</dt><dd>
|
||||
Will now generate local URL hyperlinks for packages specified in
|
||||
the command line; and links to the Sun documentation for all
|
||||
other packages.
|
||||
Many thanks to Nascif Abousalh-Neto for contributing this change.
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.3 2004-05-27</dt><dd>
|
||||
<ul>
|
||||
<li>
|
||||
Remove hardcoded default node and edge fonts.
|
||||
Thanks to Vadim Nasardinov for submitting the corresponding patch.
|
||||
</li>
|
||||
<li>
|
||||
Generate javadoc hyperlink paths in a directory-tree structure;
|
||||
do not show arcs on hidden classes.
|
||||
Thanks to Alessandro Riva for submitting the corresponding patch.
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.2 2004-05-25</dt><dd>
|
||||
SVG class diagrams containing guillemot characters
|
||||
for stereotypes
|
||||
can now be made valid through a new -outputencoding option.
|
||||
Use "-outputencoding UTF-8" when using dot to generate SVG diagrams.
|
||||
Many thanks to Nascif Abousalh-Neto for bringing this problem to
|
||||
my attention.
|
||||
</dd>
|
||||
|
||||
<dt>Version 2.1 2004-05-16</dt><dd>
|
||||
The guillemot characters used for the create and destroy stereotypes
|
||||
are now portable between <em>groff</em> and <em>pic2plot</em>.
|
||||
Many thanks to Scott Johnson (Duluth, MN) for recommending the change.
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>Version 2.0 2004-05-09</dt><dd>
|
||||
<ul>
|
||||
<li> Support for drawing sequence diagrams.</li>
|
||||
<li> New distribution format.</li>
|
||||
<li> Browsable and printable documentation.</li>
|
||||
<li> Removed the <em>ant</em>-based compilation and distribution
|
||||
system; it was proving a hindrance in organizing the project in
|
||||
a resonable manner.
|
||||
Compiling the documentation and distribution is now handled by
|
||||
a (non-distributed) Makefile; the compilation process is described
|
||||
in the README file.
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
|
||||
<dt>Version 1.24 2003-07-30</dt><dd>
|
||||
Changes by Art Hampton (thanks):
|
||||
<ul>
|
||||
<li> Create the appropriate label for relationship tags when referring to
|
||||
classes which were not parsed by javadoc.
|
||||
</li>
|
||||
<li> New "-hide <matchstring>" option, where <matchstring>
|
||||
matches the end of the name of an entity.
|
||||
Matched entities are removed from the graph.
|
||||
A regular expression matching facility will be added when Java 1.4
|
||||
becomes more widespread.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
</dd>
|
||||
<dt>Version 1.23 2003-05-7</dt><dd>
|
||||
Added <code>-output</code> command-line option, and an <em>ant</em>-based
|
||||
build file.
|
||||
Modified the dot output to avoid triggering a graphviz bug that made escape codes visible.
|
||||
|
||||
</dd>
|
||||
<dt>Version 1.20 2003-04-25</dt><dd>
|
||||
Fixes by Nick Efthymiou (thanks):
|
||||
will generate SVG hyperlinks to Javadoc documentation,
|
||||
better handling of abstract class fonts,
|
||||
and correct listing of interfaces.
|
||||
</dd>
|
||||
<dt>Version 1.19 2002-09-20</dt><dd>
|
||||
New options:
|
||||
nodefontname,
|
||||
nodefontabstractname,
|
||||
nodefontsize,
|
||||
nodefontcolor,
|
||||
edgefontname,
|
||||
edgefontsize,
|
||||
edgefontcolor,
|
||||
edgecolor,
|
||||
bgcolor.
|
||||
|
||||
</dd>
|
||||
<dt>Version 1.18 2002-08-26</dt><dd>
|
||||
<ul>
|
||||
<li> Can now specify class-local options.
|
||||
</li>
|
||||
<li> Support for the @tagvalue tag.
|
||||
</li>
|
||||
<li> Support for the @stereotype tag.
|
||||
</li>
|
||||
<li> Added nodefillcolor option.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
</dd>
|
||||
<dt>Version 1.15 2002-07-26</dt><dd>First public release.
|
||||
</dd>
|
||||
</dl>
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,51 @@
|
|||
<?xml version="1.0" ?>
|
||||
<notes>
|
||||
Documenting a big project often requires multiple diagrams:
|
||||
each to show a specific and limited portion of the system.
|
||||
Each diagram is usually composed of few classes, possibily using a different detail level.<p/>
|
||||
The <code>@view</code> tag, marks a special class used to describe a single class diagram.
|
||||
Similarly to UMLOptions, the view can define its own general options,
|
||||
but allows to define <em>overrides</em> that allow to adopt different options
|
||||
for different classes based on regular expressions matching.
|
||||
The general syntax for defining a view is:
|
||||
<fmtcode ext="java">
|
||||
/**
|
||||
* @view
|
||||
* @opt [!]viewOption1
|
||||
* @opt [!]viewOption2
|
||||
* ...
|
||||
* @match matchtype regularExpression1
|
||||
* @opt [!]option1.1 [argument]
|
||||
* @opt [!]option1.2 [argument]
|
||||
* ...
|
||||
* @match matchtype regularExpression2
|
||||
* @opt [!]option2.1 [argument]
|
||||
* @opt [!]option2.2 [argument]
|
||||
* ...
|
||||
*/
|
||||
</fmtcode>
|
||||
|
||||
At the moment UMLGraph supports only the 'class' match type, in the future
|
||||
other types of match will be added (tags, implemented interfaces,
|
||||
superclasses, just to name a few possibilities).<br/>
|
||||
The view options are applied to every class in the view (so they are the
|
||||
global options for this class diagram).<br/>
|
||||
The regular expression will be used to match a single class, a group of
|
||||
classes, or a package, and the options that follow will be applied to
|
||||
those classes. <br/>
|
||||
Multiple matches will be evaluted in the order of specification.<br/>
|
||||
Refer to the <a href="http://java.sun.com/j2se/1.5.0/docs/api/java/util/regex/Pattern.html">Pattern</a>
|
||||
class documentation for details on a proper regular expression specification.
|
||||
|
||||
<p/>Each view will generate a .dot file whose name is the name of the view,
|
||||
unless the "output" option is specified to override it.
|
||||
|
||||
<h2>View inheritance</h2>
|
||||
View classes can inherit from other view classes, allowing views to
|
||||
share a set of common matches. The standard java inheritance mechanism
|
||||
is used to specify inheritance.<br/>
|
||||
Abstract view classes won't be used to generate diagrams, the common
|
||||
idiom is to declare a base abstract view to share common options and
|
||||
overrides, and have concrete view classes that extend for diagram generation.
|
||||
|
||||
</notes>
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
|
||||
/**
|
||||
* Attribute and operation visility
|
||||
* UML User Guide p. 123
|
||||
*
|
||||
* @opt operations
|
||||
* @opt attributes
|
||||
* @opt types
|
||||
* @opt visibility
|
||||
* @hidden
|
||||
*/
|
||||
class UMLOptions {}
|
||||
|
||||
/** @hidden */
|
||||
class Tool {}
|
||||
|
||||
class Toolbar {
|
||||
protected Tool currentSelection;
|
||||
protected Integer toolCount;
|
||||
public void pickItem(Integer i) {}
|
||||
public void addTool(Tool t) {}
|
||||
public void removeTool(Integer i) {}
|
||||
public Tool getTool() {}
|
||||
protected void checkOrphans() {}
|
||||
private void compact() {}
|
||||
}
|
||||
168
index.html
|
|
@ -1,168 +0,0 @@
|
|||
<?xml version="1.0" encoding="us-ascii"?>
|
||||
<!DOCTYPE html
|
||||
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||
<!-- No not edit this page in the web directory. -->
|
||||
<!-- $Id$ -->
|
||||
<head>
|
||||
<title>UMLGraph - Declarative Drawing of UML Diagrams</title>
|
||||
<meta name="AUTHOR" content="Diomidis Spinellis" />
|
||||
</head>
|
||||
<body>
|
||||
<h1 align="right"><tt><font color="#ff0000">UMLGraph dds</font></tt></h1>
|
||||
<h2>UMLGraph - Declarative Drawing of UML Diagrams</h2>
|
||||
<!-- Introduction {{{1 -->
|
||||
UMLGraph allows the declarative specification and drawing of
|
||||
UML class and sequence diagrams.
|
||||
The current features
|
||||
are part of an ongoing effort aiming to provide support for
|
||||
all types UML diagrams.
|
||||
An <em>IEEE Software</em> article titled
|
||||
<a href="../../pubs/jrnl/2003-IEEESW-umlgraph/html/article.html">On the declarative specification of models</a>
|
||||
explains the rationale behind this approach.
|
||||
The tehnology behind UMLGraph was used to draw many of the diagrams
|
||||
appearing in the book
|
||||
<a href="http://www.spinellis.gr/codereading">Code Reading: The Open Source Perspective</a> (Addison Wesley, 2003).
|
||||
In addition,
|
||||
<a href="http://lightuml.sourceforge.net/">LightUML</a>
|
||||
integrates UMLGraph into <a href="http://www.eclipse.org">Eclipse</a>,
|
||||
and <a href="http://maven-plugins.sourceforge.net/maven-dotuml-plugin/">Dotuml</a> integrates UMLGraph into <a href="http://maven.apache.org/">Maven</a>.
|
||||
Furthermore,
|
||||
the Politecnico Di Torino SoftEng group has extended UMLGraph into
|
||||
the <a href="http://softeng.polito.it/projects/XUG/">XUG</a>
|
||||
reverse engineering tool, and
|
||||
Adam Feuer's
|
||||
<a href="http://www.python.org/pypi/PyUMLGraph">PyUMLGraph</a>
|
||||
system applies the concept to Python programs,
|
||||
|
||||
Finally,
|
||||
<a href="http://martinfowler.com">Martin Fowler</a> writes:
|
||||
<blockquote>
|
||||
I thought I'd send you a note saying how much I enjoyed discovering UML Graph. I've long fancied a text based way of describing UML diagrams, but never felt sufficiently time-rich to develop anything.
|
||||
</blockquote>
|
||||
Martin has created a
|
||||
<a href="http://martinfowler.com/bliki/UmlSketchingTools.html">bliki entry</a>
|
||||
describing his ideas of what an ideal textual language might look like.
|
||||
|
||||
<h3>Class Diagrams</h3> <!-- {{{1 -->
|
||||
One specifies a class diagram using the Java syntax complemented by
|
||||
<a href="http://java.sun.com/j2se/javadoc/"><em>javadoc</em></a>
|
||||
tags.
|
||||
Running the UmlGraph doclet on the specification will generate
|
||||
a
|
||||
<a href="http://www.research.att.com/sw/tools/graphviz/">Graphviz</a>
|
||||
diagram specification that can be automatically processed to
|
||||
create Postscript, GIF, SVG, JPEG, fig, or Framemaker drawings.
|
||||
<p />
|
||||
The following is an example of a class diagram specification and the resulting UML
|
||||
diagram:
|
||||
<table>
|
||||
<tr><td>
|
||||
<pre>
|
||||
class Person {
|
||||
String Name;
|
||||
}
|
||||
|
||||
class Employee extends Person {}
|
||||
|
||||
class Client extends Person {}
|
||||
</pre>
|
||||
</td><td>
|
||||
<img src="doc/class-eg.gif" alt="Simple UML class diagram" />
|
||||
</td></tr></table>
|
||||
|
||||
<h3>Sequence Diagrams</h3> <!-- {{{1 -->
|
||||
One specifies a sequence diagram using <em>pic</em> macros to define
|
||||
objects and method invocations.
|
||||
The <a href="http://www.gnu.org/software/plotutils/plotutils.html">GNU plotutils</a>
|
||||
<em>pic2plot</em> program can then process the sequence diagram to create a
|
||||
PNG, PNM, (pseudo)GIF, SVG, AI, Postscript, CGM, FIG, PCL, HPGL, Regis, or TEK
|
||||
drawing.
|
||||
<p />
|
||||
The following is an example of a sequence diagram specification and the
|
||||
resulting UML diagram:
|
||||
<table>
|
||||
<tr><td>
|
||||
<pre>
|
||||
# Define the objects
|
||||
object(O,"o:Toolkit");
|
||||
placeholder_object(P);
|
||||
step();
|
||||
|
||||
# Activation and messages
|
||||
active(O);
|
||||
message(O,O,"callbackLoop()");
|
||||
create_message(O,P,"p:Peer");
|
||||
message(O,P,"handleExpose()");
|
||||
active(P);
|
||||
return_message(P,O,"");
|
||||
inactive(P);
|
||||
destroy_message(O,P);
|
||||
inactive(O);
|
||||
|
||||
# Complete the lifeline of O
|
||||
step();
|
||||
complete(O);
|
||||
</pre>
|
||||
</td><td>
|
||||
<img src="doc/seq-eg.gif" alt="Simple UML sequence diagram" />
|
||||
</td></tr></table>
|
||||
|
||||
<h3>Download and Links</h3> <!-- {{{1 -->
|
||||
UMLGraph is hereby made freely available as Open Source Software.
|
||||
The current version of UMLGraph is VERSION.
|
||||
You can download UMLGraph and its documentation from the following links:
|
||||
<ul>
|
||||
<li> <a href="UMLGraph-VERSION.tar.gz">UmlGraph package version VERSION - .tar.gz</a>
|
||||
(compressed tar file containing the source code, the compiled doclet,
|
||||
and the complete documentation in HTML format).
|
||||
</li>
|
||||
<li> <a href="UMLGraph-VERSION.zip">UmlGraph package version VERSION - .zip</a>
|
||||
(zip file containing the source code, the compiled doclet,
|
||||
and the complete documentation in HTML format).
|
||||
</li>
|
||||
<li> <a href="doc/index.html">Documentation</a>
|
||||
(table of contents - suitable for web browsing).
|
||||
</li>
|
||||
<li> <a href="doc/indexw.html">Printable documentation</a>
|
||||
(the above as a single printable page).
|
||||
</li>
|
||||
<li> <a href="doc/ver.html">Version history</a> </li>
|
||||
<li> <a href="http://freshmeat.net/projects/umlgraph/">freshmeat.net page</a> (use it to subscribe and post comments).</li>
|
||||
<li> <a href="UMLGraph-2.10.tar.gz">UmlGraph package version 2.10 - .tar.gz</a>
|
||||
(The last version compatible with Java 1.4; compressed tar file containing the source code, the compiled doclet,
|
||||
and the complete documentation in HTML format).
|
||||
</li>
|
||||
<li> <a href="UMLGraph-2.10.zip">UmlGraph package version 2.10 - .zip</a>
|
||||
(The last version compatible with Java 1.4; zip file containing the source code, the compiled doclet,
|
||||
and the complete documentation in HTML format).
|
||||
</li>
|
||||
<li> <a href="jars/UmlGraph-VERSION.jar">UmlGraph binary - UmlGraph-VERSION.jar</a>
|
||||
(jar file containing only the UmlGraph classes;
|
||||
please use this only for pulling UmlGraph into other projects).
|
||||
</li>
|
||||
<li> <a href="CHECKSUM.MD5">MD5 checksums</a> for each of the above .zip, .tar.gz, and jar archives.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<!-- End matter {{{1 -->
|
||||
<p />
|
||||
<a href="../../">Diomidis Spinellis home page</a>
|
||||
<hr />
|
||||
<table>
|
||||
<tr><td>
|
||||
<a href="http://validator.w3.org/check/referer"><img src="../../valid-xhtml10.png" border="0" alt="Valid XHTML 1.0!" height="31" width="88" /></a>
|
||||
<a href="http://www.w3.org/WAI/WCAG1AAA-Conformance" title="Explanation of Level Triple-A Conformance"><img border="0" height="32" width="88" src="../../wcag1AAA.gif" alt="Level Triple-A conformance icon, W3C-WAI Web Content Accessibility Guidelines 1.0" /></a>
|
||||
</td><td>
|
||||
<font size="-2">
|
||||
(C) Copyright 2002-2005 D. Spinellis.
|
||||
May be freely uploaded by WWW viewers and similar programs.
|
||||
All other rights reserved.
|
||||
<br />
|
||||
Last modified: $Date$
|
||||
</font>
|
||||
</td></tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
<?xml version="1.0"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.umlgraph</groupId>
|
||||
<artifactId>umlgraph</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<name>UMLGraph</name>
|
||||
<version>${version}</version>
|
||||
<description>Declarative Drawing of UML Diagrams</description>
|
||||
<url>http://www.spinellis.gr/umlgraph</url>
|
||||
|
||||
<licenses>
|
||||
<license>
|
||||
<name>BSD License (original)</name>
|
||||
<url>http://www.opensource.org/licenses/bsd-license.php</url>
|
||||
<distribution>repo</distribution>
|
||||
</license>
|
||||
</licenses>
|
||||
|
||||
<scm>
|
||||
<url>https://github.com/dspinellis/UMLGraph</url>
|
||||
<connection>git://github.com/dspinellis/UMLGraph.git</connection>
|
||||
</scm>
|
||||
|
||||
<developers>
|
||||
<developer>
|
||||
<id>dspinellis</id>
|
||||
<name>Diomidis Spinellis</name>
|
||||
<email>dds@aueb.gr</email>
|
||||
</developer>
|
||||
</developers>
|
||||
|
||||
<dependencies/>
|
||||
|
||||
</project>
|
||||
|
|
@ -0,0 +1,156 @@
|
|||
<?xml version="1.0"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.umlgraph</groupId>
|
||||
<artifactId>umlgraph</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<name>UMLGraph</name>
|
||||
<version>6.0.1-SNAPSHOT</version>
|
||||
<description>Declarative Drawing of UML Diagrams</description>
|
||||
<url>http://www.spinellis.gr/umlgraph</url>
|
||||
|
||||
<licenses>
|
||||
<license>
|
||||
<name>BSD License (original)</name>
|
||||
<url>http://www.opensource.org/licenses/bsd-license.php</url>
|
||||
<distribution>repo</distribution>
|
||||
</license>
|
||||
</licenses>
|
||||
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
<scm>
|
||||
<url>https://github.com/dspinellis/UMLGraph/</url>
|
||||
<connection>scm:git://github.com/dspinellis/UMLGraph.git</connection>
|
||||
<developerConnection>scm:git:git@github.com:dspinellis/UMLGraph.git</developerConnection>
|
||||
<tag>R5_7_1</tag>
|
||||
</scm>
|
||||
|
||||
<developers>
|
||||
<developer>
|
||||
<id>dspinellis</id>
|
||||
<name>Diomidis Spinellis</name>
|
||||
<email>dds@aueb.gr</email>
|
||||
</developer>
|
||||
</developers>
|
||||
|
||||
<parent>
|
||||
<groupId>org.sonatype.oss</groupId>
|
||||
<artifactId>oss-parent</artifactId>
|
||||
<version>9</version>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>junit</groupId>
|
||||
<artifactId>junit</artifactId>
|
||||
<version>4.13.2</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>src/main/resources</directory>
|
||||
<filtering>true</filtering>
|
||||
</resource>
|
||||
</resources>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.10.1</version>
|
||||
<configuration>
|
||||
<source>9</source>
|
||||
<target>9</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-jar-plugin</artifactId>
|
||||
<version>3.3.0</version>
|
||||
<configuration>
|
||||
<archive>
|
||||
<manifest>
|
||||
<addClasspath>true</addClasspath>
|
||||
<mainClass>org.umlgraph.doclet.UmlGraph</mainClass>
|
||||
</manifest>
|
||||
</archive>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-release-plugin</artifactId>
|
||||
<version>3.0.0-M7</version>
|
||||
<configuration>
|
||||
<autoVersionSubmodules>true</autoVersionSubmodules>
|
||||
<useReleaseProfile>false</useReleaseProfile>
|
||||
<releaseProfiles>release</releaseProfiles>
|
||||
<goals>deploy</goals>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-source-plugin</artifactId>
|
||||
<version>3.2.1</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>attach-sources</id>
|
||||
<goals>
|
||||
<goal>jar</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
<version>3.5.0</version>
|
||||
<configuration>
|
||||
<tags>
|
||||
<tag>
|
||||
<name>depend</name>
|
||||
<placement>X</placement>
|
||||
</tag>
|
||||
<tag>
|
||||
<name>hidden</name>
|
||||
<placement>X</placement>
|
||||
</tag>
|
||||
<tag>
|
||||
<name>opt</name>
|
||||
<placement>X</placement>
|
||||
</tag>
|
||||
</tags>
|
||||
<doclet>org.umlgraph.doclet.UmlGraphDoc</doclet>
|
||||
<docletPath>${project.build.directory}${file.separator}${project.build.finalName}.jar</docletPath>
|
||||
<additionalOptions>
|
||||
<option>-inferrel</option>
|
||||
<option>-inferdep</option>
|
||||
<option>-autosize</option>
|
||||
<option>-collapsible</option>
|
||||
<option>--hide="java.*"</option>
|
||||
<option>--collpackages=</option>
|
||||
<option>-qualify</option>
|
||||
<option>-postfixpackage</option>
|
||||
<option>-nodefontsize 9</option>
|
||||
<option>-nodefontpackagesize 7</option>
|
||||
<option>--link="https://docs.oracle.com/javase/9/docs/api/"</option>
|
||||
</additionalOptions>
|
||||
<detectJavaApiLink>false</detectJavaApiLink>
|
||||
<useStandardDocletOptions>true</useStandardDocletOptions>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>attach-javadocs</id>
|
||||
<goals>
|
||||
<goal>jar</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||