[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] |
Gets (or creates) the cached item with the specified name.
Source position: lazfilecache.pas line 85
public function TFileStateCache.FindFile( |
const Filename: string; |
CreateIfNotExists: Boolean |
Filename |
|
Name for the file or directory to locate in the cache. |
CreateIfNotExists |
|
True to create a cache item if it does not already exist. |
Cached item with the specified name, or Nil.
FindFile is a TFileStateCacheItem function used to get, or optionally create, a cache entry for the file or directory in Filename.
FindFile resolves a relative path used in Filename by calling the ResolveDots routine. The normalized name is used to get the TFileStateCacheItem instance in the cache used as the return value for the method.
If Filename was not found in the cache, and CreateIfNotExists is set to True, a TFileStateCacheItem instance is created with the Timestamp for the cache and added to the internal storage. An Exception is raised if the cache item could not be added (and retrieved) using the internal AVL tree storage.
If Filename was not found in the cache, and CreateIfNotExists is set to False, the return value is Nil.
FindFile is used to implement the Check and IncreaseTimeStamp methods.
|
Timestamp (or revision) value for the cache storage. |
|
|
Checks the specified cache item to get a specific flag value. |
|
|
Increments the change counter or updates an item in the state cache. |
|
|
Contains information about a file or directory in the state caching mechanism. |
Version 4.0 | Generated 2025-05-03 | Home |