예제 #1
0
        public void SaveMigrations(string path)
        {
            StoreSchemaMigrations package = _migrationAggregator.GenerateMigrations(Schema, SchemaMigrations, _designRecords);
            var fileName   = Path.Combine(path, GenerateMigrationFileName(path));
            var parameters = new StorageParameters {
                FileName = fileName
            };
            var schema = DesignSchemaConvert.ToStoreSchema(Schema);

            _schemaStorage.SaveMigration(package, parameters);
            SchemaMigrations = DesignSchemaMigrations.FromStoreMigrations(package);
            ClearLog();
        }
예제 #2
0
        public void SaveSchema(string path)
        {
            // Schema.VersionKey set during migration generation
            //if (Schema.Changed)
            //{
            //    Schema.VersionKey = Guid.NewGuid();
            //}

            var fileName   = Path.Combine(path, GenerateFileName(path));
            var parameters = new StorageParameters {
                FileName = fileName
            };
            var schema = DesignSchemaConvert.ToStoreSchema(Schema);

            _schemaStorage.SaveSchema(schema, parameters);

            // set all changed properties
            ClearChanged();

            // clear logs ?
        }