Class flCacheFunction
flCacheFunction Class
Class to allow the results of a function or method call to be cached.
Package: fusionLib
Copyright:
Copyright (c) 2008 - 2013 fusionLib. All rights reserved.
Located at system/libs/Cache/flCacheFunction.php
Methods summary
public static
mixed
|
#
call( flCache $cache, string $function, array $params = array(), integer $lifetime = null )
Call a function caching the output/return.
Call a function caching the output/return.
If the function outputs data to the browser then that is detected and captured in the cache.
Parameters
- $cache
- cache object to use.
- $function
- The name of the function to call, can also be array($object, 'function).
- $params
- The array of parameters to pass to the function.
- $lifetime
- The lifetime of the object in seconds, null to use the default or 0 to never expire.
Returns
mixed The result of the function or the cached results.
|