Add XML comments to public entities.

This commit is contained in:
2021-08-17 13:56:05 +01:00
parent 0d18153610
commit 00f605b0ca
542 changed files with 6029 additions and 104 deletions

View File

@@ -42,6 +42,9 @@ using Aaru.Decoders.CD;
namespace Aaru.DiscImages
{
// TODO: Implement PCMCIA support
/// <summary>
/// Implements reading MAME CHD disk images
/// </summary>
[SuppressMessage("ReSharper", "NotAccessedField.Local")]
public sealed partial class Chd : IOpticalMediaImage, IVerifiableImage
{

View File

@@ -38,6 +38,7 @@ namespace Aaru.DiscImages
{
public sealed partial class Chd
{
/// <inheritdoc />
public bool Identify(IFilter imageFilter)
{
Stream stream = imageFilter.GetDataForkStream();

View File

@@ -42,12 +42,18 @@ namespace Aaru.DiscImages
{
public sealed partial class Chd
{
/// <inheritdoc />
public ImageInfo Info => _imageInfo;
/// <inheritdoc />
public string Name => "MAME Compressed Hunks of Data";
/// <inheritdoc />
public Guid Id => new Guid("0D50233A-08BD-47D4-988B-27EAA0358597");
/// <inheritdoc />
public string Format => "Compressed Hunks of Data";
/// <inheritdoc />
public string Author => "Natalia Portillo";
/// <inheritdoc />
public List<Partition> Partitions
{
get
@@ -60,6 +66,7 @@ namespace Aaru.DiscImages
}
}
/// <inheritdoc />
public List<Track> Tracks
{
get
@@ -72,6 +79,7 @@ namespace Aaru.DiscImages
}
}
/// <inheritdoc />
public List<Session> Sessions
{
get
@@ -84,7 +92,9 @@ namespace Aaru.DiscImages
}
}
/// <inheritdoc />
public List<DumpHardwareType> DumpHardware => null;
/// <inheritdoc />
public CICMMetadataType CicmMetadata => null;
}
}

View File

@@ -52,6 +52,7 @@ namespace Aaru.DiscImages
{
public sealed partial class Chd
{
/// <inheritdoc />
[SuppressMessage("ReSharper", "UnusedVariable")]
public bool Open(IFilter imageFilter)
{
@@ -1242,6 +1243,7 @@ namespace Aaru.DiscImages
return true;
}
/// <inheritdoc />
public byte[] ReadSector(ulong sectorAddress)
{
if(sectorAddress > _imageInfo.Sectors - 1)
@@ -1368,6 +1370,7 @@ namespace Aaru.DiscImages
return buffer;
}
/// <inheritdoc />
public byte[] ReadSectorTag(ulong sectorAddress, SectorTagType tag)
{
if(_isHdd)
@@ -1623,6 +1626,7 @@ namespace Aaru.DiscImages
return buffer;
}
/// <inheritdoc />
public byte[] ReadSectors(ulong sectorAddress, uint length)
{
if(sectorAddress > _imageInfo.Sectors - 1)
@@ -1644,6 +1648,7 @@ namespace Aaru.DiscImages
return ms.ToArray();
}
/// <inheritdoc />
public byte[] ReadSectorsTag(ulong sectorAddress, uint length, SectorTagType tag)
{
if(sectorAddress > _imageInfo.Sectors - 1)
@@ -1665,6 +1670,7 @@ namespace Aaru.DiscImages
return ms.ToArray();
}
/// <inheritdoc />
public byte[] ReadSectorLong(ulong sectorAddress)
{
if(_isHdd)
@@ -1760,6 +1766,7 @@ namespace Aaru.DiscImages
return buffer;
}
/// <inheritdoc />
public byte[] ReadSectorsLong(ulong sectorAddress, uint length)
{
if(sectorAddress > _imageInfo.Sectors - 1)
@@ -1781,6 +1788,7 @@ namespace Aaru.DiscImages
return ms.ToArray();
}
/// <inheritdoc />
public byte[] ReadDiskTag(MediaTagType tag)
{
if(_imageInfo.ReadableMediaTags.Contains(MediaTagType.ATA_IDENTIFY))
@@ -1792,6 +1800,7 @@ namespace Aaru.DiscImages
throw new FeatureUnsupportedImageException("Feature not supported by image format");
}
/// <inheritdoc />
public List<Track> GetSessionTracks(Session session)
{
if(_isHdd)
@@ -1800,6 +1809,7 @@ namespace Aaru.DiscImages
return GetSessionTracks(session.SessionSequence);
}
/// <inheritdoc />
public List<Track> GetSessionTracks(ushort session)
{
if(_isHdd)
@@ -1808,6 +1818,7 @@ namespace Aaru.DiscImages
return _tracks.Values.Where(track => track.TrackSession == session).ToList();
}
/// <inheritdoc />
public byte[] ReadSector(ulong sectorAddress, uint track)
{
if(_isHdd)
@@ -1816,6 +1827,7 @@ namespace Aaru.DiscImages
return ReadSector(GetAbsoluteSector(sectorAddress, track));
}
/// <inheritdoc />
public byte[] ReadSectorTag(ulong sectorAddress, uint track, SectorTagType tag)
{
if(_isHdd)
@@ -1824,6 +1836,7 @@ namespace Aaru.DiscImages
return ReadSectorTag(GetAbsoluteSector(sectorAddress, track), tag);
}
/// <inheritdoc />
public byte[] ReadSectors(ulong sectorAddress, uint length, uint track)
{
if(_isHdd)
@@ -1832,6 +1845,7 @@ namespace Aaru.DiscImages
return ReadSectors(GetAbsoluteSector(sectorAddress, track), length);
}
/// <inheritdoc />
public byte[] ReadSectorsTag(ulong sectorAddress, uint length, uint track, SectorTagType tag)
{
if(_isHdd)
@@ -1840,6 +1854,7 @@ namespace Aaru.DiscImages
return ReadSectorsTag(GetAbsoluteSector(sectorAddress, track), length, tag);
}
/// <inheritdoc />
public byte[] ReadSectorLong(ulong sectorAddress, uint track)
{
if(_isHdd)
@@ -1848,6 +1863,7 @@ namespace Aaru.DiscImages
return ReadSectorLong(GetAbsoluteSector(sectorAddress, track));
}
/// <inheritdoc />
public byte[] ReadSectorsLong(ulong sectorAddress, uint length, uint track)
{
if(_isHdd)

View File

@@ -40,6 +40,7 @@ namespace Aaru.DiscImages
{
public sealed partial class Chd
{
/// <inheritdoc />
public bool? VerifySector(ulong sectorAddress)
{
if(_isHdd)
@@ -50,6 +51,7 @@ namespace Aaru.DiscImages
return CdChecksums.CheckCdSector(buffer);
}
/// <inheritdoc />
public bool? VerifySectors(ulong sectorAddress, uint length, out List<ulong> failingLbas,
out List<ulong> unknownLbas)
{
@@ -87,6 +89,7 @@ namespace Aaru.DiscImages
return failingLbas.Count <= 0;
}
/// <inheritdoc />
public bool? VerifySectors(ulong sectorAddress, uint length, uint track, out List<ulong> failingLbas,
out List<ulong> unknownLbas)
{
@@ -124,6 +127,7 @@ namespace Aaru.DiscImages
return failingLbas.Count <= 0;
}
/// <inheritdoc />
public bool? VerifyMediaImage()
{
byte[] calculated;
@@ -150,6 +154,7 @@ namespace Aaru.DiscImages
return _expectedChecksum.SequenceEqual(calculated);
}
/// <inheritdoc />
public bool? VerifySector(ulong sectorAddress, uint track)
{
if(_isHdd)