开发者

C# Business Logic, Business Objects, DataAccess, Project

I am currently looking at a solution with 5 projects in it. The are as follows: BusinessLogic, BusinessObjects, DataAccess, and the ActualProject Name. I am wondering what exactly th开发者_开发问答ese would each do?

Businesslogic: Has a folder in it called business manager. Here there is some methods possibly looking like this checks business rules?

BusinessObjects: Has 2 classes and both of them are just have a bunch of public variables with {get; set;} after them and nothing else in those classes.

DataAccess: Has 3 classes in them. 1 is under a folder called DataManagers and 1 is under a folder called QueryManagers.

ActualProject: This looks like it just contains the actual application logic and the app.config file.

Any insight into any of these would be appreciated!!!

Thanks


Sounds normal to me.

BusinessLogic Business logic pertaining to domain. Things like: "Ensure Order is Submitted with Price", etc. A central place to maintain business logic, very common (and recommended).

Business Objects Simple, POCO's (Plain Old CLR Objects) to represent domain models. No logic, just lightweight storage.

Data Access Handles persistence of domain objects against an underlying data store (ie SQL Server, Oracle, XML). Makes no assumptions about the behaviour domain objects, just that it's job is to retrieve/persist them.

ActualProject The UI - generally a web application, console, WPF, etc. A presentation layer for other projects.

This follows the Microsoft Best Practices (Seperation of Concerns): Business, Data, Presentation

Often other layers are involved, but these are the core three.


It seems that you are looking for solution that will natively allow you to decouple presentation / business logic / database aka three tier application architecture.

If so, you need application server to help you easily decouple, develop and maintance your businss logic. And that depends on platform your developing upon.

For Java platform there many open-sourced servers like glassfish or tomcat (google them). You can create web-services that represent your custom business logic and use persistances as well.

For .NET (C#, VB.NET etc.) based solution you shall need something like TNAPS .NET Application Server (check http://technovation.ru/tnaps) It provides all of the concepts you need - business objects, data access, user management, security.

There are a lot of stuff in Ruby / JavaScript world too (node.js / rails etc.). Everything depends on the needs of your solution. If it is corporate oriented business solution - than standart .NET approaches are great. Moreover you can expose this logic into web (saas) it anytime you like.

Finally, happened to notice your are using c# as a tag for question so check out TNAPS or other c# application servers (although there not many out there).


Business rules, business entities, storage and presentation.

You might want to take a look at this article and this one too.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜