银光+ RIA 实体域服务最佳实践:每个域有多少个实体?

发布于 2024-09-30 14:24:43 字数 163 浏览 0 评论 0原文

我有一个包含无数实体的数据库,我观看了 Tim Heuer 关于 Silverlight 和 Silverlight 的视频。 RIA Services,他解释了如何生成 DomainService。

我的问题是,我应该为每个实体使用许多域服务,还是将它们连同所有查询一起合并到一个大的域服务中?

I have a database with a gazillion entities, I watched Tim Heuer's video about Silverlight & RIA Services, and he explained how to generate a DomainService.

My question is, should I use many domain services for each entity or merge them all along with all their queries into one big DomainService?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

猛虎独行 2024-10-07 14:24:43

您通常会将域服务用于信息域(即相关实体)。

通常是:

  • 所有/大多数表/实体,或
  • 密切相关的表/实体组,或
  • 奇怪的单个表/实体

使用 RIA 服务,将它们一次性全部导入到单个模型中并让 RIA 吐出当然更容易出一个(非常大的)域服务文件。

请确保尝试新的RIA Services SP1(现在处于测试版),因为它现在支持复杂类型和其他一些新内容。

You would typically use a Domain Service for a domain of information (i.e. related entities).

That will usually be either:

  • all/most tables/entities, or
  • groups of closely related tables/entities, or
  • the odd single table/entity

With RIA services it is certainly easier to import them all at once into a single model and have RIA spit out one (very large) domain service file.

Make sure you try out the new RIA Services SP1 (now in Beta) as it now supports complex types and some other new stuff.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文