This package can cache a script output to avoid running it again.
It can check if a given cache file exists in a given cache directory.
If the file does not exist or it was created after a time more than the cache expiry time, the class starts capturing the output of the current script. Otherwise, it outputs the previous cached content.
If the cached content was not yet previously stored in the cache file or it was stored but it already expired, the class stores the current script output in the cache file after the script ends. |