Re: Circular dependency
- From: nyhetsgrupper@xxxxxxxxx
- Date: 30 Sep 2006 07:29:15 -0700
Thank you all for taking the time to answer. Can you explain in greater
detail what you mean Aaric? Which interfaces does each of your 3
projects expose? Does the Buisness object project keep datatypes only?
No logic? Doesn't that break the OO model to place the logic for an
object outside the object itself?
Aaric wrote:
I favor the option of separate projects as well. I typically have 3 separate
projects: 1)Data Access Layer, 2)Business Logic Layer, and 3)Business
Objects. Then both the Data Access Layer and the Business Logic Layer
reference the Business Objects project.
"nyhetsgrupper@xxxxxxxxx" wrote:
I'm trying to build a .NET application (C#) which I want to seperate
into the classic UI, Business Logic and Data Access layers.
I expected to seperate each layer into different projects and reference
each as required, when I try to do this I run into circular referencing
problems between the projects because the Data Access project
references the Business object project and vice versa.
The examples I have read from varous sources involve passing business
objects to the Data Access Layer to get them populated, normally this
happens in the constructor of the Data Access Layer - the Business
object creates a Data Access Object and passes itself in (as "this").
This is OK but in the examples the Data Access objects and the Business
objects reside in the same project so don't have the circular
referencing problems that I have.
I would be grateful for some help and examples.
.
- Follow-Ups:
- Re: Circular dependency
- From: Aaric
- Re: Circular dependency
- References:
- Circular dependency
- From: nyhetsgrupper
- Circular dependency
- Prev by Date: Re: newbie - How to test for null
- Next by Date: Password Remembering Plugin
- Previous by thread: Re: Circular dependency
- Next by thread: Re: Circular dependency
- Index(es):
Relevant Pages
|
Loading