ConstantCacheManager Class Reference
[Controller]
Cache manager that returns a constant value as cache id. More...
Public Member Functions |
|
__construct ($cache_id, $duration=7200, $header_manager=false) | |
Constructor. |
|
get_cache_header_manager () | |
Get cache header manager. |
|
get_cache_id () | |
Return a chache id. |
|
get_creation_datetime () | |
Returns the datetime this cache has been
created. |
|
get_expiration_datetime () | |
Returns the datetime this cache expires.
|
|
initialize ($page_data) | |
Initialize this instance. |
|
set_cache_duration ($seconds) | |
Set Cache duration in seconds.
|
|
set_cache_header_manager (ICacheHeaderManager $manager) | |
Set cache header manager. |
|
set_cache_id ($id) | |
Sets the cache id. |
|
set_creation_datetime ($datetime) | |
Sets the datetime this cache has been
created. |
|
set_expiration_datetime ($datetime) | |
Sets the expiration datetime this cache
expires. |
Detailed Description
Cache manager that returns a constant value as cache id.
Definition at line 8 of file constantcachemanager.cls.php.
Constructor & Destructor Documentation
ConstantCacheManager::__construct | ( | $ | cache_id, | |
$ | duration = 7200 , |
|||
$ | header_manager = false |
|||
) |
Constructor.
- Parameters:
-
mixed $cache_id int $duration Cache duration , defaults to 2 hours ICacheHeaderManager $header_manager Defaults to NoCacheCacheHeaderManager
Definition at line 40 of file constantcachemanager.cls.php.
00040 { 00041 $this->set_cache_id($cache_id); 00042 $this->set_cache_duration($duration); 00043 $this->set_creation_datetime(time()); 00044 if (empty($header_manager)) { $header_manager = CacheHeaderManagerFactory::create(Config::get_value(Config::CACHEHEADER_CLASS_UNCACHED)); } 00045 $this->set_cache_header_manager($header_manager); 00046 }
Member Function Documentation
ConstantCacheManager::get_cache_header_manager | ( | ) |
Get cache header manager.
- Returns:
- ICacheHeaderManager
Implements ICacheManager.
Definition at line 125 of file constantcachemanager.cls.php.
ConstantCacheManager::get_cache_id | ( | ) |
Return a chache id.
Implements ICacheManager.
Reimplemented in SuccessCacheManager.
Definition at line 55 of file constantcachemanager.cls.php.
ConstantCacheManager::get_creation_datetime | ( | ) |
Returns the datetime this cache has been created.
- Returns:
- timestamp
Implements ICacheManager.
Definition at line 91 of file constantcachemanager.cls.php.
ConstantCacheManager::get_expiration_datetime | ( | ) |
Returns the datetime this cache expires.
- Returns:
- timestamp
Implements ICacheManager.
Definition at line 73 of file constantcachemanager.cls.php.
ConstantCacheManager::initialize | ( | $ | page_data | ) |
Initialize this instance.
- Parameters:
-
PageData $page_data
- Returns:
- void
Implements ICacheManager.
Reimplemented in SuccessCacheManager.
Definition at line 48 of file constantcachemanager.cls.php.
ConstantCacheManager::set_cache_duration | ( | $ | seconds | ) |
Set Cache duration in seconds.
- Parameters:
-
int $seconds
Implements ICacheManager.
Definition at line 109 of file constantcachemanager.cls.php.
ConstantCacheManager::set_cache_header_manager | ( | ICacheHeaderManager $ | manager | ) |
Set cache header manager.
Implements ICacheManager.
Definition at line 116 of file constantcachemanager.cls.php.
ConstantCacheManager::set_cache_id | ( | $ | id | ) |
Sets the cache id.
- Parameters:
-
mixed $id
Implements ICacheManager.
Definition at line 64 of file constantcachemanager.cls.php.
ConstantCacheManager::set_creation_datetime | ( | $ | datetime | ) |
Sets the datetime this cache has been created.
- Parameters:
-
timestamp $datetime
Implements ICacheManager.
Definition at line 100 of file constantcachemanager.cls.php.
ConstantCacheManager::set_expiration_datetime | ( | $ | datetime | ) |
Sets the expiration datetime this cache expires.
- Parameters:
-
timestamp $datetime
Implements ICacheManager.
Definition at line 82 of file constantcachemanager.cls.php.
The documentation for this class was generated from the following file:
- gyro/core/controller/base/cachemanager/constantcachemanager.cls.php