Exemplo n.º 1
0
 // IDisposable implementation
 protected void Dispose(bool disposing)
 {
     if (disposing)
     {
         if (_db != null)
         {
             _db.Dispose();
             _db = null;
         }
     }
 }
Exemplo n.º 2
0
 public ProductService()
 {
     _db = AdventureWorksDBEntities.Instance;
 }