From fe09e407d1c00ce1215674d9536515965807209e Mon Sep 17 00:00:00 2001 From: Andrea Aime Date: Thu, 5 Jan 2006 11:04:02 +0000 Subject: [PATCH] Relationship inference documentation --- doc/ceg-infer.xml | 49 ++++++++++++++++++++++++++++++++++++++++++++++ doc/index.xml | 1 + doc/infer.java | 38 +++++++++++++++++++++++++++++++++++ doc/infer.png | Bin 0 -> 1393 bytes doc/ver.xml | 6 +++++- 5 files changed, 93 insertions(+), 1 deletion(-) create mode 100644 doc/ceg-infer.xml create mode 100644 doc/infer.java create mode 100644 doc/infer.png diff --git a/doc/ceg-infer.xml b/doc/ceg-infer.xml new file mode 100644 index 0000000..01bfc34 --- /dev/null +++ b/doc/ceg-infer.xml @@ -0,0 +1,49 @@ + + + + +
+ +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 hide java.* + * @hidden + */ +class UMLOptions {} + +class Person { + House[] houses; + List dogs; + + public Room getFavouriteRoom(House house) {} +} + +/** + * @opt inferreltype composed + */ +class House { + Map nameRoomMap; +} + +class Room {} + +class Dog { + Person owner; +} + + + +UML diagram with relationship inference +
+ +

In this diagram we enabled both relationship and dependency inference.
+To make sure Person.dogs and Person.friends are interpreted as one to many relationship +the collpackage option has to be specified. + diff --git a/doc/index.xml b/doc/index.xml index 83133fd..03edd9d 100644 --- a/doc/index.xml +++ b/doc/index.xml @@ -8,6 +8,7 @@ Class Diagram Optionscd-opt Class Diagram Example: Generalisation Relationshipsceg-gen Class Diagram Example: Advanced Relationshipsceg-adv +Class Diagram Example: Relationships Inferenceceg-infer Class Diagram Example: Schemaceg-schema Class Diagram Example: Element Visibilityceg-ev Class Diagram Example: Association Typesceg-at diff --git a/doc/infer.java b/doc/infer.java new file mode 100644 index 0000000..8d9a34c --- /dev/null +++ b/doc/infer.java @@ -0,0 +1,38 @@ +/* + * Relationship inference + * $Id$ + */ + +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 hide java.* + * @hidden + */ +class UMLOptions {} + +class Person { + House[] houses; + List dogs; + + public Room getFavouriteRoom(House house) {} +} + +/** + * @opt inferreltype composed + */ +class House { + Map nameRoomMap; +} + +class Room {} + +class Dog { + Person owner; +} diff --git a/doc/infer.png b/doc/infer.png new file mode 100644 index 0000000000000000000000000000000000000000..487ab5598d149fe9ad2628e48511386a8e379259 GIT binary patch literal 1393 zcmV-%1&;cOP)0(n<%P*(; zzWV&u=}}q3vihEjsnSZzOlYzFE(?>>T`=pnRftx!S$scBH<%pOp0 zR%1}<%&I-=&1wYN$f$!#Z&qo}Q`P=fQfZ$$997V~+@so4z=P4&xoAD5De3L~7>>3= zP9PMYhN7yqG-w-?Qiq{dJ|@5xden*t zp}z7RgxUeKpjJj3RobwKn?XAht>um`q`{~iE(hwgPMy7{)G zL%~{dP^CAgr)cuNDEtICagsSR5h(K1>7a*uUaWirQHh3dN|y{ZnM4W;Kot>+NARIo zrG}vb4*>0pq(Ws8hAJx5Je$1!c?NERc2MmObfii`QTgG|A`Df61{Kw3J_k`CZ1oH- zC{X+=1%z$%I7Fbnz9?wRp?eP5*)X&Y1a1O6n+|RqT68eOQ)B# zg_`Gq-C)jjSu7jFqKBa-*q1v$YSQh7t-hSrgLdOk6Rg;Dqq_mRb1`k+WV19y6!1sf_)CCQ**%0F6*(nX3#E* zc3yT&;}CN6dL}0gb`H8z<8aJ|e*d?!)1*hw8%<0k3jQYbrS18k;MM3DQK&s)lnjOY zj~Jyv;VNa62t{tm83ob4{k>T5KK;GOg!gBM zfIbY?&55erVBO5

  • Correct the handling of qualified class names following the extends keyword (Arnaud Rogues).
  • +
  • Relationship inference support. When enabled UMLGraph will try to + compute relationships and dependecies by field/method/import + statements examination. (Andrea Aime) +
  • 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 + to determine the actual class (Andrea Aime)
  • A views feature provides the ability to specify package-based option overrides in UMLOptions like classes,