mirror of
https://github.com/aaru-dps/Aaru.Server.git
synced 2025-12-16 19:24:27 +00:00
DOCUMENTATION: Removed unneeded AppleDouble DateTime handler.
This commit is contained in:
@@ -590,8 +590,8 @@ namespace DiscImageChef.Filters
|
|||||||
fs.Read(dates_b, 0, 16);
|
fs.Read(dates_b, 0, 16);
|
||||||
AppleDoubleFileDates dates =
|
AppleDoubleFileDates dates =
|
||||||
BigEndianMarshal.ByteArrayToStructureBigEndian<AppleDoubleFileDates>(dates_b);
|
BigEndianMarshal.ByteArrayToStructureBigEndian<AppleDoubleFileDates>(dates_b);
|
||||||
creationTime = DateHandlers.AppleDoubleToDateTime(dates.creationDate);
|
creationTime = DateHandlers.UNIXUnsignedToDateTime(dates.creationDate);
|
||||||
lastWriteTime = DateHandlers.AppleDoubleToDateTime(dates.modificationDate);
|
lastWriteTime = DateHandlers.UNIXUnsignedToDateTime(dates.modificationDate);
|
||||||
break;
|
break;
|
||||||
case AppleDoubleEntryID.FileInfo:
|
case AppleDoubleEntryID.FileInfo:
|
||||||
fs.Seek(entry.offset, SeekOrigin.Begin);
|
fs.Seek(entry.offset, SeekOrigin.Begin);
|
||||||
|
|||||||
@@ -315,8 +315,8 @@ namespace DiscImageChef.Filters
|
|||||||
ms.Read(dates_b, 0, 16);
|
ms.Read(dates_b, 0, 16);
|
||||||
AppleSingleFileDates dates =
|
AppleSingleFileDates dates =
|
||||||
BigEndianMarshal.ByteArrayToStructureBigEndian<AppleSingleFileDates>(dates_b);
|
BigEndianMarshal.ByteArrayToStructureBigEndian<AppleSingleFileDates>(dates_b);
|
||||||
creationTime = DateHandlers.AppleDoubleToDateTime(dates.creationDate);
|
creationTime = DateHandlers.UNIXUnsignedToDateTime(dates.creationDate);
|
||||||
lastWriteTime = DateHandlers.AppleDoubleToDateTime(dates.modificationDate);
|
lastWriteTime = DateHandlers.UNIXUnsignedToDateTime(dates.modificationDate);
|
||||||
break;
|
break;
|
||||||
case AppleSingleEntryID.FileInfo:
|
case AppleSingleEntryID.FileInfo:
|
||||||
ms.Seek(entry.offset, SeekOrigin.Begin);
|
ms.Seek(entry.offset, SeekOrigin.Begin);
|
||||||
|
|||||||
@@ -44,7 +44,6 @@ namespace DiscImageChef
|
|||||||
// Day 0 of Julian Date system
|
// Day 0 of Julian Date system
|
||||||
static readonly DateTime JulianEpoch = new DateTime(1858, 11, 17, 0, 0, 0);
|
static readonly DateTime JulianEpoch = new DateTime(1858, 11, 17, 0, 0, 0);
|
||||||
static readonly DateTime AmigaEpoch = new DateTime(1978, 1, 1, 0, 0, 0);
|
static readonly DateTime AmigaEpoch = new DateTime(1978, 1, 1, 0, 0, 0);
|
||||||
static readonly DateTime AppleDoubleEpoch = new DateTime(1970, 1, 1, 0, 0, 0);
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Converts a Macintosh timestamp to a .NET DateTime
|
/// Converts a Macintosh timestamp to a .NET DateTime
|
||||||
@@ -290,12 +289,6 @@ namespace DiscImageChef
|
|||||||
return temp;
|
return temp;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: This is unix
|
|
||||||
public static DateTime AppleDoubleToDateTime(ulong AppleDoubleTimeStamp)
|
|
||||||
{
|
|
||||||
return AppleDoubleEpoch.AddSeconds(AppleDoubleTimeStamp);
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Converts an ECMA timestamp to a .NET DateTime
|
/// Converts an ECMA timestamp to a .NET DateTime
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
Reference in New Issue
Block a user