Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | Private Member Functions | Private Attributes | Static Private Attributes

SharedMemory Class Reference
[Application-wide cache subsystem]

Sys-V shared memory cache. More...

Inheritance diagram for SharedMemory:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 __construct ($defaultSize=self::DEFAULT_SEGMENT_SIZE, $customSized=array())
 __destruct ()
 increment ($key, $value)
 decrement ($key, $value)
 get ($key)
 delete ($key)
 isAlive ()
 clean ()
 append ($key, $data)

Static Public Member Functions

static create ($defaultSize=self::DEFAULT_SEGMENT_SIZE, $customSized=array())

Public Attributes

const INDEX_SEGMENT = 12345678
const DEFAULT_SEGMENT_SIZE = 4194304

Protected Member Functions

 store ($action, $key, $value, $expires=0)

Private Member Functions

 getSegment ()
 stringToInt ($string)

Private Attributes

 $defaultSize = null
 $customSized = array()

Static Private Attributes

static $attached = array()

Detailed Description

Sys-V shared memory cache.

Definition at line 17 of file SharedMemory.class.php.


Constructor & Destructor Documentation

SharedMemory::__construct ( defaultSize = self::DEFAULT_SEGMENT_SIZE,
customSized = array() 
)
Returns:
SharedMemory

Definition at line 42 of file SharedMemory.class.php.

References $customSized, and $defaultSize.

SharedMemory::__destruct (  ) 

Definition at line 51 of file SharedMemory.class.php.


Member Function Documentation

SharedMemory::append ( key,
data 
)

Reimplemented from CachePeer.

Definition at line 175 of file SharedMemory.class.php.

References getSegment(), store(), and stringToInt().

Here is the call graph for this function:

SharedMemory::clean (  ) 
Returns:
SharedMemory

Reimplemented from CachePeer.

Definition at line 150 of file SharedMemory.class.php.

References stringToInt().

Here is the call graph for this function:

static SharedMemory::create ( defaultSize = self::DEFAULT_SEGMENT_SIZE,
customSized = array() 
) [static]
Returns:
SharedMemory

Definition at line 31 of file SharedMemory.class.php.

References $customSized, and $defaultSize.

SharedMemory::decrement ( key,
value 
)

Reimplemented from CachePeer.

Definition at line 94 of file SharedMemory.class.php.

SharedMemory::delete ( key  ) 

Reimplemented from CachePeer.

Definition at line 128 of file SharedMemory.class.php.

References getSegment(), Assert::isUnreachable(), and stringToInt().

Here is the call graph for this function:

SharedMemory::get ( key  ) 

Reimplemented from CachePeer.

Definition at line 104 of file SharedMemory.class.php.

References getSegment(), Assert::isUnreachable(), CachePeer::restoreData(), and stringToInt().

Here is the call graph for this function:

SharedMemory::getSegment (  )  [private]

Definition at line 228 of file SharedMemory.class.php.

References SelectivePeer::getClassName(), and stringToInt().

Referenced by append(), delete(), get(), and store().

Here is the call graph for this function:

SharedMemory::increment ( key,
value 
)

Reimplemented from CachePeer.

Definition at line 84 of file SharedMemory.class.php.

SharedMemory::isAlive (  ) 

Reimplemented from CachePeer.

Definition at line 141 of file SharedMemory.class.php.

SharedMemory::store ( action,
key,
value,
expires = 0 
) [protected]

Reimplemented from CachePeer.

Definition at line 201 of file SharedMemory.class.php.

References getSegment(), Assert::isUnreachable(), CachePeer::prepareData(), and stringToInt().

Referenced by append().

Here is the call graph for this function:

SharedMemory::stringToInt ( string  )  [private]

Definition at line 244 of file SharedMemory.class.php.

Referenced by append(), clean(), delete(), get(), getSegment(), and store().


Member Data Documentation

SharedMemory::$attached = array() [static, private]

Definition at line 26 of file SharedMemory.class.php.

SharedMemory::$customSized = array() [private]

Definition at line 24 of file SharedMemory.class.php.

Referenced by __construct(), and create().

SharedMemory::$defaultSize = null [private]

Definition at line 23 of file SharedMemory.class.php.

Referenced by __construct(), and create().

Definition at line 21 of file SharedMemory.class.php.

const SharedMemory::INDEX_SEGMENT = 12345678

Definition at line 19 of file SharedMemory.class.php.


The documentation for this class was generated from the following file: