电子商务领域模型反馈 [英] E-commerce Domain Model Feedback

查看:97
本文介绍了电子商务领域模型反馈的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在努力构建一个电子商务网站的粗略概念模型,该模型基本上允许用户转售演唱会门票。

I've been working on putting together a rough conceptual model of an E-commerce website that basically allows users to resell concert tickets. It's purely conceptual and not something i'm actually making!

无论如何,我已经提出了一个领域模型,希望得到一些反馈。我以前已经建立了类模型并为数据库建模,但是发现区分它们非常困难。

Anyway I've put together a domain model and I was hoping for some feedback. I've made class model before and modelled databases but found it quite difficult differentiating between them.

我已经看到很多单词富有和贫乏,我相信我的模型是贫血的。

I've seen the words rich and anaemic thrown around a lot and I believe my model is anaemic. Would simply notating more behaviour make it rich?

我的关系是否正确?我是否正确使用了我的汇总和构成?

Are my relationships correct? Have I correctly used my aggregations and compositions?

我希望对改进提出任何建议。

I would love any suggestions on improvements.

在此先感谢。

推荐答案

您的想法正确,但是某些UML是不正确的,并且(业务)域模型不应具有用户。

You have the right idea, but some of the UML is incorrect and a (business) domain model shouldn't have a User.

我看到的一些问题示例:

Some examples of problems I see:


  • 用户可能不是竞标者,卖方;相反,用户可以扮演投标人或卖方的角色。

  • 一般化没有多重性。

  • 对我来说,买票没有意义有一位艺术家。票证通常允许一个人入场表演,而艺人则可以在表演中演出。

  • 作品最多可以有一个创作班。

  • A User is probably not a Bidder and a Seller; rather, a User can play a Role of Bidder or Seller.
  • Generalizations do not have multiplicities.
  • It makes no sense to me for a Ticket to HAVE an Artist. A Ticket generally allows a Person to be admitted into a Show, and an Artist performs at a Show.
  • Compositions can have at most one composing class.

我将从概念模型中删除组成和聚合。否则,我不认为这是一个概念模型。下一步是将行为添加为OOA模型,并从中生成一些代码。请参阅Leon Starr的如何构建清晰的UML模型文章以获取更多帮助。

I would remove compositions and aggregations from a conceptual model. Otherwise, I don't think it's anemic as a conceptual model. The next step would be to add behavior to it as an OOA model and generate some code from it. Please see Leon Starr's How to Build Articulate UML Models article for more help.

这篇关于电子商务领域模型反馈的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆