ImageResizer  3.4.0
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events
Public Member Functions | Properties | List of all members
ImageResizer.Plugins.DiskCache.CachedFileInfo Class Reference

Public Member Functions

 CachedFileInfo (FileInfo f)
 
 CachedFileInfo (FileInfo f, CachedFileInfo old)
 Uses old.AccessedUtc if it is newer than FileInfo.LastAccessTimeUtc More...
 
 CachedFileInfo (DateTime modifiedDate, DateTime createdDate)
 
 CachedFileInfo (DateTime modifiedDate, DateTime createdDate, DateTime accessedDate)
 
 CachedFileInfo (CachedFileInfo f, DateTime accessedDate)
 

Properties

DateTime ModifiedUtc [get]
 The modified date of the source file that the cached file is based on. More...
 
DateTime AccessedUtc [get]
 The last time the file was accessed. Will not match NTFS date, this value is updated by DiskCache. When first loaded from NTFS, it will be granular to about an hour, due to NTFS delayed write. Also, windows Vista and higher never write accessed dates. We update this value in memory, and flush it to disk lazily. More...
 
DateTime UpdatedUtc [get]
 The Created date of the cached file - the last time the cached file was written to More...
 

Detailed Description

Definition at line 9 of file CachedFileInfo.cs.

Constructor & Destructor Documentation

ImageResizer.Plugins.DiskCache.CachedFileInfo.CachedFileInfo ( FileInfo  f,
CachedFileInfo  old 
)
inline

Uses old.AccessedUtc if it is newer than FileInfo.LastAccessTimeUtc

Parameters
f
old

Definition at line 20 of file CachedFileInfo.cs.

20  {
21  modifiedUtc = f.LastWriteTimeUtc;
22  accessedUtc = f.LastAccessTimeUtc;
23  if (old != null && accessedUtc < old.accessedUtc) accessedUtc = old.accessedUtc; //Use the larger value
24  updatedUtc = f.CreationTimeUtc;
25  }

Property Documentation

DateTime ImageResizer.Plugins.DiskCache.CachedFileInfo.AccessedUtc
get

The last time the file was accessed. Will not match NTFS date, this value is updated by DiskCache. When first loaded from NTFS, it will be granular to about an hour, due to NTFS delayed write. Also, windows Vista and higher never write accessed dates. We update this value in memory, and flush it to disk lazily.

Definition at line 55 of file CachedFileInfo.cs.

DateTime ImageResizer.Plugins.DiskCache.CachedFileInfo.ModifiedUtc
get

The modified date of the source file that the cached file is based on.

Definition at line 46 of file CachedFileInfo.cs.

DateTime ImageResizer.Plugins.DiskCache.CachedFileInfo.UpdatedUtc
get

The Created date of the cached file - the last time the cached file was written to

Definition at line 62 of file CachedFileInfo.cs.


The documentation for this class was generated from the following file: