Beispiel #1
0
 public static AgendaContext GetInstance()
 {
     if (_context == null)
     {
         Database.SetInitializer(new DropCreateDatabaseIfModelChanges<AgendaContext>());
         _context = new AgendaContext();
     }
     return _context;
 }
Beispiel #2
0
 public ContatoRepository()
 {
     _context = AgendaContext.GetInstance();
 }