Property | Type | Description | |
---|---|---|---|
$cacheResults | boolean | Whether or not to cache this call's results | |
$settings | array | Settings |
Method | Description | |
---|---|---|
beforeDelete ( Model $Model, $cascade = true ) | Intercepts delete to use the caching datasource instead | |
beforeFind ( Model $Model, array $queryData ) | Intercepts find to use the caching datasource instead | |
beforeSave ( Model $Model, $options = [] ) | Intercepts save to use the caching datasource instead | |
clearCache ( Model $Model, $queryData = null ) : boolean | Clears all of the cache for this model's find queries. Optionally, pass $queryData to just clear a specific query | |
setup ( Model $Model, array $config = [] ) | Sets up a connection using passed settings |
Method | Description | |
---|---|---|
_prepareFind ( Model $Model, $query = [] ) | * Prepares a query by adding missing data. This function is needed because reads on the database typically bypass Model::find() which is where the query is changed. |
protected _prepareFind ( Model $Model, $query = [] ) | ||
$Model | Model | |
$query | The query |
public beforeDelete ( Model $Model, $cascade = true ) | ||
$Model | Model | The calling model |
public beforeFind ( Model $Model, array $queryData ) | ||
$Model | Model | The calling model |
$queryData | array | The query |
public beforeSave ( Model $Model, $options = [] ) | ||
$Model | Model | The calling model |
public clearCache ( Model $Model, $queryData = null ) : boolean | ||
$Model | Model | The calling model |
return | boolean |
public bool $cacheResults | ||
return | boolean |