business-logic-layer

Business Logic Layer

I am programming data driven applications using asp.net with telerik controls (v2009 q2). I have a class named BLL which contains (almost only) static classes that return different objects taking some id as parameter. The generally return group of objects as Lists. My question is that are there any architrectural flaws to this, always u...

Using Entity Framework generated classes in Business Logic Layer

I have a ASP.net (C#) project that is using a three layer architecture. I started to use Entity Framework in my DAL and the question is to what extent classes generated by Entity Framework can be used in the Business Logic Layer? It is a good idea to use them directly or should i create my own business objects and map to them from Ent...

Business Logic Classes Naming

I have a business layer that has some business objects/POCOs/entities/whatever. I also have some repositories for the data access. Up until this point, I've been accessing the repositories directly from my UI layer. I'm at a point where I actually need some more classes that aren't straight CRUD, so I'm going to create some business logi...

Business logic and services

In a three-tier/multitier architecture (UI/Logic/DAO/Domain model), can services be considered as belonging to the business logic layer or are they situated as something separate ? ...

C# anonymous type foreach looping

I need to loop through the properties of a custom object type that I'm getting back from the database and only show the columns that contain data. This means I cannot simply bind the list of objects to the datagrid. I don't want to loop through each object and see if the column is empty/null and determine in the UI to display it. What I'...

What should we have in a Business Logic Layer (BLL).

I know this is a very basic question. But I am really not able to comprehend what should we have in BLL. Let me take an example. Let us consider a Login.aspx web page, which is used to facilitate user login. In this case Login.aspx will have two textboxes and one login button.(Presentation Layer). Data Acess Layer will have functions to...

Can ASP.NET Dynamic Data be made to work with custom business objects rather than data objects?

I'm working on a project in which we have a database, data layer (entity framework), business layer and web/UI layer. I want to use ASP.NET Dynamic Data for the web layer, but don't want it to access the data layer or database, as I want it to be purely running off business logic, and not directly accessing the data. However, it appear...

Link between BO and GUI is broken. What to do?

I have some points (car stops) to represent on a time graph. These points are linked between them by lines. Points + Lines represent a Graph (that is a car schedule). The Graph can be modified by moving CarStops in time with the mouse. I decided to implement Points and Lines as controls (thought that will be easier to move them on the p...

Business layer: Looking for a complete reference ?

hi I'm studying business layer and need a complete reference which covers issues about "how to manage dependency between business layer and other layers", "how many ways are there to send data between layers" and most important for me "how to group business logic and make business component and talk about possible ways....". do you kn...

Separation of business logic

When I was optimizing my architecture of our applications in our website, I came to a problem that I don't know the best solution for. Now at the moment we have a small dll based on this structure: Database <-> DAL <-> BLL the Dal uses Business Objects to pass to the BLL that will pass it to the applications that uses this dll. Onl...

Design of Business Layer

Hi, We are currently revamping our architecture and design of application. We have just completed design of Data Access Layer which is generic in the sense that it works using XML and reflection to persist data. Any ways now we are in the phase of designing business layer. We have read some books related to Enterprise Architecture and ...

SWhen layering, what is the difference between Business Components and Business Services?

Hi: I'm trying to clear up a miscomprehension of the layering of an application. Think I may have something wrong... Up till now, I've only seen smallish apps and websites, each broken down as Data Layer, Services Layer, UI Layer. When WCF was involved, A second 'services' layer was inserted, with remote Proxies. The Data layer conta...

Where to catch exceptions

I have a WCF svc separated into a Service Layer, Business Logic Layer and Data Access Layer. When my DAL encounters an exception, should I catch it there or let it bubble back up to the Service Layer? And why? Please disregard any client involvement for this scenario, I am only concerned with logging the exceptions on the WCF svc. ...

DAL + BLL + LINQ + Enterprise Library 5 + .net 3.5

What are the Best practices for coding Data Access Layer and Business Logic Layer with combination of LINQ and Enterprise Library 5.0 in .net 3.5? ...

Authentication and authorisation in an n-tiered architecture

Hi, I need to be able to tighten my business layer - access to particular data. The UI can make a call to the business layer and receive a userdetail. The UI can then call .Save() on a user and the business layer will call the data access layer to save the user. Although, the problem here is that I don't just want any user to be able t...

Layered Architecture Question

Hello. I am developing an piece of software where I have a few entities such as: public class Workspace { public int ID { get; set; } public string Name { get; set; } public string Description { get; set; } public virtual List<Playground> Playground { get; set; } public virtual List<Workspa...

Business Layer structure, how do you build yours?

I am a big fan of NTiers for my development choices, of course it doesnt fit every scenario. I am currently working on a new project and I am trying to have a play with the way I normally work, and trying to see if I can clean it up. As I have been a very bad boy and have been putting too much code in the presentation layer. My normal ...

In what scenarios would i want to create custom business objects from Linq to Sql results?

A simple linq to SQL query Might return a product object. Obiously I could pass this object to my business layer, then read and update the data, directly against that object. I've seen a bunch of implementations where following the execution of the linq query the resulting object is mapped (via automapper or manually) to a custom busin...

Date Created - should this value be set in the BL or DAL?

Date Created a specific example I'm interested in - but there are other bits of data that fall into the same category: data which you'd want to capture about any vaguely important entity. Where best to do this: business logic (BL) or Data Access layer (DAL)? Until now I've relied on SQL Server's getdate() to populate the date created f...

Moving from custom n-tier OR/M to EF4

I currently have a custom ORM. I have a business layer, and data layer. My Data layer has all my CRUD operations. In the example below, I pass an Id to the constructor. This gets the record from the DB and fills the object with my person record: E.g. //Access through business layer Dim person as new Business.Person(Id:=1) person.Data...