mirror of
https://github.com/aaru-dps/Aaru.Server.git
synced 2025-12-16 19:24:27 +00:00
REFACTOR: Use explicit or implicit modified definition.
This commit is contained in:
@@ -482,7 +482,7 @@ namespace DiscImageChef.Checksums
|
||||
}
|
||||
|
||||
// Converts an ASCII null-terminated string to .NET string
|
||||
private string CToString(byte[] cString)
|
||||
string CToString(byte[] cString)
|
||||
{
|
||||
StringBuilder sb = new StringBuilder();
|
||||
|
||||
|
||||
@@ -49,7 +49,7 @@ namespace DiscImageChef.Core.Devices.Dumping
|
||||
using Session = Decoders.CD.Session;
|
||||
using TrackType = Schemas.TrackType;
|
||||
|
||||
internal class CompactDisc
|
||||
class CompactDisc
|
||||
{
|
||||
internal static void Dump(Device dev, string devicePath, string outputPrefix, ushort retryPasses, bool force,
|
||||
bool dumpRaw, bool persistent, bool stopOnError, ref CICMMetadataType sidecar,
|
||||
|
||||
@@ -40,7 +40,7 @@ using Schemas;
|
||||
|
||||
namespace DiscImageChef.Core.Devices.Dumping
|
||||
{
|
||||
internal static class Mmc
|
||||
static class Mmc
|
||||
{
|
||||
internal static void Dump(Device dev, string devicePath, string outputPrefix, ushort retryPasses, bool force,
|
||||
bool dumpRaw, bool persistent, bool stopOnError, ref CICMMetadataType sidecar,
|
||||
|
||||
@@ -49,7 +49,7 @@ namespace DiscImageChef.Core.Devices.Dumping
|
||||
{
|
||||
using TrackType = DiscImages.TrackType;
|
||||
|
||||
internal static class Sbc
|
||||
static class Sbc
|
||||
{
|
||||
internal static void Dump(Device dev, string devicePath, string outputPrefix, ushort retryPasses, bool force,
|
||||
bool dumpRaw, bool persistent, bool stopOnError, ref CICMMetadataType sidecar,
|
||||
|
||||
@@ -42,7 +42,7 @@ using Schemas;
|
||||
|
||||
namespace DiscImageChef.Core.Devices.Dumping
|
||||
{
|
||||
internal static class Ssc
|
||||
static class Ssc
|
||||
{
|
||||
internal static void Dump(Device dev, string outputPrefix, string devicePath, ref CICMMetadataType sidecar,
|
||||
ref Metadata.Resume resume, ref DumpLog dumpLog)
|
||||
|
||||
@@ -47,7 +47,7 @@ using Schemas;
|
||||
|
||||
namespace DiscImageChef.Core.Devices.Dumping
|
||||
{
|
||||
internal static class Xgd
|
||||
static class Xgd
|
||||
{
|
||||
internal static void Dump(Device dev, string devicePath, string outputPrefix, ushort retryPasses, bool force,
|
||||
bool dumpRaw, bool persistent, bool stopOnError, ref CICMMetadataType sidecar,
|
||||
|
||||
@@ -39,7 +39,7 @@ using DiscImageChef.Metadata;
|
||||
|
||||
namespace DiscImageChef.Core.Devices.Report.SCSI
|
||||
{
|
||||
internal static class Mmc
|
||||
static class Mmc
|
||||
{
|
||||
internal static void Report(Device dev, ref DeviceReport report, bool debug,
|
||||
ref Decoders.SCSI.Modes.ModePage_2A? cdromMode, ref List<string> mediaTypes)
|
||||
|
||||
@@ -38,7 +38,7 @@ using DiscImageChef.Metadata;
|
||||
|
||||
namespace DiscImageChef.Core.Devices.Report.SCSI
|
||||
{
|
||||
internal static class Ssc
|
||||
static class Ssc
|
||||
{
|
||||
internal static void Report(Device dev, ref DeviceReport report, bool debug)
|
||||
{
|
||||
|
||||
@@ -301,7 +301,7 @@ namespace DiscImageChef.Devices.FreeBSD
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
struct NvmeCommand
|
||||
{
|
||||
private ushort opc_fuse_rsvd1;
|
||||
ushort opc_fuse_rsvd1;
|
||||
/// <summary>
|
||||
/// command identifier
|
||||
/// </summary>
|
||||
@@ -372,7 +372,7 @@ namespace DiscImageChef.Devices.FreeBSD
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
struct NvmeStatus
|
||||
{
|
||||
private ushort status;
|
||||
ushort status;
|
||||
|
||||
/// <summary>
|
||||
/// phase tag
|
||||
@@ -462,7 +462,7 @@ namespace DiscImageChef.Devices.FreeBSD
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
struct PeriphMatchPattern
|
||||
{
|
||||
private const int DEV_IDLEN = 16;
|
||||
const int DEV_IDLEN = 16;
|
||||
|
||||
[MarshalAs(UnmanagedType.ByValArray, SizeConst = DEV_IDLEN)] public byte[] periph_name;
|
||||
public uint unit_number;
|
||||
@@ -482,9 +482,9 @@ namespace DiscImageChef.Devices.FreeBSD
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
struct ScsiStaticInquiryPattern
|
||||
{
|
||||
private const int SID_VENDOR_SIZE = 8;
|
||||
private const int SID_PRODUCT_SIZE = 16;
|
||||
private const int SID_REVISION_SIZE = 4;
|
||||
const int SID_VENDOR_SIZE = 8;
|
||||
const int SID_PRODUCT_SIZE = 16;
|
||||
const int SID_REVISION_SIZE = 4;
|
||||
public byte type;
|
||||
public byte media_type;
|
||||
[MarshalAs(UnmanagedType.ByValArray, SizeConst = SID_VENDOR_SIZE + 1)] public byte[] vendor;
|
||||
@@ -512,7 +512,7 @@ namespace DiscImageChef.Devices.FreeBSD
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
struct BusMatchPattern
|
||||
{
|
||||
private const int DEV_IDLEN = 16;
|
||||
const int DEV_IDLEN = 16;
|
||||
|
||||
public path_id_t path_id;
|
||||
[MarshalAs(UnmanagedType.ByValArray, SizeConst = DEV_IDLEN)] public byte[] dev_name;
|
||||
@@ -622,7 +622,7 @@ namespace DiscImageChef.Devices.FreeBSD
|
||||
struct BusMatchResult
|
||||
{
|
||||
public path_id_t path_id;
|
||||
private const int DEV_IDLEN = 16;
|
||||
const int DEV_IDLEN = 16;
|
||||
[MarshalAs(UnmanagedType.ByValArray, SizeConst = DEV_IDLEN)] public byte[] dev_name;
|
||||
public uint unit_number;
|
||||
public uint bus_id;
|
||||
@@ -687,9 +687,9 @@ namespace DiscImageChef.Devices.FreeBSD
|
||||
|
||||
struct CamDevice
|
||||
{
|
||||
private const int MAXPATHLEN = 1024;
|
||||
private const int DEV_IDLEN = 16;
|
||||
private const int SIM_IDLEN = 16;
|
||||
const int MAXPATHLEN = 1024;
|
||||
const int DEV_IDLEN = 16;
|
||||
const int SIM_IDLEN = 16;
|
||||
/// <summary>
|
||||
/// Pathname of the device given by the user. This may be null if the user states the device name and unit number separately.
|
||||
/// </summary>
|
||||
|
||||
@@ -215,7 +215,7 @@ namespace DiscImageChef.Devices.Windows
|
||||
public int cbSize;
|
||||
public Guid interfaceClassGuid;
|
||||
public uint flags;
|
||||
private IntPtr reserved;
|
||||
IntPtr reserved;
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
|
||||
@@ -291,7 +291,7 @@ namespace DiscImageChef.Devices.Windows
|
||||
}
|
||||
|
||||
// return a unique device number for the given device path
|
||||
private static int GetDeviceNumber(string devicePath)
|
||||
static int GetDeviceNumber(string devicePath)
|
||||
{
|
||||
int ans = -1;
|
||||
|
||||
|
||||
@@ -933,7 +933,7 @@ namespace DiscImageChef.DiscImages
|
||||
#endregion Unsupported features
|
||||
|
||||
#region Private methods
|
||||
private static uint DC42CheckSum(byte[] buffer)
|
||||
static uint DC42CheckSum(byte[] buffer)
|
||||
{
|
||||
uint dc42Chk = 0;
|
||||
if((buffer.Length & 0x01) == 0x01) return 0xFFFFFFFF;
|
||||
|
||||
@@ -137,17 +137,17 @@ namespace DiscImageChef.DiscImages
|
||||
/// <summary>
|
||||
/// The HDCP file header after the image has been opened
|
||||
/// </summary>
|
||||
private HdcpFileHeader fileHeader;
|
||||
HdcpFileHeader fileHeader;
|
||||
|
||||
/// <summary>
|
||||
/// Every track that has been read is cached here
|
||||
/// </summary>
|
||||
private Dictionary<int, byte[]> trackCache = new Dictionary<int, byte[]>();
|
||||
Dictionary<int, byte[]> trackCache = new Dictionary<int, byte[]>();
|
||||
|
||||
/// <summary>
|
||||
/// The offset in the file where each track starts, or -1 if the track is not present
|
||||
/// </summary>
|
||||
private Dictionary<int, long> trackOffset = new Dictionary<int, long>();
|
||||
Dictionary<int, long> trackOffset = new Dictionary<int, long>();
|
||||
|
||||
/// <summary>
|
||||
/// The ImageFilter we're reading from, after the file has been opened
|
||||
@@ -156,7 +156,7 @@ namespace DiscImageChef.DiscImages
|
||||
#endregion
|
||||
|
||||
#region Internal constants
|
||||
private readonly MediaTypeTableEntry[] mediaTypes =
|
||||
readonly MediaTypeTableEntry[] mediaTypes =
|
||||
{
|
||||
new MediaTypeTableEntry(80, 8, MediaType.DOS_35_DS_DD_8),
|
||||
new MediaTypeTableEntry(80, 9, MediaType.DOS_35_DS_DD_9),
|
||||
@@ -382,7 +382,7 @@ namespace DiscImageChef.DiscImages
|
||||
return MediaType.Unknown;
|
||||
}
|
||||
|
||||
private void ReadTrackIntoCache(Stream stream, int tracknum)
|
||||
void ReadTrackIntoCache(Stream stream, int tracknum)
|
||||
{
|
||||
byte[] trackData = new byte[ImageInfo.SectorSize * ImageInfo.SectorsPerTrack];
|
||||
byte[] blkHeader = new byte[3];
|
||||
|
||||
Reference in New Issue
Block a user