Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/duplicati/duplicati.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'Duplicati/Server/Database/Connection.cs')
-rw-r--r--Duplicati/Server/Database/Connection.cs14
1 files changed, 13 insertions, 1 deletions
diff --git a/Duplicati/Server/Database/Connection.cs b/Duplicati/Server/Database/Connection.cs
index ec5416f0d..12c5087fe 100644
--- a/Duplicati/Server/Database/Connection.cs
+++ b/Duplicati/Server/Database/Connection.cs
@@ -64,7 +64,18 @@ namespace Duplicati.Server.Database
using(var cmd = m_connection.CreateCommand())
f(cmd);
}
-
+
+ internal Serializable.ImportExportStructure PrepareBackupForExport(IBackup backup)
+ {
+ var scheduleId = GetScheduleIDsFromTags(new string[] { "ID=" + backup.ID });
+ return new Serializable.ImportExportStructure() {
+ CreatedByVersion = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString(),
+ Backup = (Database.Backup)backup,
+ Schedule = (Database.Schedule)(scheduleId.Any() ? GetSchedule(scheduleId.First()) : null),
+ DisplayNames = SpecialFolders.GetSourceNames(backup)
+ };
+ }
+
public string RegisterTemporaryBackup(IBackup backup)
{
lock(m_lock)
@@ -562,6 +573,7 @@ namespace Duplicati.Server.Database
foreach(var n in lst)
n.Metadata = GetMetadata(long.Parse(n.ID));
+
return lst;
}
}