using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Tango.PMR.Exports;
using Tango.Web;
namespace Tango.PPC.Common.BackupRestore
{
///
/// Represents a backup file record.
///
public class BackupFile
{
///
/// Gets or sets the backup file version.
///
public int Version { get; set; }
///
/// Gets or sets the backup name.
///
public String Name { get; set; }
///
/// Gets or sets the creation date.
///
public DateTime Date { get; set; }
///
/// Gets or sets the machine serial number.
///
public String MachineSerialNumber { get; set; }
///
/// Gets or sets the machine unique identifier.
///
public String MachineGuid { get; set; }
///
/// Gets or sets the application version.
///
public String ApplicationVersion { get; set; }
///
/// Gets or sets the firmware version.
///
public String FirmwareVersion { get; set; }
///
/// Gets or sets the settings file.
///
public String SettingsFile { get; set; }
///
/// Gets or sets the job files.
///
public List JobFiles { get; set; }
///
/// Gets or sets the backup settings.
///
public BackupSettings Settings { get; set; }
///
/// Initializes a new instance of the class.
///
public BackupFile()
{
Settings = new BackupSettings();
JobFiles = new List();
}
public String ToJson()
{
return JsonConvert.SerializeObject(this);
}
public static BackupFile FromJson(String json)
{
return JsonConvert.DeserializeObject(json);
}
}
}