internal static void Main()
        {
            var db = new ToyStoreEntities();
            var ran = RandomDataGenerator.Instance;
            var factory = new SeederFactory(db, ran);

            db.Configuration.AutoDetectChangesEnabled = false;

            factory.GetManufacturerSeeder(50).Seed();
            factory.GetCategoriesSeeder(100).Seed();
            factory.GetAgeRangesSeeder(100).Seed();
            factory.GetToysSeeder(20000).Seed();

            db.Configuration.AutoDetectChangesEnabled = true;
        }
 public ToyStoreSeeder(ToyStoreEntities db, IRandomDataGenerator ran, int count)
 {
     this.ran = ran;
     this.db = db;
     this.count = count;
 }
 public AgeRangesSeeder(ToyStoreEntities db, IRandomDataGenerator ran, int count)
     : base(db, ran, count)
 {
 }
 public ManufacturerSeeder(ToyStoreEntities db, IRandomDataGenerator ran, int count)
     : base(db, ran, count)
 {
 }
 public SeederFactory(ToyStoreEntities db, IRandomDataGenerator ran)
 {
     this.db = db;
     this.ran = ran;
 }