met
met

Reputation: 23

How to indicate in class diagram that an object will have versions?

I have a Text class. Objects of this class will have many versions. So there will be history of text changes. How to indicate this on class diagram properly? I need to show when it was changed and by who? Create class for text change? It is littlebit strange. Generalization?

Thanks for answer.

Upvotes: 1

Views: 78

Answers (1)

Satomi
Satomi

Reputation: 332

How's this diagram below? (I'm sorry if I am misunderstanding your description.) Also, the Memento design pattern may help you.

enter image description here

Upvotes: 2

Related Questions