EDIT 1
I apologize but after reading the 2 suggested articles I still don't understand what I should use. I understand that using IQueryable is not preferred for various reasons but does that eliminate IEnumerable as well? Is a DataTable really my best option?
In short, I guess, what is the preferred Return type?
I have the followi...
We are currently havin a discussion if dataset should go in the data or business layer?
My friend thinks all ADO.NET components should go in data layer. For me this does not seem right for the followin reasons:
If you create a fat Data Layer Client, it will be much more difficult to for example migrate everything to a different dat...
Hi,
I am using a layered architecture with the Entity Framework as my datalayer with a bunch of repositories on top which contain the Linq-To-Entities queries.
The data layer is one project, next to that I have a Services layer and the interface, which is a website.
I want my website to be responsible of specifying the connectionstring...
Being pretty unfamiliar with design patterns and architecture, I'm having trouble explaining to others exactly how my latest application is designed. I've switched between thinking it's a pure n-tier, pure MVC and n-tier with MVC in the presentation layer. Currently I think the latter is correct, but I want thoughts from more experienced...
Here is my situation: I am trying to follow as hard as I can the 3-tier pattern (i.e. Presentation, Business and Data layer). When I need data from the DB, the Business layer calls the Data layer which returns the information. The Data layer never return a SqlDataReader or DataTable object, but often an enumeration of custom object known...
I am working hard to standardize one single way of Layered/n-Tiered design of my all applications.
I am trying to make all my applications 5 tiered.
Code:
| UI |
|
| Business Object |
|
| OR-Mapper |
|
| Data Access |
|
| RDBMS |
Suppose I am developi...
Please first read the following thread:
http://stackoverflow.com/questions/924382/circular-reference-between-assemblies-in-c-and-visual-studio-2005
Implementing interfaces is solving my problem but not fulfilling my target.
My target is to work only with BO-layer/assembly from the UI layer/Assembly. So that I can maintain a clean la...
What is the best practise for returning an error of a business rule in a BLL? SHould I just raise exceptions and catch them in the presentation layer, shoudl I return some kind of object that holds any exception type info?
...
My opinion is it does and it doesn't.
It does separate logic and data from UI, but it still crams it all together into a single point application.
That's why I think it doesn't really, because Controllers are business logic, Views are UI, Models are DAL. These are now just layers within the same app.
But are layers supposed to be the...
Suppose you have three tiers (with namespaces):
User interface (App.UI) - calls business layer processes and communicates using objects
Business layer (App.Core) - orchestrates processes and uses DAL layer using objects
DAL (App.Data) - directly manipulates store and persists objects
Let's say that you have User table and thus reflec...
When adding user input to a web page, it should (unless it's HTML of course :) be encoded to help prevent XSS attacks etc.. like this:
litForename.Text = HttpUtility.HtmlEncode(MyUser.Forename);
I'm putting together a template to generate my business logic layer, and I'm thinking of using it to do all the encoding as soon as the data ...
Hi guys,
I've got a nice DAL generated using Subsonic. Is there a way I can generate a skeleton for the BLL? I don't want to plug the SS layer directly into my GUI.
I've trudged through both SS forums and it seems that everyone calls the SSS-generated layer a DAL, but they use it as a BLL.
Have you used SS and seperated the DAL and B...
Hi guys,
This is an embarrassingly basic n-tier question.
I've created a DAL project in VS2008 with subsonic. It's got a widget class, a widgetcollection class, and a widgetcontroller class.
I've created my Business logic project (no I can't put it in the same tier) that references it. Using certain business criteria, it selects a co...
Suppose I am developing an application for a product distributor in C#.
The distributor does the following 3 types of transactions:
(1) Indent
(2) Sell
(3) Stock
I am designing my classes as follows:
public abstract class Transaction
{
}
public class Indent : Transaction
{
}
public class Sell : Transaction
{
}
public class S...
I have a 3-tier .NET 2.0 app. The presentation layer references the middle tier. The middle tier references the database layer. For some reason, when I compile, the dll's for the data layer appear in the bin of the presentation layer. How do I stop this?
...
I'm currently on a co-op term working on a project nearing completion with one other co-op student. Since this project has been passed down from co-op to co-op, poor practices have been taken along the way and testing has been left until the end. I've decided I'd like to write unit-tests to learn something new while testing.
However, ...
I've set up a test database to begin unit-testing an app that I've recently been added to. It is a 3-tier design (presentation layer, BOL and DAL) and this is my first time writing unit tests.
I've decided to start at the BOL and I figure the best way is to swap out the ConnectionString (which has been passed along as a Shared String...
Hi. The question title might not be clear but what I want to do is something like this:
This is how I layer out my app
App.Domain
App.Services
App.Web
What I want is, if I request something like /api/OrderProcessor/GetAllOrder it will call method GetAllOrder in App.Services.OrderProcessorService.
The method will return an IL...
I read some articles about SqlCacheDependency. I think it is a really cool way for updating caches, but i'm not sure how i can handle this technologie if my application is a n-tier architekture.
Is this just useful if my program is a small webapplication, or is there also a way for use in big n-tier architektures?
...
So I have a MVC app and in another project I have a normal collection of classes which handle the Business and Data logic for the application. I also have some logic in the Model of the MVC project itself. This logic handles ViewModels and the like, things which could not have been done in the n-tier project as they relate to the MVC pro...