命名空间/解决方案结构 [英] Namespace/solution structure

查看:145
本文介绍了命名空间/解决方案结构的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于我问这样一个问题普遍表示歉意,但它的东西,可以证明具有挑战性的我。我的团队是即将走上一个大的项目,希望能拖动已经经过多年演变随机一次性codebases一起所有。鉴于该项目将覆盖全公司(客户,员工),小任务,控制着小任务大任务,公用服务规范的逻辑实体,我挣扎找出来架构的最佳方式命名空间和code结构。

I apologize for asking such a generalized question, but it's something that can prove challenging for me. My team is about to embark on a large project that will hopefully drag together all of the random one-off codebases that have evolved through the years. Given that this project will cover standardizing logical entities across the company ("Customer", "Employee"), small tasks, large tasks that control the small tasks, and utility services, I'm struggling to figure out the best way to structure the namespaces and code structure.

虽然我想我不会给你足够的细节去,你有没有对如何处理你的分割高达域逻辑的任何资源或建议吗?万一有帮助,其中的大部分功能将通过网络服务来揭晓了,我们是一个微软店铺所有最新的小玩意和小工具。

Though I guess I'm not giving you enough specifics to go on, do you have any resources or advice on how to approach splitting your domains up logically? In case it helps, most of this functionality will be revealed via web services, and we're a Microsoft shop with all the latest gizmos and gadgets.


  • 我辩论与子项目一台庞大的解决方案,以方便引用,但会使得它太笨重?

  • 我应该包扎遗留应用程序的功能,或者离开这个完全不可知的命名空间(作出 OurCRMProduct.Customer 类与一般的客户类,例如)?

  • 如果每个服务/项目有它自己的 BAL DAL ,或者应该说是一个完全独立的程序集一切都引用?

  • I'm debating one massive solution with subprojects to make references easier, but will that make it too unwieldy?
  • Should I wrap up legacy application functionality, or leave that completely agnostic in the namespace (making an OurCRMProduct.Customer class versus a generic Customer class, for instance)?
  • Should each service/project have its own BAL and DAL, or should that be an entirely separate assembly that everything references?

我没有与组织如此深远的项目中,只有一次性的经验,所以我在寻找任何指导我可以得到的。

I don't have experience with organizing such far-reaching projects, only one-offs, so I'm looking for any guidance I can get.

推荐答案

有一百万方式皮肤猫。但是,最简单的一个是总是最好的。哪种方式是你最简单?取决于您的要求。但也有一些经验的一般规则我跟着。

There's a million ways to skin a cat. However, the simplest one is always the best. Which way is the simplest for you? Depends on your requirements. But there are some general rules of thumb I follow.

首先,减少的尽可能的项目的总数。当你编译一个一天二十次,额外分钟加起来。

First, reduce the overall number of projects as much as possible. When you compile twenty times a day, that extra minute adds up.

如果您的应用程序是专为可扩展性,可考虑沿设计与实现的路线分裂的组件。请将您的接口和基类中的一个公众集会。为您的企业的这些类的实现组装。

If your app is designed for extensibility, consider splitting your assemblies along the lines of design vs. implementation. Place your interfaces and base classes in a public assembly. Create an assembly for your company's implementations of these classes.

对于大型应用程序,让你的UI逻辑和业务逻辑分离。

For large applications, keep your UI logic and business logic separate.

简化您的解决方案。如果它看起来太复杂了,它可能是。结合,减少。

SIMPLIFY your solution. If it looks too complex, it probably is. Combine, reduce.

这篇关于命名空间/解决方案结构的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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