General code refactor.

This commit is contained in:
2021-08-17 21:23:22 +01:00
parent 8b7e27dca5
commit 22f34a17d4
7 changed files with 729 additions and 759 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -105,8 +105,8 @@ namespace Aaru.Decoders.ATA
if(ATAID.CommandSet3.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CommandSetBit3.MustBeSet) && if(ATAID.CommandSet3.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CommandSetBit3.MustBeSet) &&
!ATAID.CommandSet3.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CommandSetBit3.MustBeClear)) !ATAID.CommandSet3.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CommandSetBit3.MustBeClear))
{ {
if(ATAID.EnabledCommandSet3.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CommandSetBit3.MediaSerial) if(ATAID.EnabledCommandSet3.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CommandSetBit3.
) MediaSerial))
{ {
if(ATAID.MediaManufacturer != "") if(ATAID.MediaManufacturer != "")
sb.AppendFormat("Media manufacturer: {0}", ATAID.MediaManufacturer).AppendLine(); sb.AppendFormat("Media manufacturer: {0}", ATAID.MediaManufacturer).AppendLine();
@@ -849,8 +849,8 @@ namespace Aaru.Decoders.ATA
sb.AppendFormat("Device size in 48-bit LBA mode: {0} bytes, {1} Tb, {2} TiB", sb.AppendFormat("Device size in 48-bit LBA mode: {0} bytes, {1} Tb, {2} TiB",
ATAID.ExtendedUserSectors * logicalSectorSize, ATAID.ExtendedUserSectors * logicalSectorSize,
ATAID.ExtendedUserSectors * logicalSectorSize / 1000 / 1000 / 1000 / 1000, ATAID.ExtendedUserSectors * logicalSectorSize / 1000 / 1000 / 1000 / 1000,
ATAID.ExtendedUserSectors * logicalSectorSize / 1024 / 1024 / 1024 / ATAID.ExtendedUserSectors * logicalSectorSize / 1024 / 1024 / 1024 / 1024).
1024).AppendLine(); AppendLine();
else if(ATAID.ExtendedUserSectors * logicalSectorSize / 1024 / 1024 > 1000) else if(ATAID.ExtendedUserSectors * logicalSectorSize / 1024 / 1024 > 1000)
sb.AppendFormat("Device size in 48-bit LBA mode: {0} bytes, {1} Gb, {2} GiB", sb.AppendFormat("Device size in 48-bit LBA mode: {0} bytes, {1} Gb, {2} GiB",
ATAID.ExtendedUserSectors * logicalSectorSize, ATAID.ExtendedUserSectors * logicalSectorSize,
@@ -933,8 +933,8 @@ namespace Aaru.Decoders.ATA
switch(ATAID.BufferType) switch(ATAID.BufferType)
{ {
case 1: case 1:
sb.AppendFormat("{0} KiB of single ported single sector buffer", sb.AppendFormat("{0} KiB of single ported single sector buffer", ATAID.BufferSize * 512 / 1024).
ATAID.BufferSize * 512 / 1024).AppendLine(); AppendLine();
break; break;
case 2: case 2:
@@ -962,8 +962,8 @@ namespace Aaru.Decoders.ATA
sb.Append("Device capabilities:"); sb.Append("Device capabilities:");
if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit.StandardStandbyTimer) if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit.
) StandardStandbyTimer))
sb.AppendLine().Append("Standby time values are standard"); sb.AppendLine().Append("Standby time values are standard");
if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit.IORDY)) if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit.IORDY))
@@ -1012,8 +1012,8 @@ namespace Aaru.Decoders.ATA
if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit.CommandQueue)) if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit.CommandQueue))
sb.AppendLine().Append("ATAPI device supports command queueing"); sb.AppendLine().Append("ATAPI device supports command queueing");
if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit.OverlapOperation) if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit.
) OverlapOperation))
sb.AppendLine().Append("ATAPI device supports overlapped operations"); sb.AppendLine().Append("ATAPI device supports overlapped operations");
if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit. if(ATAID.Capabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.CapabilitiesBit.
@@ -1332,8 +1332,8 @@ namespace Aaru.Decoders.ATA
} }
} }
if(!ATAID.SATACapabilities2.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATACapabilitiesBit2.Clear) if(!ATAID.SATACapabilities2.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATACapabilitiesBit2.
) Clear))
{ {
if(!ATAID.SATACapabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATACapabilitiesBit. if(!ATAID.SATACapabilities.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATACapabilitiesBit.
Clear) && Clear) &&
@@ -1943,8 +1943,8 @@ namespace Aaru.Decoders.ATA
ReadLogDMAExt)) ReadLogDMAExt))
sb.AppendLine().Append("READ LOG DMA EXT is supported"); sb.AppendLine().Append("READ LOG DMA EXT is supported");
if(!ATAID.SATACapabilities2.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATACapabilitiesBit2.Clear) if(!ATAID.SATACapabilities2.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATACapabilitiesBit2.
) Clear))
if(ATAID.SATACapabilities2.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATACapabilitiesBit2. if(ATAID.SATACapabilities2.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATACapabilitiesBit2.
FPDMAQ)) FPDMAQ))
sb.AppendLine().Append("RECEIVE FPDMA QUEUED and SEND FPDMA QUEUED are supported"); sb.AppendLine().Append("RECEIVE FPDMA QUEUED and SEND FPDMA QUEUED are supported");
@@ -2021,8 +2021,8 @@ namespace Aaru.Decoders.ATA
sb.Append(" and enabled"); sb.Append(" and enabled");
} }
if(ATAID.SATAFeatures.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATAFeaturesBit.NCQAutoSense) if(ATAID.SATAFeatures.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATAFeaturesBit.
) NCQAutoSense))
sb.AppendLine().Append("NCQ Autosense is supported"); sb.AppendLine().Append("NCQ Autosense is supported");
if(ATAID.EnabledSATAFeatures.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATAFeaturesBit. if(ATAID.EnabledSATAFeatures.HasFlag(CommonTypes.Structs.Devices.ATA.Identify.SATAFeaturesBit.

View File

@@ -54,132 +54,132 @@
<ConsolePause>false</ConsolePause> <ConsolePause>false</ConsolePause>
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="System" /> <Reference Include="System"/>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Compile Include="Bluray\BCA.cs" /> <Compile Include="Bluray\BCA.cs"/>
<Compile Include="Bluray\Cartridge.cs" /> <Compile Include="Bluray\Cartridge.cs"/>
<Compile Include="Bluray\DDS.cs" /> <Compile Include="Bluray\DDS.cs"/>
<Compile Include="Bluray\DI.cs" /> <Compile Include="Bluray\DI.cs"/>
<Compile Include="Bluray\Spare.cs" /> <Compile Include="Bluray\Spare.cs"/>
<Compile Include="CD\SectorBuilder.cs" /> <Compile Include="CD\SectorBuilder.cs"/>
<Compile Include="CD\Subchannel.cs" /> <Compile Include="CD\Subchannel.cs"/>
<Compile Include="SCSI\Inquiry.cs" /> <Compile Include="SCSI\Inquiry.cs"/>
<Compile Include="Floppy\Enums.cs" /> <Compile Include="Floppy\Enums.cs"/>
<Compile Include="Floppy\System3740.cs" /> <Compile Include="Floppy\System3740.cs"/>
<Compile Include="Floppy\System34.cs" /> <Compile Include="Floppy\System34.cs"/>
<Compile Include="Floppy\Perpendicular.cs" /> <Compile Include="Floppy\Perpendicular.cs"/>
<Compile Include="Floppy\ISO.cs" /> <Compile Include="Floppy\ISO.cs"/>
<Compile Include="Floppy\Apple2.cs" /> <Compile Include="Floppy\Apple2.cs"/>
<Compile Include="Floppy\AppleSony.cs" /> <Compile Include="Floppy\AppleSony.cs"/>
<Compile Include="Floppy\Commodore.cs" /> <Compile Include="Floppy\Commodore.cs"/>
<Compile Include="Floppy\Amiga.cs" /> <Compile Include="Floppy\Amiga.cs"/>
<Compile Include="DVD\Enums.cs" /> <Compile Include="DVD\Enums.cs"/>
<Compile Include="DVD\PFI.cs" /> <Compile Include="DVD\PFI.cs"/>
<Compile Include="DVD\DMI.cs" /> <Compile Include="DVD\DMI.cs"/>
<Compile Include="DVD\BCA.cs" /> <Compile Include="DVD\BCA.cs"/>
<Compile Include="DVD\DDS.cs" /> <Compile Include="DVD\DDS.cs"/>
<Compile Include="DVD\RMD.cs" /> <Compile Include="DVD\RMD.cs"/>
<Compile Include="DVD\Spare.cs" /> <Compile Include="DVD\Spare.cs"/>
<Compile Include="DVD\PRI.cs" /> <Compile Include="DVD\PRI.cs"/>
<Compile Include="DVD\UDI.cs" /> <Compile Include="DVD\UDI.cs"/>
<Compile Include="DVD\ADIP.cs" /> <Compile Include="DVD\ADIP.cs"/>
<Compile Include="DVD\Layers.cs" /> <Compile Include="DVD\Layers.cs"/>
<Compile Include="DVD\AACS.cs" /> <Compile Include="DVD\AACS.cs"/>
<Compile Include="DVD\CSS&amp;CPRM.cs" /> <Compile Include="DVD\CSS&amp;CPRM.cs"/>
<Compile Include="DVD\CPRM.cs" /> <Compile Include="DVD\CPRM.cs"/>
<Compile Include="DVD\Cartridge.cs" /> <Compile Include="DVD\Cartridge.cs"/>
<Compile Include="CD\TOC.cs" /> <Compile Include="CD\TOC.cs"/>
<Compile Include="CD\Session.cs" /> <Compile Include="CD\Session.cs"/>
<Compile Include="CD\FullTOC.cs" /> <Compile Include="CD\FullTOC.cs"/>
<Compile Include="CD\PMA.cs" /> <Compile Include="CD\PMA.cs"/>
<Compile Include="CD\ATIP.cs" /> <Compile Include="CD\ATIP.cs"/>
<Compile Include="CD\Enums.cs" /> <Compile Include="CD\Enums.cs"/>
<Compile Include="CD\CDTextOnLeadIn.cs" /> <Compile Include="CD\CDTextOnLeadIn.cs"/>
<Compile Include="SCSI\MMC\AACS.cs" /> <Compile Include="SCSI\MMC\AACS.cs"/>
<Compile Include="SCSI\MMC\CPRM.cs" /> <Compile Include="SCSI\MMC\CPRM.cs"/>
<Compile Include="SCSI\MMC\Enums.cs" /> <Compile Include="SCSI\MMC\Enums.cs"/>
<Compile Include="SCSI\MMC\Hybrid.cs" /> <Compile Include="SCSI\MMC\Hybrid.cs"/>
<Compile Include="SCSI\MMC\TrackInformation.cs" /> <Compile Include="SCSI\MMC\TrackInformation.cs"/>
<Compile Include="SCSI\MMC\WriteProtect.cs" /> <Compile Include="SCSI\MMC\WriteProtect.cs"/>
<Compile Include="SCSI\MMC\DiscInformation.cs" /> <Compile Include="SCSI\MMC\DiscInformation.cs"/>
<Compile Include="SCSI\Modes\00_SFF.cs" /> <Compile Include="SCSI\Modes\00_SFF.cs"/>
<Compile Include="SCSI\Modes\01.cs" /> <Compile Include="SCSI\Modes\01.cs"/>
<Compile Include="SCSI\Modes\01_MMC.cs" /> <Compile Include="SCSI\Modes\01_MMC.cs"/>
<Compile Include="SCSI\Modes\02.cs" /> <Compile Include="SCSI\Modes\02.cs"/>
<Compile Include="SCSI\Modes\03.cs" /> <Compile Include="SCSI\Modes\03.cs"/>
<Compile Include="SCSI\Modes\04.cs" /> <Compile Include="SCSI\Modes\04.cs"/>
<Compile Include="SCSI\Modes\05.cs" /> <Compile Include="SCSI\Modes\05.cs"/>
<Compile Include="SCSI\Modes\06.cs" /> <Compile Include="SCSI\Modes\06.cs"/>
<Compile Include="SCSI\Modes\07.cs" /> <Compile Include="SCSI\Modes\07.cs"/>
<Compile Include="SCSI\Modes\07_MMC.cs" /> <Compile Include="SCSI\Modes\07_MMC.cs"/>
<Compile Include="SCSI\Modes\08.cs" /> <Compile Include="SCSI\Modes\08.cs"/>
<Compile Include="SCSI\Modes\0A.cs" /> <Compile Include="SCSI\Modes\0A.cs"/>
<Compile Include="SCSI\Modes\0B.cs" /> <Compile Include="SCSI\Modes\0B.cs"/>
<Compile Include="SCSI\Modes\0C.cs" /> <Compile Include="SCSI\Modes\0C.cs"/>
<Compile Include="SCSI\Modes\0D.cs" /> <Compile Include="SCSI\Modes\0D.cs"/>
<Compile Include="SCSI\Modes\0E.cs" /> <Compile Include="SCSI\Modes\0E.cs"/>
<Compile Include="SCSI\Modes\0F.cs" /> <Compile Include="SCSI\Modes\0F.cs"/>
<Compile Include="SCSI\Modes\10.cs" /> <Compile Include="SCSI\Modes\10.cs"/>
<Compile Include="SCSI\Modes\10_SSC.cs" /> <Compile Include="SCSI\Modes\10_SSC.cs"/>
<Compile Include="SCSI\Modes\11.cs" /> <Compile Include="SCSI\Modes\11.cs"/>
<Compile Include="SCSI\Modes\12_13_14.cs" /> <Compile Include="SCSI\Modes\12_13_14.cs"/>
<Compile Include="SCSI\Modes\1A.cs" /> <Compile Include="SCSI\Modes\1A.cs"/>
<Compile Include="SCSI\Modes\1B.cs" /> <Compile Include="SCSI\Modes\1B.cs"/>
<Compile Include="SCSI\Modes\1C.cs" /> <Compile Include="SCSI\Modes\1C.cs"/>
<Compile Include="SCSI\Modes\1C_SFF.cs" /> <Compile Include="SCSI\Modes\1C_SFF.cs"/>
<Compile Include="SCSI\Modes\1D.cs" /> <Compile Include="SCSI\Modes\1D.cs"/>
<Compile Include="SCSI\Modes\21_Certance.cs" /> <Compile Include="SCSI\Modes\21_Certance.cs"/>
<Compile Include="SCSI\Modes\22_Certance.cs" /> <Compile Include="SCSI\Modes\22_Certance.cs"/>
<Compile Include="SCSI\Modes\24_IBM.cs" /> <Compile Include="SCSI\Modes\24_IBM.cs"/>
<Compile Include="SCSI\Modes\2A.cs" /> <Compile Include="SCSI\Modes\2A.cs"/>
<Compile Include="SCSI\Modes\2F_IBM.cs" /> <Compile Include="SCSI\Modes\2F_IBM.cs"/>
<Compile Include="SCSI\Modes\30_Apple.cs" /> <Compile Include="SCSI\Modes\30_Apple.cs"/>
<Compile Include="SCSI\Modes\3B_HP.cs" /> <Compile Include="SCSI\Modes\3B_HP.cs"/>
<Compile Include="SCSI\Modes\3C_HP.cs" /> <Compile Include="SCSI\Modes\3C_HP.cs"/>
<Compile Include="SCSI\Modes\3D_HP.cs" /> <Compile Include="SCSI\Modes\3D_HP.cs"/>
<Compile Include="SCSI\Modes\3D_IBM.cs" /> <Compile Include="SCSI\Modes\3D_IBM.cs"/>
<Compile Include="SCSI\Modes\3E_Fujitsu.cs" /> <Compile Include="SCSI\Modes\3E_Fujitsu.cs"/>
<Compile Include="SCSI\Modes\3E_HP.cs" /> <Compile Include="SCSI\Modes\3E_HP.cs"/>
<Compile Include="SCSI\Modes\Headers.cs" /> <Compile Include="SCSI\Modes\Headers.cs"/>
<Compile Include="SCSI\Modes\Mode10.cs" /> <Compile Include="SCSI\Modes\Mode10.cs"/>
<Compile Include="SCSI\Modes\Mode6.cs" /> <Compile Include="SCSI\Modes\Mode6.cs"/>
<Compile Include="SCSI\Modes\Structs.cs" /> <Compile Include="SCSI\Modes\Structs.cs"/>
<Compile Include="SCSI\VendorString.cs" /> <Compile Include="SCSI\VendorString.cs"/>
<Compile Include="ATA\Identify.cs" /> <Compile Include="ATA\Identify.cs"/>
<Compile Include="SCSI\EVPD.cs" /> <Compile Include="SCSI\EVPD.cs"/>
<Compile Include="SCSI\MMC\Features.cs" /> <Compile Include="SCSI\MMC\Features.cs"/>
<Compile Include="SCSI\DiscStructureCapabilities.cs" /> <Compile Include="SCSI\DiscStructureCapabilities.cs"/>
<Compile Include="SCSI\Sense.cs" /> <Compile Include="SCSI\Sense.cs"/>
<Compile Include="ATA\Registers.cs" /> <Compile Include="ATA\Registers.cs"/>
<Compile Include="Xbox\DMI.cs" /> <Compile Include="Xbox\DMI.cs"/>
<Compile Include="SCSI\SSC\BlockLimits.cs" /> <Compile Include="SCSI\SSC\BlockLimits.cs"/>
<Compile Include="SCSI\SSC\DensitySupport.cs" /> <Compile Include="SCSI\SSC\DensitySupport.cs"/>
<Compile Include="SCSI\Types.cs" /> <Compile Include="SCSI\Types.cs"/>
<Compile Include="LisaTag.cs" /> <Compile Include="LisaTag.cs"/>
<Compile Include="CD\Sector.cs" /> <Compile Include="CD\Sector.cs"/>
<Compile Include="PCMCIA\Enums.cs" /> <Compile Include="PCMCIA\Enums.cs"/>
<Compile Include="PCMCIA\Types.cs" /> <Compile Include="PCMCIA\Types.cs"/>
<Compile Include="PCMCIA\CIS.cs" /> <Compile Include="PCMCIA\CIS.cs"/>
<Compile Include="PCMCIA\VendorCode.cs" /> <Compile Include="PCMCIA\VendorCode.cs"/>
<Compile Include="MMC\CSD.cs" /> <Compile Include="MMC\CSD.cs"/>
<Compile Include="MMC\CID.cs" /> <Compile Include="MMC\CID.cs"/>
<Compile Include="MMC\ExtendedCSD.cs" /> <Compile Include="MMC\ExtendedCSD.cs"/>
<Compile Include="MMC\OCR.cs" /> <Compile Include="MMC\OCR.cs"/>
<Compile Include="MMC\VendorString.cs" /> <Compile Include="MMC\VendorString.cs"/>
<Compile Include="SecureDigital\CID.cs" /> <Compile Include="SecureDigital\CID.cs"/>
<Compile Include="SecureDigital\CSD.cs" /> <Compile Include="SecureDigital\CSD.cs"/>
<Compile Include="SecureDigital\SCR.cs" /> <Compile Include="SecureDigital\SCR.cs"/>
<Compile Include="SecureDigital\OCR.cs" /> <Compile Include="SecureDigital\OCR.cs"/>
<Compile Include="SecureDigital\VendorString.cs" /> <Compile Include="SecureDigital\VendorString.cs"/>
<Compile Include="Xbox\SS.cs" /> <Compile Include="Xbox\SS.cs"/>
<Compile Include="Sega\CD.cs" /> <Compile Include="Sega\CD.cs"/>
<Compile Include="Sega\Saturn.cs" /> <Compile Include="Sega\Saturn.cs"/>
<Compile Include="Sega\Dreamcast.cs" /> <Compile Include="Sega\Dreamcast.cs"/>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ProjectReference Include="..\Aaru.Checksums\Aaru.Checksums.csproj" /> <ProjectReference Include="..\Aaru.Checksums\Aaru.Checksums.csproj"/>
<ProjectReference Include="..\Aaru.CommonTypes\Aaru.CommonTypes.csproj" /> <ProjectReference Include="..\Aaru.CommonTypes\Aaru.CommonTypes.csproj"/>
<ProjectReference Include="..\Aaru.Helpers\Aaru.Helpers.csproj"> <ProjectReference Include="..\Aaru.Helpers\Aaru.Helpers.csproj">
<Project>{F8BDF57B-1571-4CD0-84B3-B422088D359A}</Project> <Project>{F8BDF57B-1571-4CD0-84B3-B422088D359A}</Project>
<Name>Aaru.Helpers</Name> <Name>Aaru.Helpers</Name>
@@ -190,20 +190,20 @@
</ProjectReference> </ProjectReference>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Folder Include="Blu-ray" /> <Folder Include="Blu-ray"/>
<Folder Include="SCSI\" /> <Folder Include="SCSI\"/>
<Folder Include="ATA\" /> <Folder Include="ATA\"/>
<Folder Include="Blu-ray\" /> <Folder Include="Blu-ray\"/>
<Folder Include="DVD\" /> <Folder Include="DVD\"/>
<Folder Include="SCSI\MMC\" /> <Folder Include="SCSI\MMC\"/>
<Folder Include="CD\" /> <Folder Include="CD\"/>
<Folder Include="Floppy\" /> <Folder Include="Floppy\"/>
<Folder Include="Xbox\" /> <Folder Include="Xbox\"/>
<Folder Include="SCSI\SSC\" /> <Folder Include="SCSI\SSC\"/>
<Folder Include="PCMCIA\" /> <Folder Include="PCMCIA\"/>
<Folder Include="MMC\" /> <Folder Include="MMC\"/>
<Folder Include="SecureDigital\" /> <Folder Include="SecureDigital\"/>
<Folder Include="Sega\" /> <Folder Include="Sega\"/>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<EmbeddedResource Include="..\LICENSE.LGPL"> <EmbeddedResource Include="..\LICENSE.LGPL">
@@ -211,18 +211,18 @@
</EmbeddedResource> </EmbeddedResource>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" /> <PackageReference Include="Newtonsoft.Json" Version="12.0.3"/>
<PackageReference Include="System.ComponentModel.Annotations" Version="4.7.0" /> <PackageReference Include="System.ComponentModel.Annotations" Version="4.7.0"/>
<PackageReference Include="Unclassified.NetRevisionTask" Version="0.3.0" PrivateAssets="all" /> <PackageReference Include="Unclassified.NetRevisionTask" Version="0.3.0" PrivateAssets="all"/>
</ItemGroup> </ItemGroup>
<ProjectExtensions> <ProjectExtensions>
<MonoDevelop> <MonoDevelop>
<Properties> <Properties>
<Policies> <Policies>
<DotNetNamingPolicy DirectoryNamespaceAssociation="PrefixedHierarchical" ResourceNamePolicy="MSBuild" /> <DotNetNamingPolicy DirectoryNamespaceAssociation="PrefixedHierarchical" ResourceNamePolicy="MSBuild"/>
<StandardHeader IncludeInNewFiles="True" Text="/***************************************************************************&#xA;Aaru Data Preservation Suite&#xA;----------------------------------------------------------------------------&#xA; &#xA;Filename : ${FileName}&#xA;Author(s) : ${AuthorName} &lt;${AuthorEmail}&gt;&#xA;&#xA;Component : Component&#xA; &#xA;--[ Description ] ----------------------------------------------------------&#xA; &#xA; Description&#xA; &#xA;--[ License ] --------------------------------------------------------------&#xA; &#xA; This library is free software; you can redistribute it and/or modify&#xA; it under the terms of the GNU Lesser General Public License as&#xA; published by the Free Software Foundation; either version 2.1 of the&#xA; License, or (at your option) any later version.&#xA;&#xA; This library is distributed in the hope that it will be useful, but&#xA; WITHOUT ANY WARRANTY; without even the implied warranty of&#xA; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU&#xA; Lesser General Public License for more details.&#xA;&#xA; You should have received a copy of the GNU Lesser General Public&#xA; License along with this library; if not, see &lt;http://www.gnu.org/licenses/&gt;.&#xA;&#xA;----------------------------------------------------------------------------&#xA;Copyright © 2011-${Year} ${CopyrightHolder}&#xA;****************************************************************************/" /> <StandardHeader IncludeInNewFiles="True" Text="/***************************************************************************&#xA;Aaru Data Preservation Suite&#xA;----------------------------------------------------------------------------&#xA; &#xA;Filename : ${FileName}&#xA;Author(s) : ${AuthorName} &lt;${AuthorEmail}&gt;&#xA;&#xA;Component : Component&#xA; &#xA;--[ Description ] ----------------------------------------------------------&#xA; &#xA; Description&#xA; &#xA;--[ License ] --------------------------------------------------------------&#xA; &#xA; This library is free software; you can redistribute it and/or modify&#xA; it under the terms of the GNU Lesser General Public License as&#xA; published by the Free Software Foundation; either version 2.1 of the&#xA; License, or (at your option) any later version.&#xA;&#xA; This library is distributed in the hope that it will be useful, but&#xA; WITHOUT ANY WARRANTY; without even the implied warranty of&#xA; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU&#xA; Lesser General Public License for more details.&#xA;&#xA; You should have received a copy of the GNU Lesser General Public&#xA; License along with this library; if not, see &lt;http://www.gnu.org/licenses/&gt;.&#xA;&#xA;----------------------------------------------------------------------------&#xA;Copyright © 2011-${Year} ${CopyrightHolder}&#xA;****************************************************************************/"/>
<TextStylePolicy FileWidth="120" TabWidth="4" IndentWidth="4" RemoveTrailingWhitespace="True" NoTabsAfterNonTabs="False" EolMarker="Native" TabsToSpaces="True" scope="text/x-csharp" /> <TextStylePolicy FileWidth="120" TabWidth="4" IndentWidth="4" RemoveTrailingWhitespace="True" NoTabsAfterNonTabs="False" EolMarker="Native" TabsToSpaces="True" scope="text/x-csharp"/>
<CSharpFormattingPolicy IndentBlock="True" IndentBraces="False" IndentSwitchSection="True" IndentSwitchCaseSection="True" LabelPositioning="OneLess" NewLinesForBracesInTypes="True" NewLinesForBracesInMethods="True" NewLinesForBracesInProperties="True" NewLinesForBracesInAccessors="True" NewLinesForBracesInAnonymousMethods="True" NewLinesForBracesInControlBlocks="True" NewLinesForBracesInAnonymousTypes="True" NewLinesForBracesInObjectCollectionArrayInitializers="True" NewLinesForBracesInLambdaExpressionBody="True" NewLineForElse="True" NewLineForCatch="True" NewLineForFinally="True" NewLineForMembersInObjectInit="True" NewLineForMembersInAnonymousTypes="True" NewLineForClausesInQuery="True" SpacingAfterMethodDeclarationName="False" SpaceWithinMethodDeclarationParenthesis="False" SpaceBetweenEmptyMethodDeclarationParentheses="False" SpaceAfterMethodCallName="False" SpaceWithinMethodCallParentheses="False" SpaceBetweenEmptyMethodCallParentheses="False" SpaceWithinExpressionParentheses="False" SpaceWithinCastParentheses="False" SpaceWithinOtherParentheses="False" SpaceAfterCast="False" SpacesIgnoreAroundVariableDeclaration="False" SpaceBeforeOpenSquareBracket="False" SpaceBetweenEmptySquareBrackets="False" SpaceWithinSquareBrackets="False" SpaceAfterColonInBaseTypeDeclaration="True" SpaceAfterComma="True" SpaceAfterDot="False" SpaceAfterSemicolonsInForStatement="True" SpaceBeforeColonInBaseTypeDeclaration="True" SpaceBeforeComma="False" SpaceBeforeDot="False" SpaceBeforeSemicolonsInForStatement="False" SpacingAroundBinaryOperator="Single" WrappingPreserveSingleLine="True" WrappingKeepStatementsOnSingleLine="True" PlaceSystemDirectiveFirst="True" SpaceAfterControlFlowStatementKeyword="False" scope="text/x-csharp" /> <CSharpFormattingPolicy IndentBlock="True" IndentBraces="False" IndentSwitchSection="True" IndentSwitchCaseSection="True" LabelPositioning="OneLess" NewLinesForBracesInTypes="True" NewLinesForBracesInMethods="True" NewLinesForBracesInProperties="True" NewLinesForBracesInAccessors="True" NewLinesForBracesInAnonymousMethods="True" NewLinesForBracesInControlBlocks="True" NewLinesForBracesInAnonymousTypes="True" NewLinesForBracesInObjectCollectionArrayInitializers="True" NewLinesForBracesInLambdaExpressionBody="True" NewLineForElse="True" NewLineForCatch="True" NewLineForFinally="True" NewLineForMembersInObjectInit="True" NewLineForMembersInAnonymousTypes="True" NewLineForClausesInQuery="True" SpacingAfterMethodDeclarationName="False" SpaceWithinMethodDeclarationParenthesis="False" SpaceBetweenEmptyMethodDeclarationParentheses="False" SpaceAfterMethodCallName="False" SpaceWithinMethodCallParentheses="False" SpaceBetweenEmptyMethodCallParentheses="False" SpaceWithinExpressionParentheses="False" SpaceWithinCastParentheses="False" SpaceWithinOtherParentheses="False" SpaceAfterCast="False" SpacesIgnoreAroundVariableDeclaration="False" SpaceBeforeOpenSquareBracket="False" SpaceBetweenEmptySquareBrackets="False" SpaceWithinSquareBrackets="False" SpaceAfterColonInBaseTypeDeclaration="True" SpaceAfterComma="True" SpaceAfterDot="False" SpaceAfterSemicolonsInForStatement="True" SpaceBeforeColonInBaseTypeDeclaration="True" SpaceBeforeComma="False" SpaceBeforeDot="False" SpaceBeforeSemicolonsInForStatement="False" SpacingAroundBinaryOperator="Single" WrappingPreserveSingleLine="True" WrappingKeepStatementsOnSingleLine="True" PlaceSystemDirectiveFirst="True" SpaceAfterControlFlowStatementKeyword="False" scope="text/x-csharp"/>
</Policies> </Policies>
</Properties> </Properties>
</MonoDevelop> </MonoDevelop>

View File

@@ -36,17 +36,13 @@ using Aaru.Helpers;
namespace Aaru.Decoders namespace Aaru.Decoders
{ {
/// <summary> /// <summary>Represents a Lisa Office 7/7 sector tag</summary>
/// Represents a Lisa Office 7/7 sector tag
/// </summary>
[SuppressMessage("ReSharper", "MemberCanBeInternal"), SuppressMessage("ReSharper", "NotAccessedField.Global"), [SuppressMessage("ReSharper", "MemberCanBeInternal"), SuppressMessage("ReSharper", "NotAccessedField.Global"),
SuppressMessage("ReSharper", "MemberCanBePrivate.Global")] SuppressMessage("ReSharper", "MemberCanBePrivate.Global"),
[SuppressMessage("ReSharper", "StructMemberCanBeMadeReadOnly")] SuppressMessage("ReSharper", "StructMemberCanBeMadeReadOnly")]
public static class LisaTag public static class LisaTag
{ {
/// <summary> /// <summary>Decodes tag from a 3.5" Sony micro-floppy</summary>
/// Decodes tag from a 3.5" Sony micro-floppy
/// </summary>
/// <param name="tag">Byte array containing raw tag data</param> /// <param name="tag">Byte array containing raw tag data</param>
/// <returns>Decoded tag in Sony's format</returns> /// <returns>Decoded tag in Sony's format</returns>
public static SonyTag? DecodeSonyTag(byte[] tag) public static SonyTag? DecodeSonyTag(byte[] tag)
@@ -73,9 +69,7 @@ namespace Aaru.Decoders
return snTag; return snTag;
} }
/// <summary> /// <summary>Decodes tag from a Profile</summary>
/// Decodes tag from a Profile
/// </summary>
/// <param name="tag">Byte array containing raw tag data</param> /// <param name="tag">Byte array containing raw tag data</param>
/// <returns>Decoded tag in Profile's format</returns> /// <returns>Decoded tag in Profile's format</returns>
public static ProfileTag? DecodeProfileTag(byte[] tag) public static ProfileTag? DecodeProfileTag(byte[] tag)
@@ -123,9 +117,7 @@ namespace Aaru.Decoders
return phTag; return phTag;
} }
/// <summary> /// <summary>Decodes tag from a Priam</summary>
/// Decodes tag from a Priam
/// </summary>
/// <param name="tag">Byte array containing raw tag data</param> /// <param name="tag">Byte array containing raw tag data</param>
/// <returns>Decoded tag in Priam's format</returns> /// <returns>Decoded tag in Priam's format</returns>
public static PriamTag? DecodePriamTag(byte[] tag) public static PriamTag? DecodePriamTag(byte[] tag)
@@ -175,9 +167,7 @@ namespace Aaru.Decoders
return pmTag; return pmTag;
} }
/// <summary> /// <summary>Decodes tag from any known format</summary>
/// Decodes tag from any known format
/// </summary>
/// <param name="tag">Byte array containing raw tag data</param> /// <param name="tag">Byte array containing raw tag data</param>
/// <returns>Decoded tag in Priam's format</returns> /// <returns>Decoded tag in Priam's format</returns>
public static PriamTag? DecodeTag(byte[] tag) public static PriamTag? DecodeTag(byte[] tag)

View File

@@ -40,16 +40,12 @@ using Marshal = Aaru.Helpers.Marshal;
namespace Aaru.Decoders.Sega namespace Aaru.Decoders.Sega
{ {
/// <summary> /// <summary>Represents the IP.BIN from a SEGA CD / MEGA CD</summary>
/// Represents the IP.BIN from a SEGA CD / MEGA CD
/// </summary>
[SuppressMessage("ReSharper", "InconsistentNaming"), SuppressMessage("ReSharper", "MemberCanBeInternal"), [SuppressMessage("ReSharper", "InconsistentNaming"), SuppressMessage("ReSharper", "MemberCanBeInternal"),
SuppressMessage("ReSharper", "MemberCanBePrivate.Global")] SuppressMessage("ReSharper", "MemberCanBePrivate.Global")]
public static class CD public static class CD
{ {
/// <summary> /// <summary>Decodes an IP.BIN sector in SEGA CD / MEGA CD format</summary>
/// Decodes an IP.BIN sector in SEGA CD / MEGA CD format
/// </summary>
/// <param name="ipbin_sector">IP.BIN sector</param> /// <param name="ipbin_sector">IP.BIN sector</param>
/// <returns>Decoded IP.BIN</returns> /// <returns>Decoded IP.BIN</returns>
public static IPBin? DecodeIPBin(byte[] ipbin_sector) public static IPBin? DecodeIPBin(byte[] ipbin_sector)
@@ -125,9 +121,7 @@ namespace Aaru.Decoders.Sega
: (IPBin?)null; : (IPBin?)null;
} }
/// <summary> /// <summary>Pretty prints a decoded IP.BIN in SEGA CD / MEGA CD format</summary>
/// Pretty prints a decoded IP.BIN in SEGA CD / MEGA CD format
/// </summary>
/// <param name="decoded">Decoded IP.BIN</param> /// <param name="decoded">Decoded IP.BIN</param>
/// <returns>Description of the IP.BIN contents</returns> /// <returns>Description of the IP.BIN contents</returns>
public static string Prettify(IPBin? decoded) public static string Prettify(IPBin? decoded)

View File

@@ -40,16 +40,12 @@ using Marshal = Aaru.Helpers.Marshal;
namespace Aaru.Decoders.Sega namespace Aaru.Decoders.Sega
{ {
/// <summary> /// <summary>Represents the IP.BIN from a SEGA Dreamcast</summary>
/// Represents the IP.BIN from a SEGA Dreamcast
/// </summary>
[SuppressMessage("ReSharper", "InconsistentNaming"), SuppressMessage("ReSharper", "MemberCanBeInternal"), [SuppressMessage("ReSharper", "InconsistentNaming"), SuppressMessage("ReSharper", "MemberCanBeInternal"),
SuppressMessage("ReSharper", "MemberCanBePrivate.Global")] SuppressMessage("ReSharper", "MemberCanBePrivate.Global")]
public static class Dreamcast public static class Dreamcast
{ {
/// <summary> /// <summary>Decodes an IP.BIN sector in Dreamcast format</summary>
/// Decodes an IP.BIN sector in Dreamcast format
/// </summary>
/// <param name="ipbin_sector">IP.BIN sector</param> /// <param name="ipbin_sector">IP.BIN sector</param>
/// <returns>Decoded IP.BIN</returns> /// <returns>Decoded IP.BIN</returns>
public static IPBin? DecodeIPBin(byte[] ipbin_sector) public static IPBin? DecodeIPBin(byte[] ipbin_sector)
@@ -113,9 +109,7 @@ namespace Aaru.Decoders.Sega
return Encoding.ASCII.GetString(ipbin.SegaHardwareID) == "SEGA SEGAKATANA " ? ipbin : (IPBin?)null; return Encoding.ASCII.GetString(ipbin.SegaHardwareID) == "SEGA SEGAKATANA " ? ipbin : (IPBin?)null;
} }
/// <summary> /// <summary>Pretty prints a decoded IP.BIN in Dreamcast format</summary>
/// Pretty prints a decoded IP.BIN in Dreamcast format
/// </summary>
/// <param name="decoded">Decoded IP.BIN</param> /// <param name="decoded">Decoded IP.BIN</param>
/// <returns>Description of the IP.BIN contents</returns> /// <returns>Description of the IP.BIN contents</returns>
public static string Prettify(IPBin? decoded) public static string Prettify(IPBin? decoded)
@@ -270,9 +264,7 @@ namespace Aaru.Decoders.Sega
return IPBinInformation.ToString(); return IPBinInformation.ToString();
} }
/// <summary> /// <summary>SEGA IP.BIN format for Dreamcast</summary>
/// SEGA IP.BIN format for Dreamcast
/// </summary>
[StructLayout(LayoutKind.Sequential, Pack = 1)] [StructLayout(LayoutKind.Sequential, Pack = 1)]
public struct IPBin public struct IPBin
{ {

View File

@@ -40,16 +40,12 @@ using Marshal = Aaru.Helpers.Marshal;
namespace Aaru.Decoders.Sega namespace Aaru.Decoders.Sega
{ {
/// <summary> /// <summary>Represents the IP.BIN from a SEGA Saturn</summary>
/// Represents the IP.BIN from a SEGA Saturn
/// </summary>
[SuppressMessage("ReSharper", "InconsistentNaming"), SuppressMessage("ReSharper", "MemberCanBeInternal"), [SuppressMessage("ReSharper", "InconsistentNaming"), SuppressMessage("ReSharper", "MemberCanBeInternal"),
SuppressMessage("ReSharper", "MemberCanBePrivate.Global")] SuppressMessage("ReSharper", "MemberCanBePrivate.Global")]
public static class Saturn public static class Saturn
{ {
/// <summary> /// <summary>Decodes an IP.BIN sector in Saturn format</summary>
/// Decodes an IP.BIN sector in Saturn format
/// </summary>
/// <param name="ipbin_sector">IP.BIN sector</param> /// <param name="ipbin_sector">IP.BIN sector</param>
/// <returns>Decoded IP.BIN</returns> /// <returns>Decoded IP.BIN</returns>
public static IPBin? DecodeIPBin(byte[] ipbin_sector) public static IPBin? DecodeIPBin(byte[] ipbin_sector)
@@ -103,9 +99,7 @@ namespace Aaru.Decoders.Sega
return Encoding.ASCII.GetString(ipbin.SegaHardwareID) == "SEGA SEGASATURN " ? ipbin : (IPBin?)null; return Encoding.ASCII.GetString(ipbin.SegaHardwareID) == "SEGA SEGASATURN " ? ipbin : (IPBin?)null;
} }
/// <summary> /// <summary>Pretty prints a decoded IP.BIN in Saturn format</summary>
/// Pretty prints a decoded IP.BIN in Saturn format
/// </summary>
/// <param name="decoded">Decoded IP.BIN</param> /// <param name="decoded">Decoded IP.BIN</param>
/// <returns>Description of the IP.BIN contents</returns> /// <returns>Description of the IP.BIN contents</returns>
public static string Prettify(IPBin? decoded) public static string Prettify(IPBin? decoded)