2015-06-19 12:03:02 +02:00
|
|
|
|
using System;
|
2021-02-18 11:06:02 +01:00
|
|
|
|
using Umbraco.Cms.Core.Models.Entities;
|
|
|
|
|
|
using Umbraco.Cms.Core.Semver;
|
2015-06-19 12:03:02 +02:00
|
|
|
|
|
2021-02-18 11:06:02 +01:00
|
|
|
|
namespace Umbraco.Cms.Core.Models
|
2015-06-19 12:03:02 +02:00
|
|
|
|
{
|
2018-01-15 11:32:30 +01:00
|
|
|
|
public class MigrationEntry : EntityBase, IMigrationEntry
|
2015-06-19 12:03:02 +02:00
|
|
|
|
{
|
|
|
|
|
|
public MigrationEntry()
|
|
|
|
|
|
{
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2015-06-24 14:17:24 +02:00
|
|
|
|
public MigrationEntry(int id, DateTime createDate, string migrationName, SemVersion version)
|
2015-06-19 12:03:02 +02:00
|
|
|
|
{
|
|
|
|
|
|
Id = id;
|
|
|
|
|
|
CreateDate = createDate;
|
|
|
|
|
|
_migrationName = migrationName;
|
|
|
|
|
|
_version = version;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-01-21 11:43:58 +01:00
|
|
|
|
private string? _migrationName;
|
|
|
|
|
|
private SemVersion? _version;
|
2015-06-19 12:03:02 +02:00
|
|
|
|
|
2022-01-21 11:43:58 +01:00
|
|
|
|
public string? MigrationName
|
2015-06-19 12:03:02 +02:00
|
|
|
|
{
|
2019-02-04 19:52:04 +11:00
|
|
|
|
get => _migrationName;
|
|
|
|
|
|
set => SetPropertyValueAndDetectChanges(value, ref _migrationName, nameof(MigrationName));
|
2015-06-19 12:03:02 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
2022-01-21 11:43:58 +01:00
|
|
|
|
public SemVersion? Version
|
2015-06-19 12:03:02 +02:00
|
|
|
|
{
|
2019-02-04 19:52:04 +11:00
|
|
|
|
get => _version;
|
|
|
|
|
|
set => SetPropertyValueAndDetectChanges(value, ref _version, nameof(Version));
|
2015-06-19 12:03:02 +02:00
|
|
|
|
}
|
|
|
|
|
|
}
|
2017-07-20 11:21:28 +02:00
|
|
|
|
}
|