VivaVictoria.Chaos.ReflectionSqlReader
1.1.1
.NET Core 3.1
dotnet add package VivaVictoria.Chaos.ReflectionSqlReader --version 1.1.1
NuGet\Install-Package VivaVictoria.Chaos.ReflectionSqlReader -Version 1.1.1
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="VivaVictoria.Chaos.ReflectionSqlReader" Version="1.1.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add VivaVictoria.Chaos.ReflectionSqlReader --version 1.1.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: VivaVictoria.Chaos.ReflectionSqlReader, 1.1.1"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install VivaVictoria.Chaos.ReflectionSqlReader as a Cake Addin
#addin nuget:?package=VivaVictoria.Chaos.ReflectionSqlReader&version=1.1.1
// Install VivaVictoria.Chaos.ReflectionSqlReader as a Cake Tool
#tool nuget:?package=VivaVictoria.Chaos.ReflectionSqlReader&version=1.1.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
VivaVictoria.Chaos.Reflection
Install
Install via nuget.
Migration class
using VivaVictoria.Chaos.ReflectionSqlReader.Attributes;
using VivaVictoria.Chaos.ReflectionSqlReader.Interfaces;
namespace Migrations
{
[Migration(Version = 1, Name = "create table test", TransactionMode = TransactionMode.One)]
public class Migration_001_CreateTableTest : IReflectMigration {
public string Up()
{
return "create table test(id int primary key)";
}
public string Down()
{
return "drop table test";
}
}
}
Migration Attribute
Next code marks class as Migration class:
[Migration(Version = 1, Name = "create table test", TransactionMode = TransactionMode.One)]
Version and Name fields are required, TransactionMode is optional. If TransactionMode does not set or set to Default - Migrator will uses TransactionMode from ISettings.
Usage
Just use extension method:
var services = new ServiceCollection();
services.AddChaosReflection(typeof(Program).Assembly);
Product | Versions |
---|---|
.NET | net5.0 net5.0-windows net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows net7.0 net7.0-android net7.0-ios net7.0-maccatalyst net7.0-macos net7.0-tvos net7.0-windows |
.NET Core | netcoreapp3.1 |
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.
-
.NETCoreApp 3.1
- VivaVictoria.Chaos (>= 1.1.1)
- VivaVictoria.Chaos.Sql (>= 1.1.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
1.1.1 | 285 | 10/17/2021 |
1.1.1-preview | 145 | 10/7/2021 |
1.1.0 | 229 | 10/7/2021 |