common.cache
[ class tree: common.cache ] [ index: common.cache ] [ all elements ]

Class: SerializingCache

Source Location: /cache/SerializingCache.class.php

Class Overview


Serializing Cache decorator


Author(s):

  • Tyler Tompkins (ttompkins@mojavi.org)

Variables

Methods



Class Details

[line 19]
Serializing Cache decorator



Tags:

since:  4.0.0 $Id: SerializingCache.class.php 913 2005-11-21 21:58:53Z illusina $
author:  Tyler Tompkins (ttompkins@mojavi.org)


[ Top ]


Class Variables

$cache =  null

[line 25]



Tags:

access:  protected

Type:   mixed


[ Top ]



Class Methods


constructor __construct [line 37]

SerializingCache __construct( Cache $cache)

Construct this object against the Cache object it wants to decorate



Tags:

access:  public
since:  4.0.0
author:  Tyler Tompkins (ttompkins@mojavi.org)


Parameters:

Cache   $cache   A Cache instance

[ Top ]

method clearAll [line 54]

bool clearAll( )

Clear the entire cache



Tags:

return:  True on success, false otherwise
access:  public
since:  4.0.0
author:  Tyler Tompkins (ttompkins@mojavi.org)


[ Top ]

method clearCache [line 71]

bool clearCache( mixed $handle)

Clear a paritcular cache instance



Tags:

return:  True on success, false otherwise
access:  public
since:  4.0.0
author:  Tyler Tompkins (ttompkins@mojavi.org)


[ Top ]

method getCache [line 114]

mixed &getCache( string $handle)

Retrieve a cache



Tags:

return:  The cache value, or false on failure
access:  public
since:  4.0.0
author:  Tyler Tompkins (ttompkins@mojavi.org)


Parameters:

string   $handle   A handle name

[ Top ]

method hasCache [line 136]

bool hasCache( string $handle)

Determine if a cache instance exists



Tags:

return:  True on success, false otherwise
access:  public
since:  4.0.0
author:  Tyler Tompkins (ttompkins@mojavi.org)


Parameters:

string   $handle   A handle name

[ Top ]

method isExpired [line 155]

bool isExpired( string $handle, mixed $time)

Determine if a handle is older than $time, where time is an absolute unix timestamp value relative to the epoch



Tags:

return:  True if expired, false otherwise
access:  public
since:  4.0.0
author:  Tyler Tompkins (ttompkins@mojavi.org)


Parameters:

string   $handle   A handle name

[ Top ]

method isExpiredRelative [line 176]

bool isExpiredRelative( string $handle, mixed $expirationTime)

Determine if a handle is older than $time, where time is an relative value in seconds from the current time



Tags:

return:  True if expired, false otherwise
access:  public
since:  4.0.0
author:  Tyler Tompkins (ttompkins@mojavi.org)


Parameters:

string   $handle   A handle name

[ Top ]

method setCache [line 91]

bool setCache( string $handle, mixed &$value)

Set a cache value to the cache handle



Tags:

return:  True on success, false otherwise
access:  public
since:  4.0.0
author:  Tyler Tompkins (ttompkins@mojavi.org)


Parameters:

string   $handle   A handle name
mixed   &$value   A handle value

[ Top ]


Documentation generated on Tue, 21 Feb 2006 02:30:00 +0900 by phpDocumentor 1.3.0RC5