[sgen] Refactor collection logging
[mono.git] / mcs / class / WindowsBase / ZipSharp / ZipFileInfo.cs
1 // ZipFileInfo.cs created with MonoDevelop
2 // User: alan at 12:14 13/10/2008
3 //
4 // To change standard headers go to Edit->Preferences->Coding->Standard Headers
5 //
6
7 using System;
8
9 namespace zipsharp
10 {
11         struct ZipFileInfo
12         {
13                 ZipTime date;
14                 IntPtr dosDate;
15                 IntPtr internalFileAttributes;
16                 IntPtr externalFileAttributes;
17
18                 public DateTime FileTime
19                 {
20                         get { return date.Date; }
21                 }
22
23                 public long DosDate
24                 {
25                         get { return dosDate.ToInt64 (); }
26                 }
27                 
28                 internal long InternalFileAttributes
29                 {
30                         get { return internalFileAttributes.ToInt64 (); }
31                 }
32
33                 internal long ExternalFileAttributes
34                 {
35                         get { return externalFileAttributes.ToInt64 (); }
36                 }
37                 
38                 public ZipFileInfo (DateTime fileTime)
39                 {
40                         date = new ZipTime (fileTime);
41                         dosDate = new IntPtr ((int)fileTime.ToFileTime ());
42                         internalFileAttributes = IntPtr.Zero;
43                         externalFileAttributes = IntPtr.Zero;
44                 }
45
46         }
47 }