Exemplo n.º 1
0
 /// <summary>
 /// Constructor<br/>
 /// -------------<br/>
 /// Inherited from constructor <see cref="ChangeLogContext(IDbMigrationConfig,string)"/><br/>
 /// SchemaPrefixId is assigned with value from <paramref name="model"/>(<see cref="IMigrationModel.GetMigrationConfig()"/>)  - method <see cref="IDbConfigSchemaTargets.GetSchemaPrefixId()"/><br/>
 /// SchemaPrefixUniqueId is assigned with value from <paramref name="model"/>(<see cref="IMigrationModel.GetMigrationConfig()"/>)  - method <see cref="IDbMigrationConfig.GetSchemaPrefixUniqueId()"/><br/>
 /// ShortName is assigned value from configuration database:migration:schemaPrefix:tables:{tableName}:ShortName or database:schemaPrefix:tables:{tableName}:ShortName<br/>
 /// GlobalId is assigned value from configuration database:migration:schemaPrefix:tables:{tableName}:GlobalId or database:schemaPrefix:tables:{tableName}:GlobalId<br/>
 /// <br/>
 /// i.e:<br/>
 /// When configuration have database:migration:schemaPrefix:Id = "PR" and database:migration:schemaPrefix:UniqueId = "abode" <br/>
 /// SchemaPrefixId will be resolved to "PR"<br/>
 /// SchemaPrefixUniqueId will be resolved to "abode"<br/>
 /// <br/>
 /// When <paramref name="tableName"/> is "testing", <br/>
 /// ShortName is fetched from database:migration:schemaPrefix:tables:testing:ShortName or database:schemaPrefix:tables:testing:ShortName<br/>
 /// GlobalId is fetched from database:migration:schemaPrefix:tables:testing:GlobalId or database:schemaPrefix:tables:testing:GlobalId<br/>
 /// </summary>
 /// <param name="model"></param>
 /// <param name="tableName"></param>
 public ChangeLogContext(IMigrationModel model, string tableName)
     : this(model?.GetMigrationConfig(), tableName)
 {
 }
Exemplo n.º 2
0
 public ChangeLogContext(IMigrationModel model)
     : this(model.GetMigrationConfig())
 {
     InitMetadata(model);
 }