ASP.Net layered communication
Posted
by Chris Klepeis
on Stack Overflow
See other posts from Stack Overflow
or by Chris Klepeis
Published on 2010-05-14T17:30:20Z
Indexed on
2010/05/14
17:34 UTC
Read the original article
Hit count: 181
Hi,
We're developing a layered web application. The specs:
- 3 layers, data layer, business layer, ui layer.
- Programmed in C#
- Data Layer uses the entity framework
Currently we plan on having the data layer return IEnumerable<T>
to the business layer via linq 2 entities, and the business layer will return data to the ui layer.
Since the ui layer has no knowledge of the existance of the data layer, how would it handle a result of IEnumerable passed to it from the BLL, where T is defined in the data layer?
Are there any GOOD example out there on how to do this. Please note that I'm extremely new to factories / interfaces / abstraction to loosely couple layers.
I saw the question here http://stackoverflow.com/questions/917457/passing-data-in-an-ntier-application and it was recommended to have the entity layer shared amongst all layers... however I do not want the other layers to be able to query the database.
© Stack Overflow or respective owner