mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-10 02:13:17 +08:00
@ -49,23 +49,30 @@ class DbMessageSource extends MessageSource
|
|||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* Prefix which would be used when generating cache key.
|
* Prefix which would be used when generating cache key.
|
||||||
|
* @deprecated This constant has never been used and will be removed in 2.1.0.
|
||||||
*/
|
*/
|
||||||
const CACHE_KEY_PREFIX = 'DbMessageSource';
|
const CACHE_KEY_PREFIX = 'DbMessageSource';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Connection|array|string the DB connection object or the application component ID of the DB connection.
|
* @var Connection|array|string the DB connection object or the application component ID of the DB connection.
|
||||||
|
*
|
||||||
* After the DbMessageSource object is created, if you want to change this property, you should only assign
|
* After the DbMessageSource object is created, if you want to change this property, you should only assign
|
||||||
* it with a DB connection object.
|
* it with a DB connection object.
|
||||||
|
*
|
||||||
* Starting from version 2.0.2, this can also be a configuration array for creating the object.
|
* Starting from version 2.0.2, this can also be a configuration array for creating the object.
|
||||||
*/
|
*/
|
||||||
public $db = 'db';
|
public $db = 'db';
|
||||||
/**
|
/**
|
||||||
* @var Cache|array|string the cache object or the application component ID of the cache object.
|
* @var Cache|array|string the cache object or the application component ID of the cache object.
|
||||||
* The messages data will be cached using this cache object. Note, this property has meaning only
|
* The messages data will be cached using this cache object.
|
||||||
* in case [[cachingDuration]] set to non-zero value and [[enableCaching]] is true.
|
* Note, that to enable caching you have to set [[enableCaching]] to `true`, otherwise setting this property has no effect.
|
||||||
|
*
|
||||||
* After the DbMessageSource object is created, if you want to change this property, you should only assign
|
* After the DbMessageSource object is created, if you want to change this property, you should only assign
|
||||||
* it with a cache object.
|
* it with a cache object.
|
||||||
|
*
|
||||||
* Starting from version 2.0.2, this can also be a configuration array for creating the object.
|
* Starting from version 2.0.2, this can also be a configuration array for creating the object.
|
||||||
|
* @see cachingDuration
|
||||||
|
* @see enableCaching
|
||||||
*/
|
*/
|
||||||
public $cache = 'cache';
|
public $cache = 'cache';
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user