Reformatted.

This commit is contained in:
2016-04-19 02:11:47 +01:00
parent 6a8499f8ed
commit f8bc81d4f5
149 changed files with 6983 additions and 6970 deletions

View File

@@ -75,61 +75,61 @@ namespace DiscImageChef
int year, month, day, hour, minute, second, hundredths;
byte[] twocharvalue = new byte[2];
byte[] fourcharvalue = new byte[4];
fourcharvalue[0] = VDDateTime[0];
fourcharvalue[1] = VDDateTime[1];
fourcharvalue[2] = VDDateTime[2];
fourcharvalue[3] = VDDateTime[3];
DicConsole.DebugWriteLine("ISO9600ToDateTime handler", "year = \"{0}\"", StringHandlers.CToString(fourcharvalue));
if (!Int32.TryParse(StringHandlers.CToString(fourcharvalue), out year))
if(!Int32.TryParse(StringHandlers.CToString(fourcharvalue), out year))
year = 0;
// year = Convert.ToInt32(StringHandlers.CToString(fourcharvalue));
// year = Convert.ToInt32(StringHandlers.CToString(fourcharvalue));
twocharvalue[0] = VDDateTime[4];
twocharvalue[1] = VDDateTime[5];
DicConsole.DebugWriteLine("ISO9600ToDateTime handler", "month = \"{0}\"", StringHandlers.CToString(twocharvalue));
if (!Int32.TryParse(StringHandlers.CToString(twocharvalue), out month))
if(!Int32.TryParse(StringHandlers.CToString(twocharvalue), out month))
month = 0;
// month = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
// month = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
twocharvalue[0] = VDDateTime[6];
twocharvalue[1] = VDDateTime[7];
DicConsole.DebugWriteLine("ISO9600ToDateTime handler", "day = \"{0}\"", StringHandlers.CToString(twocharvalue));
if (!Int32.TryParse(StringHandlers.CToString(twocharvalue), out day))
if(!Int32.TryParse(StringHandlers.CToString(twocharvalue), out day))
day = 0;
// day = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
// day = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
twocharvalue[0] = VDDateTime[8];
twocharvalue[1] = VDDateTime[9];
DicConsole.DebugWriteLine("ISO9600ToDateTime handler", "hour = \"{0}\"", StringHandlers.CToString(twocharvalue));
if (!Int32.TryParse(StringHandlers.CToString(twocharvalue), out hour))
if(!Int32.TryParse(StringHandlers.CToString(twocharvalue), out hour))
hour = 0;
// hour = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
// hour = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
twocharvalue[0] = VDDateTime[10];
twocharvalue[1] = VDDateTime[11];
DicConsole.DebugWriteLine("ISO9600ToDateTime handler", "minute = \"{0}\"", StringHandlers.CToString(twocharvalue));
if (!Int32.TryParse(StringHandlers.CToString(twocharvalue), out minute))
if(!Int32.TryParse(StringHandlers.CToString(twocharvalue), out minute))
minute = 0;
// minute = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
// minute = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
twocharvalue[0] = VDDateTime[12];
twocharvalue[1] = VDDateTime[13];
DicConsole.DebugWriteLine("ISO9600ToDateTime handler", "second = \"{0}\"", StringHandlers.CToString(twocharvalue));
if (!Int32.TryParse(StringHandlers.CToString(twocharvalue), out second))
if(!Int32.TryParse(StringHandlers.CToString(twocharvalue), out second))
second = 0;
// second = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
// second = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
twocharvalue[0] = VDDateTime[14];
twocharvalue[1] = VDDateTime[15];
DicConsole.DebugWriteLine("ISO9600ToDateTime handler", "hundredths = \"{0}\"", StringHandlers.CToString(twocharvalue));
if (!Int32.TryParse(StringHandlers.CToString(twocharvalue), out hundredths))
if(!Int32.TryParse(StringHandlers.CToString(twocharvalue), out hundredths))
hundredths = 0;
// hundredths = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
// hundredths = Convert.ToInt32(StringHandlers.CToString(twocharvalue));
DicConsole.DebugWriteLine("ISO9600ToDateTime handler", "decodedDT = new DateTime({0}, {1}, {2}, {3}, {4}, {5}, {6}, DateTimeKind.Unspecified);", year, month, day, hour, minute, second, hundredths * 10);
DateTime decodedDT = new DateTime(year, month, day, hour, minute, second, hundredths * 10, DateTimeKind.Unspecified);
return decodedDT;
}