mirror of
https://github.com/aaru-dps/Aaru.Decoders.git
synced 2025-12-16 19:24:32 +00:00
Convert local variable or field into constant.
This commit is contained in:
@@ -484,7 +484,7 @@ public static class PFI
|
|||||||
_ => $"unknown size identifier {decoded.DiscSize}"
|
_ => $"unknown size identifier {decoded.DiscSize}"
|
||||||
};
|
};
|
||||||
|
|
||||||
var categorySentence = "Disc is a {0} {1} version {2}";
|
const string categorySentence = "Disc is a {0} {1} version {2}";
|
||||||
|
|
||||||
switch(decoded.DiskCategory)
|
switch(decoded.DiskCategory)
|
||||||
{
|
{
|
||||||
@@ -669,7 +669,7 @@ public static class PFI
|
|||||||
|
|
||||||
if(decoded.RecordedBookType != decoded.DiskCategory)
|
if(decoded.RecordedBookType != decoded.DiskCategory)
|
||||||
{
|
{
|
||||||
var bookTypeSentence = "Disc book type is {0}";
|
const string bookTypeSentence = "Disc book type is {0}";
|
||||||
|
|
||||||
switch(decoded.RecordedBookType)
|
switch(decoded.RecordedBookType)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -222,7 +222,7 @@ public static class CIS
|
|||||||
var buffer = new List<byte>();
|
var buffer = new List<byte>();
|
||||||
List<string> strings = null;
|
List<string> strings = null;
|
||||||
var firstString = false;
|
var firstString = false;
|
||||||
var secondString = false;
|
const bool secondString = false;
|
||||||
|
|
||||||
var tuple = new Level1VersionTuple
|
var tuple = new Level1VersionTuple
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -128,20 +128,22 @@ public static partial class Modes
|
|||||||
if(page.ReadRetryCount > 0)
|
if(page.ReadRetryCount > 0)
|
||||||
sb.AppendFormat("\tDrive will repeat read operations {0} times", page.ReadRetryCount).AppendLine();
|
sb.AppendFormat("\tDrive will repeat read operations {0} times", page.ReadRetryCount).AppendLine();
|
||||||
|
|
||||||
var AllUsed = "\tAll available recovery procedures will be used.\n";
|
const string AllUsed = "\tAll available recovery procedures will be used.\n";
|
||||||
var CIRCRetriesUsed = "\tOnly retries and CIRC are used.\n";
|
const string CIRCRetriesUsed = "\tOnly retries and CIRC are used.\n";
|
||||||
var RetriesUsed = "\tOnly retries are used.\n";
|
const string RetriesUsed = "\tOnly retries are used.\n";
|
||||||
var RecoveredNotReported = "\tRecovered errors will not be reported.\n";
|
const string RecoveredNotReported = "\tRecovered errors will not be reported.\n";
|
||||||
var RecoveredReported = "\tRecovered errors will be reported.\n";
|
const string RecoveredReported = "\tRecovered errors will be reported.\n";
|
||||||
var RecoveredAbort = "\tRecovered errors will be reported and aborted with CHECK CONDITION.\n";
|
const string RecoveredAbort = "\tRecovered errors will be reported and aborted with CHECK CONDITION.\n";
|
||||||
var UnrecECCAbort = "\tUnrecovered ECC errors will return CHECK CONDITION.";
|
const string UnrecECCAbort = "\tUnrecovered ECC errors will return CHECK CONDITION.";
|
||||||
var UnrecCIRCAbort = "\tUnrecovered CIRC errors will return CHECK CONDITION.";
|
const string UnrecCIRCAbort = "\tUnrecovered CIRC errors will return CHECK CONDITION.";
|
||||||
var UnrecECCNotAbort = "\tUnrecovered ECC errors will not abort the transfer.";
|
const string UnrecECCNotAbort = "\tUnrecovered ECC errors will not abort the transfer.";
|
||||||
var UnrecCIRCNotAbort = "\tUnrecovered CIRC errors will not abort the transfer.";
|
const string UnrecCIRCNotAbort = "\tUnrecovered CIRC errors will not abort the transfer.";
|
||||||
|
|
||||||
var UnrecECCAbortData = "\tUnrecovered ECC errors will return CHECK CONDITION and the uncorrected data.";
|
const string UnrecECCAbortData =
|
||||||
|
"\tUnrecovered ECC errors will return CHECK CONDITION and the uncorrected data.";
|
||||||
|
|
||||||
var UnrecCIRCAbortData = "\tUnrecovered CIRC errors will return CHECK CONDITION and the uncorrected data.";
|
const string UnrecCIRCAbortData =
|
||||||
|
"\tUnrecovered CIRC errors will return CHECK CONDITION and the uncorrected data.";
|
||||||
|
|
||||||
switch(page.Parameter)
|
switch(page.Parameter)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -93,20 +93,22 @@ public static partial class Modes
|
|||||||
if(page.VerifyRetryCount > 0)
|
if(page.VerifyRetryCount > 0)
|
||||||
sb.AppendFormat("\tDrive will repeat verify operations {0} times", page.VerifyRetryCount).AppendLine();
|
sb.AppendFormat("\tDrive will repeat verify operations {0} times", page.VerifyRetryCount).AppendLine();
|
||||||
|
|
||||||
var AllUsed = "\tAll available recovery procedures will be used.\n";
|
const string AllUsed = "\tAll available recovery procedures will be used.\n";
|
||||||
var CIRCRetriesUsed = "\tOnly retries and CIRC are used.\n";
|
const string CIRCRetriesUsed = "\tOnly retries and CIRC are used.\n";
|
||||||
var RetriesUsed = "\tOnly retries are used.\n";
|
const string RetriesUsed = "\tOnly retries are used.\n";
|
||||||
var RecoveredNotReported = "\tRecovered errors will not be reported.\n";
|
const string RecoveredNotReported = "\tRecovered errors will not be reported.\n";
|
||||||
var RecoveredReported = "\tRecovered errors will be reported.\n";
|
const string RecoveredReported = "\tRecovered errors will be reported.\n";
|
||||||
var RecoveredAbort = "\tRecovered errors will be reported and aborted with CHECK CONDITION.\n";
|
const string RecoveredAbort = "\tRecovered errors will be reported and aborted with CHECK CONDITION.\n";
|
||||||
var UnrecECCAbort = "\tUnrecovered ECC errors will return CHECK CONDITION.";
|
const string UnrecECCAbort = "\tUnrecovered ECC errors will return CHECK CONDITION.";
|
||||||
var UnrecCIRCAbort = "\tUnrecovered CIRC errors will return CHECK CONDITION.";
|
const string UnrecCIRCAbort = "\tUnrecovered CIRC errors will return CHECK CONDITION.";
|
||||||
var UnrecECCNotAbort = "\tUnrecovered ECC errors will not abort the transfer.";
|
const string UnrecECCNotAbort = "\tUnrecovered ECC errors will not abort the transfer.";
|
||||||
var UnrecCIRCNotAbort = "\tUnrecovered CIRC errors will not abort the transfer.";
|
const string UnrecCIRCNotAbort = "\tUnrecovered CIRC errors will not abort the transfer.";
|
||||||
|
|
||||||
var UnrecECCAbortData = "\tUnrecovered ECC errors will return CHECK CONDITION and the uncorrected data.";
|
const string UnrecECCAbortData =
|
||||||
|
"\tUnrecovered ECC errors will return CHECK CONDITION and the uncorrected data.";
|
||||||
|
|
||||||
var UnrecCIRCAbortData = "\tUnrecovered CIRC errors will return CHECK CONDITION and the uncorrected data.";
|
const string UnrecCIRCAbortData =
|
||||||
|
"\tUnrecovered CIRC errors will return CHECK CONDITION and the uncorrected data.";
|
||||||
|
|
||||||
switch(page.Parameter)
|
switch(page.Parameter)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user