Zend Framework  3.0
Public Member Functions | List of all members
AccessController Class Reference

Memory object container access controller. More...

Public Member Functions

 __construct (Movable $memContainer)
 Object constructor.
 
 __destruct ()
 Object destructor.
 
getRef ()
 Get string value reference.
 
 touch ()
 Signal, that value is updated by external code.
 
 lock ()
 Lock object in memory.
 
 unlock ()
 Unlock object.
 
 isLocked ()
 Return true if object is locked.
 
 __get ($property)
 Get handler.
 
 __set ($property, $value)
 Set handler.
 

Detailed Description

Memory object container access controller.

Memory manager stores a list of generated objects to control them. So container objects always have at least one reference and can't be automatically destroyed.

This class is intended to be an userland proxy to memory container object. It's not referenced by memory manager and class destructor is invoked immediately after going out of scope or unset operation.

Class also provides Zend interface and works as proxy for such cases.

Constructor & Destructor Documentation

__construct ( Movable  $memContainer)

Object constructor.

Parameters
Movable$memContainer
__destruct ( )

Object destructor.

Member Function Documentation

__get (   $property)

Get handler.

Loads object if necessary and moves it to the top of loaded objects list. Swaps objects from the bottom of loaded objects list, if necessary.

Parameters
string$property
Returns
string
__set (   $property,
  $value 
)

Set handler.

Parameters
string$property
string$value
& getRef ( )

Get string value reference.

_Must_ be used for value access before PHP v 5.2 or _may_ be used for performance considerations

Returns
&string

Implements ContainerInterface.

isLocked ( )

Return true if object is locked.

Returns
bool

Implements ContainerInterface.

lock ( )

Lock object in memory.

Implements ContainerInterface.

touch ( )

Signal, that value is updated by external code.

Should be used together with getRef()

Implements ContainerInterface.

unlock ( )

Unlock object.

Implements ContainerInterface.