开发者

How to represent repository pattern in UML?

开发者 https://www.devze.com 2023-04-03 21:34 出处:网络
How to represent Repository pattern in UML? Is there any stereotype that can be used to describe repository pattern? I am using Enterprise Architect to creat开发者_Python百科e diagrams. I specificall

How to represent Repository pattern in UML?

Is there any stereotype that can be used to describe repository pattern? I am using Enterprise Architect to creat开发者_Python百科e diagrams. I specifically looking for class diagram representation.


According to Martin Fowler, P of EAA, p. 322:

How to represent repository pattern in UML?

(However, you must have already found this since it's the first hit on Google.)

Based on this example (and the text from P of EAA), this roughly translates to the following DCD:

How to represent repository pattern in UML?


jensgram has already provided an answer on how to represent the pattern as classes.

When it comes to using patterns in EA, you can quite easily create them yourself using Save UML Pattern under the Diagram - Advanced menu. This saves an XML representation of the pattern.

You import the pattern for use in your project either using the Resources window or by creating an MDG Technology (more complex, but a much better alternative for medium and large-scale deployments).

Unfortunately, the one UML diagram type where EA does not support pattern creation is the sequence diagram.

0

精彩评论

暂无评论...
验证码 换一张
取 消