Index: Application/Ringtoets/src/Application.Ringtoets.Migration/RingtoetsProjectMigrator.cs
===================================================================
diff -u -rb6d487f36edb7b6ca133a0e26d1ab7bda4c6bab6 -r5ec759496df2662a183c1c5ed74e3724bd834ae2
--- Application/Ringtoets/src/Application.Ringtoets.Migration/RingtoetsProjectMigrator.cs (.../RingtoetsProjectMigrator.cs) (revision b6d487f36edb7b6ca133a0e26d1ab7bda4c6bab6)
+++ Application/Ringtoets/src/Application.Ringtoets.Migration/RingtoetsProjectMigrator.cs (.../RingtoetsProjectMigrator.cs) (revision 5ec759496df2662a183c1c5ed74e3724bd834ae2)
@@ -24,6 +24,7 @@
using System.Windows.Forms;
using Application.Ringtoets.Migration.Core;
using Application.Ringtoets.Migration.Properties;
+using Core.Common.Base.Storage;
using Core.Common.Gui;
using Core.Common.Utils;
using log4net;
@@ -37,7 +38,7 @@
///
/// A GUI implementation to migrate a Ringtoets database file to a newer version.
///
- public class RingtoetsProjectMigrator
+ public class RingtoetsProjectMigrator : IMigrateProject
{
private static readonly string currentProjectVersion = RingtoetsVersionHelper.GetCurrentDatabaseVersion();
@@ -63,18 +64,6 @@
Resources.RingtoetsProject_FileExtension);
}
- ///
- /// Indicates if the project needs to be
- /// updated to the newest version.
- ///
- /// The file path of the project which needs to be checked.
- /// true if the file needs to be migrated, false if:
- ///
- /// - The file does not need to be migrated.
- /// - The file is not supported for the migration.
- ///
- /// Thrown when is null.
- /// Thrown when is an invalid file path.
public bool ShouldMigrate(string sourceFilePath)
{
if (sourceFilePath == null)
@@ -102,18 +91,6 @@
return isVersionSupported;
}
- ///
- /// Migrates an outdated project file from
- /// to the newest project version version at a user defined target filepath.
- ///
- /// The project file which needs to be migrated.
- /// A filepath to the updated project file. null if:
- ///
- /// - The user cancelled.
- /// - The migration failed.
- ///
- /// Thrown when is null.
- /// Thrown when is an invalid file path.
public string Migrate(string sourceFilePath)
{
if (sourceFilePath == null)