Class Zend_Session

Description

Implements interfaces:

  • IteratorAggregate (internal interface)

Zend_Session

  • license: New BSD License
  • copyright: Copyright (c) 2005-2007 Zend Technologies USA Inc. (http://www.zend.com)

Located in /Zend/Session.php (line 41)


	
			
Class Constant Summary
Variable Summary
Method Summary
 static void unlockAll ()
 void __construct ([string $namespace = 'Default'], [bool $singleInstance = false], [Zend_Session_Core $core = null])
 ArrayObject getIterator ()
 bool isLocked ()
 void lock ()
 void setExpirationHops (int $hops, [mixed $variables = null], [boolean $hopCountOnUsageOnly = false])
 void setExpirationSeconds (int $seconds, [mixed $variables = null])
 void unlock ()
 true unsetAll ()
 mixed __get (string $name)
 bool __isset (string $name)
 true __set (string $name, mixed $value)
 true __unset (string $name)
Variables
static array $_namespaceLocks = array() (line 68)

Namespace locking mechanism

  • access: protected
static array $_singleInstances = array() (line 75)

Single instance namespace array to ensure data security.

  • access: protected
string $_namespace = "Default" (line 61)

Namespace - which namespace this instance of zend-session is saving-to/getting-from

  • access: protected
Zend_Session_Core $_sessionCore = null (line 54)

Session_Core instance

  • access: protected
Methods
static unlockAll (line 184)

unlockAll() - unmark all session/namespaces to enable read & write

  • access: public
static void unlockAll ()
Constructor __construct (line 89)

__construct() - This will create an instance that saves to/gets from an

instantiated core. An optional namespace allows for saving/getting to isolated sections of the session. An optional argument $singleInstance will prevent any futured attempts of getting a Zend_Session object in the same namespace that is provided.

  • access: public
void __construct ([string $namespace = 'Default'], [bool $singleInstance = false], [Zend_Session_Core $core = null])
  • string $namespace:
    • programmatic name of the requested namespace
  • bool $singleInstance:
    • prevent creation of additional instances for this namespace
  • Zend_Session_Core $core: - OPTIONAL instance of Zend_Session_Core, used only for testing purposes
getIterator (line 120)

getIterator() - return an iteratable object for use in foreach and the like, this completes the IteratorAggregate interface

  • return: - iteratable container of the namespace contents
  • access: public
ArrayObject getIterator ()

Implementation of:
IteratorAggregate::getIterator
isLocked (line 195)

isLocked() - return lock status, true if, and only if, read-only

  • access: public
bool isLocked ()
lock (line 162)

lock() - mark a session/namespace as readonly

  • access: public
void lock ()
setExpirationHops (line 151)

setExpirationHops() - expire the namespace, or specific variables after a specified number of page hops

  • access: public
void setExpirationHops (int $hops, [mixed $variables = null], [boolean $hopCountOnUsageOnly = false])
  • int $hops:
    • how many "hops" (number of subsequent requests) before expiring
  • mixed $variables: - OPTIONAL list of variables to expire (defaults to all)
  • boolean $hopCountOnUsageOnly: - OPTIONAL if set, only count a hop/request if this namespace is used
setExpirationSeconds (line 136)

setExpirationSeconds() - expire the namespace, or specific variables after a specified number of seconds

  • access: public
void setExpirationSeconds (int $seconds, [mixed $variables = null])
  • int $seconds:
    • expires in this many seconds
  • mixed $variables: - OPTIONAL list of variables to expire (defaults to all)
unlock (line 173)

unlock() - unmark a session/namespace to enable read & write

  • access: public
void unlock ()
unsetAll (line 206)

unsetAll() - unset all variables in this namespace

  • access: public
true unsetAll ()
__get (line 217)

__get() - method to get a variable in this objects current namespace

  • access: protected
mixed __get (string $name)
  • string $name: - programmatic name of a key, in a <key,value> pair in the current namespace
__isset (line 254)

__isset() - determine if a variable in this objects namespace is set

  • access: protected
bool __isset (string $name)
  • string $name: - programmatic name of a key, in a <key,value> pair in the current namespace
__set (line 234)

__set() - method to set a variable/value in this objects namespace

  • access: protected
true __set (string $name, mixed $value)
  • string $name: - programmatic name of a key, in a <key,value> pair in the current namespace
  • mixed $value: - value in the <key,value> pair to assign to the $name key
__unset (line 270)

__unset() - unset a variable in this objects namespace.

  • access: protected
true __unset (string $name)
  • string $name: - programmatic name of a key, in a <key,value> pair in the current namespace
Class Constants
SINGLE_INSTANCE = true (line 47)

used as option to constructor to prevent additional instances to the same namespace

Documentation generated on Thu, 18 Jan 2007 09:59:12 -0800 by phpDocumentor 1.3.1