Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
N Tier Data Apps
Message
De
27/06/2010 12:39:30
James Blackburn
Qualty Design Systems, Inc.
Kuna, Idaho, États-Unis
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
Bases de données
Titre:
N Tier Data Apps
Versions des environnements
Environment:
C# 4.0
Divers
Thread ID:
01470721
Message ID:
01470721
Vues:
138
Hi All,

I must be missing something. I watched an App Dev movie about creating n tier data layers. This was done by first adding a class library for the data access layer (DAL) and the adding another class library for the business logic layer (BLL). Once this was done, a winform was created and the data class was bound to the form. I started looking at the sample code and I noticed the the DAL class was bound to the form. I can find no where the BLL class was used except the DLL class has a using for the BLL class.

This seams very strange to me because my assumption was the BLL class would be bound to the form and in turn the BLL class would use the DAL. Otherwise, how could the database be changed without changing the BLL clases as well. It has always been my assumption that the BLL should not know or care what the data store is.

What am I missing?

Here is the sample code used in the form.
    public Form1()
    {
      InitializeComponent();
    }

      private NorthwindDAL.NorthwindDataSetTableAdapters.CustomersTableAdapter customersTA = null;
      private NorthwindDAL.NorthwindDataSetTableAdapters.OrdersTableAdapter ordersTA = null;
      private NorthwindDAL.NorthwindDataSetTableAdapters.Order_DetailsTableAdapter orderDetailsTA = null;

    private void Form1_Load(object sender, EventArgs e)
    {
      customersTA = new NorthwindDAL.NorthwindDataSetTableAdapters.CustomersTableAdapter();
      ordersTA = new NorthwindDAL.NorthwindDataSetTableAdapters.OrdersTableAdapter();
      orderDetailsTA = new NorthwindDAL.NorthwindDataSetTableAdapters.Order_DetailsTableAdapter();

      customersTA.Fill(this.northwindDataSet.Customers);
      ordersTA.Fill(this.northwindDataSet.Orders);
      orderDetailsTA.Fill(this.northwindDataSet.Order_Details);
    }
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform