Class CI_DB_Cache - echiong/testRepo GitHub Wiki
##Class CI_DB_Cache
Database Cache Class
Category:
Database
Author:
ExpressionEngine Dev Team
Link:
http://codeigniter.com/user_guide/database/
Located at system/database/DB_cache.php
##Methods summary
public __construct ( mixed & $db )
Constructor
Grabs the CI super object instance so we can access it.
public boolean check_path ( string $path = '' )
Set Cache Directory Path
Parameters
$path
string
the path to the cache directory
Returns
boolean
public string read ( mixed $sql )
Retrieve a cached query
The URI being requested will become the name of the cache sub-folder. An MD5 hash of the SQL statement will become the cache file name
Returns
string
public boolean write ( mixed $sql, mixed $object )
Write a query to a cache file
Returns
boolean
public boolean delete ( mixed $segment_one = '', mixed $segment_two = '' )
Delete cache files within a particular directory
Returns
boolean
public boolean delete_all ( )
Delete all existing cache files
Returns
boolean
<table class="summary" id="properties">
<caption>Properties summary</caption>
<tr data-order="CI" id="$CI">
<td class="attributes"><code>
public
mixed
</code></td>
<td class="name">
$CI
<div class="description detailed">
</div>
</div></td>
</tr>
<tr data-order="db" id="$db">
<td class="attributes"><code>
public
mixed
</code></td>
<td class="name">
$db
<div class="description detailed">
</div>
</div></td>
</tr>
</table>