mirror of
https://github.com/aaru-dps/Aaru.Dto.git
synced 2025-12-16 19:24:34 +00:00
Add XML comments to public entities.
This commit is contained in:
@@ -34,10 +34,21 @@ using Aaru.CommonTypes.Metadata;
|
||||
|
||||
namespace Aaru.Dto
|
||||
{
|
||||
/// <summary>
|
||||
/// DTO from a CD drive read offset
|
||||
/// </summary>
|
||||
public class CdOffsetDto : CdOffset
|
||||
{
|
||||
/// <summary>
|
||||
/// Build an empty DTO
|
||||
/// </summary>
|
||||
public CdOffsetDto() {}
|
||||
|
||||
/// <summary>
|
||||
/// Build a DTO using the specified offset and database ID
|
||||
/// </summary>
|
||||
/// <param name="offset">CD reading offset</param>
|
||||
/// <param name="id">Database ID</param>
|
||||
public CdOffsetDto(CdOffset offset, int id)
|
||||
{
|
||||
Manufacturer = offset.Manufacturer;
|
||||
@@ -48,6 +59,9 @@ namespace Aaru.Dto
|
||||
Id = id;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Database ID
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
}
|
||||
}
|
||||
26
DeviceDto.cs
26
DeviceDto.cs
@@ -37,10 +37,20 @@ using Aaru.CommonTypes.Metadata;
|
||||
|
||||
namespace Aaru.Dto
|
||||
{
|
||||
/// <summary>
|
||||
/// DTO for known device
|
||||
/// </summary>
|
||||
public class DeviceDto : DeviceReportV2
|
||||
{
|
||||
/// <summary>
|
||||
/// Build an empty DTO
|
||||
/// </summary>
|
||||
public DeviceDto() {}
|
||||
|
||||
/// <summary>
|
||||
/// Build a DTO from a device report
|
||||
/// </summary>
|
||||
/// <param name="report">Device report</param>
|
||||
public DeviceDto(DeviceReportV2 report)
|
||||
{
|
||||
ATA = report.ATA;
|
||||
@@ -59,6 +69,13 @@ namespace Aaru.Dto
|
||||
GdRomSwapDiscCapabilities = report.GdRomSwapDiscCapabilities;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Build a DTO from a device report with the specified parameters
|
||||
/// </summary>
|
||||
/// <param name="report">Device report</param>
|
||||
/// <param name="id">Database ID</param>
|
||||
/// <param name="optimalMultipleSectorsRead">Optimal number of blocks for read</param>
|
||||
/// <param name="canReadGdRomUsingSwapDisc">Can read GD-ROM using swap trick?</param>
|
||||
public DeviceDto(DeviceReportV2 report, int id, int optimalMultipleSectorsRead, bool? canReadGdRomUsingSwapDisc)
|
||||
{
|
||||
ATA = report.ATA;
|
||||
@@ -170,10 +187,19 @@ namespace Aaru.Dto
|
||||
CanReadGdRomUsingSwapDisc = canReadGdRomUsingSwapDisc;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Optimal maximum number of transfer blocks to read
|
||||
/// </summary>
|
||||
public int OptimalMultipleSectorsRead { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Can read GD-ROM using disc swap trick?
|
||||
/// </summary>
|
||||
public bool? CanReadGdRomUsingSwapDisc { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Database ID
|
||||
/// </summary>
|
||||
public new int Id { get; set; }
|
||||
|
||||
static TestedMedia ClearBinaries(TestedMedia media)
|
||||
|
||||
15
SyncDto.cs
15
SyncDto.cs
@@ -34,11 +34,26 @@ using System.Collections.Generic;
|
||||
|
||||
namespace Aaru.Dto
|
||||
{
|
||||
/// <summary>
|
||||
/// DTO for database synchronization.
|
||||
/// </summary>
|
||||
public class SyncDto
|
||||
{
|
||||
/// <summary>
|
||||
/// List of USB vendors
|
||||
/// </summary>
|
||||
public List<UsbVendorDto> UsbVendors { get; set; }
|
||||
/// <summary>
|
||||
/// List of USB products
|
||||
/// </summary>
|
||||
public List<UsbProductDto> UsbProducts { get; set; }
|
||||
/// <summary>
|
||||
/// List of CD read offsets
|
||||
/// </summary>
|
||||
public List<CdOffsetDto> Offsets { get; set; }
|
||||
/// <summary>
|
||||
/// List of known devices
|
||||
/// </summary>
|
||||
public List<DeviceDto> Devices { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -32,11 +32,26 @@
|
||||
|
||||
namespace Aaru.Dto
|
||||
{
|
||||
/// <summary>
|
||||
/// DTO for USB product field
|
||||
/// </summary>
|
||||
public class UsbProductDto
|
||||
{
|
||||
/// <summary>
|
||||
/// Database ID
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
/// <summary>
|
||||
/// Product ID
|
||||
/// </summary>
|
||||
public ushort ProductId { get; set; }
|
||||
/// <summary>
|
||||
/// Product name
|
||||
/// </summary>
|
||||
public string Product { get; set; }
|
||||
/// <summary>
|
||||
/// Vendor ID
|
||||
/// </summary>
|
||||
public ushort VendorId { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -32,9 +32,18 @@
|
||||
|
||||
namespace Aaru.Dto
|
||||
{
|
||||
/// <summary>
|
||||
/// DTO for USB vendor field
|
||||
/// </summary>
|
||||
public class UsbVendorDto
|
||||
{
|
||||
/// <summary>
|
||||
/// Vendor ID
|
||||
/// </summary>
|
||||
public ushort VendorId { get; set; }
|
||||
/// <summary>
|
||||
/// Vendor
|
||||
/// </summary>
|
||||
public string Vendor { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user