dotnet() public static method

public static dotnet ( long dotnetTicks ) : DateTime
dotnetTicks long
return DateTime
Example #1
0
 public OutStream writeNext(Uri path, DateTime modifyTime)
 {
     if (m_zipOut == null)
     {
         throw UnsupportedErr.make("Zip not opened for writing").val;
     }
     if (path.frag() != null)
     {
         throw ArgErr.make("Path must not contain fragment: " + path).val;
     }
     if (path.queryStr() != null)
     {
         throw ArgErr.make("Path must not contain query: " + path).val;
     }
     try
     {
         string zipPath = path.ToString();
         if (zipPath.StartsWith("/"))
         {
             zipPath = zipPath.Substring(1);
         }
         ZipEntry entry = new ZipEntry(zipPath);
         entry.DateTime = new System.DateTime(modifyTime.dotnet());
         m_zipOut.PutNextEntry(entry);
         return(new ZipSysOutStream(m_zipOut));
     }
     catch (System.IO.IOException e)
     {
         throw IOErr.make(e).val;
     }
 }
Example #2
0
 public override void modified(DateTime time)
 {
     m_file.LastAccessTime = new System.DateTime(time.dotnet());
 }
Example #3
0
 public override DateTime modified()
 {
     return(DateTime.dotnet(m_entry.DateTime.Ticks));
 }
Example #4
0
 public override void modified(DateTime time)
 {
     m_file.LastAccessTime = new System.DateTime(time.dotnet());
 }
Example #5
0
 public override DateTime modified()
 {
     return(m_file.Exists ? DateTime.dotnet(m_file.LastAccessTime.Ticks) : null);
 }
Example #6
0
File: Zip.cs Project: nomit007/f4
 public OutStream writeNext(Uri path, DateTime modifyTime)
 {
     if (m_zipOut == null) throw UnsupportedErr.make("Zip not opened for writing").val;
       if (path.frag() != null) throw ArgErr.make("Path must not contain fragment: " + path).val;
       if (path.queryStr() != null) throw ArgErr.make("Path must not contain query: " + path).val;
       try
       {
     string zipPath = path.ToString();
     if (zipPath.StartsWith("/")) zipPath = zipPath.Substring(1);
     ZipEntry entry = new ZipEntry(zipPath);
     entry.DateTime = new System.DateTime(modifyTime.dotnet());
     m_zipOut.PutNextEntry(entry);
     return new ZipSysOutStream(m_zipOut);
       }
       catch (System.IO.IOException e)
       {
     throw IOErr.make(e).val;
       }
 }