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

Class: Cache

Source Location: /cache/Cache.iface.php

Interface Overview


A simple Cache interface


Author(s):

  • Tyler Tompkins (ttompkins@mojavi.org)

Methods



Class Details

[line 19]
A simple Cache interface



Tags:

since:  4.0.0 $Id: Cache.iface.php 886 2005-11-12 10:54:07Z illusina $
author:  Tyler Tompkins (ttompkins@mojavi.org)


[ Top ]


Class Methods


method clearAll [line 32]

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 44]

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 72]

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 85]

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 99]

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 115]

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 59]

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:29:39 +0900 by phpDocumentor 1.3.0RC5