public void Execute() { if (IsExecuted) { return; } for (int i = 0; i < MigrationCount; i++) { IMigration migration = GetMigration(i); if (migration != null) { migration.Execute(); } } if (OnExecuted != null) { OnExecuted(this, new MigrationServiceExecutedEventArgs(true)); } IsExecuted = true; HasMigrations = false; }