Class Swift_KeyCache_DiskKeyCache
A KeyCache which streams to and from disk.
- Swift_KeyCache_DiskKeyCache implements Swift_KeyCache
Author: Chris Corbyn
Located at vendors/swiftmailer/lib/classes/Swift/KeyCache/DiskKeyCache.php
Methods summary
public
|
#
__construct(
Create a new DiskKeyCache with the given $stream for cloning to make InputByteStreams, and the given $path to save to. |
public
|
#
setString( string $nsKey, string $itemKey, string $string, integer $mode )
Set a string into the cache under $itemKey for the namespace $nsKey. |
public
|
#
importFromByteStream( string $nsKey, string $itemKey,
Set a ByteStream into the cache under $itemKey for the namespace $nsKey. |
public
|
#
getInputByteStream( string $nsKey, string $itemKey,
Provides a ByteStream which when written to, writes data to $itemKey. NOTE: The stream will always write in append mode. |
public
string
|
|
public
|
#
exportToByteStream( string $nsKey, string $itemKey,
Get data back out of the cache as a ByteStream. |
public
boolean
|
#
hasKey( string $nsKey, string $itemKey )
Check if the given $itemKey exists in the namespace $nsKey. |
public
|
#
clearKey( string $nsKey, string $itemKey )
Clear data for $itemKey in the namespace $nsKey if it exists. |
public
|
|
private
|
|
private
resource
|
#
_getHandle( string $nsKey, string $itemKey, integer $position )
Get a file handle on the cache item. |
private
|
|
public
|
Magic methods summary
Constants summary
integer |
POSITION_START |
0 |
#
Signal to place pointer at start of file |
integer |
POSITION_END |
1 |
#
Signal to place pointer at end of file |
integer |
POSITION_CURRENT |
2 |
#
Signal to leave pointer in whatever position it currently is |
Constants inherited from Swift_KeyCache
Properties summary
private
|
$_stream |
#
An InputStream for cloning. |
private
string
|
$_path |
#
A path to write to. |
private
array
|
$_keys |
#
Stored keys. |
private
boolean
|
$_quotes |
#
Will be true if magic_quotes_runtime is turned on. |