Class LinkedCacheSet

Description

Quasi-equivalent (superior in some repects) to Java's LinkedHashSet. Uses memcached as a storage mechanism for persisting set data beyond the scope of the current request.

Located in /LinkedCacheSet.php (line 46)

CacheSet
   |
   --LinkedCacheSet
Method Summary
LinkedCacheSet __construct (string $name)
void __destruct ()
void add (mixed $value, mixed $key)
mixed current ()
mixed delete (mixed $key)
mixed first ()
mixed last ()
void move (int $delta, [boolean $forward = true])
mixed next ()
mixed previous ()
mixed seek (mixed $key)
void set (mixed $key, mixed $value)
Variables

Inherited Variables

Inherited from CacheSet

CacheSet::$cache
CacheSet::$name
CacheSet::$set
Methods
Constructor __construct (line 53)

Class constructor

  • access: public
LinkedCacheSet __construct (string $name)
  • string $name

Redefinition of:
CacheSet::__construct()
Class constructor
Destructor __destruct (line 61)

Class destructor

  • access: public
void __destruct ()

Redefinition of:
CacheSet::__destruct()
Class destructor
add (line 70)

Adds the specified element to the end of the set. The internal pointer is updated to the position of the element (last in the set).

  • access: public
void add (mixed $value, mixed $key)
  • mixed $key
  • mixed $value

Redefinition of:
CacheSet::add()
Adds the specified element to the end of the set.
current (line 81)

Returns the element referenced by the internal pointer, or null if there is no element at the current position.

  • access: public
mixed current ()
delete (line 93)

Deletes and returns the specified element from the set, or returns null if the element does not exist. The internal pointer is updated to the first element in the set.

  • access: public
mixed delete (mixed $key)
  • mixed $key

Redefinition of:
CacheSet::delete()
Deletes and returns the specified element from the set, or returns null if the element does not exist.
first (line 105)

Updates the internal pointer to the first element in the set and returns that element, or false if the set is empty.

  • access: public
mixed first ()
last (line 115)

Updates the internal pointer to the last element in the set and returns that element, or false if the set is empty.

  • access: public
mixed last ()
move (line 129)

Moves the internal pointer by a magnitude of $delta. The default is to move the pointer in a forward direction.

  • access: protected
void move (int $delta, [boolean $forward = true])
  • int $delta
  • boolean $forward: = true
next (line 141)

Updates the internal pointer to the next element in the set and returns that element, or false if there is no element at that location.

  • access: public
mixed next ()
previous (line 151)

Updates the internal pointer to the previous element in the set and returns that element, or false if there is no element at that location.

  • access: public
mixed previous ()
seek (line 162)

Updates the internal pointer to the specified element in the set and returns that element, or returns false if key does not exist.

  • access: public
mixed seek (mixed $key)
  • mixed $key
set (line 184)

Updates the specified element's value within the set. The internal pointer is updated to the position of the element.

  • access: public
void set (mixed $key, mixed $value)
  • mixed $key
  • mixed $value

Redefinition of:
CacheSet::set()
Updates the specified element's value within the set.

Inherited Methods

Inherited From CacheSet

CacheSet::__construct()
CacheSet::add()
CacheSet::contains()
CacheSet::copy()
CacheSet::delete()
CacheSet::get()
CacheSet::indexOf()
CacheSet::isEmpty()
CacheSet::load()
CacheSet::purge()
CacheSet::save()
CacheSet::set()
CacheSet::size()
CacheSet::sort()
CacheSet::sortByKey()
CacheSet::update()
CacheSet::valueOf()
CacheSet::__destruct()

Documentation generated on Thu, 14 Feb 2008 09:14:28 -0500 by phpDocumentor 1.4.1