using Semver;
using System.Threading.Tasks;
namespace LANCommander.SDK.Migrations;
public interface IMigration
{
///
/// The version of the Migration.
///
public SemVersion Version { get; }
///
/// Asynchronously determines whether the associated operation should be executed.
///
/// A task that represents the asynchronous operation. The task result is if the operation
/// should be executed; otherwise, .
public Task ShouldExecuteAsync();
///
/// Performs any necessary pre-checks before executing the migration.
///
/// A task that represents the asynchronous operation. The task result is if pre-checks pass; otherwise, .
public Task PerformPreChecksAsync();
///
/// Executes the migration asynchronously.
///
///
/// This will only be called if returns and returns .
///
public Task ExecuteAsync();
}