class PropertyAccessorBuilder

A configurable builder to create a PropertyAccessor.

Methods

$this
enableMagicCall()

Enables the use of "__call" by the PropertyAccessor.

$this
disableMagicCall()

Disables the use of "__call" by the PropertyAccessor.

bool
isMagicCallEnabled()

No description

$this
enableExceptionOnInvalidIndex()

Enables exceptions when reading a non-existing index.

$this
disableExceptionOnInvalidIndex()

Disables exceptions when reading a non-existing index.

bool
setCacheItemPool(CacheItemPoolInterface $cacheItemPool = null)

Sets a cache system.

CacheItemPoolInterface|null
getCacheItemPool()

Gets the used cache system.

getPropertyAccessor()

Builds and returns a new PropertyAccessor object.

Details

at line line 43
$this enableMagicCall()

Enables the use of "__call" by the PropertyAccessor.

Return Value

$this

at line line 55
$this disableMagicCall()

Disables the use of "__call" by the PropertyAccessor.

Return Value

$this

at line line 65
bool isMagicCallEnabled()

Return Value

bool whether the use of "__call" by the PropertyAccessor is enabled

at line line 78
$this enableExceptionOnInvalidIndex()

Enables exceptions when reading a non-existing index.

This has no influence on writing non-existing indices with PropertyAccessorInterface::setValue() which are always created on-the-fly.

Return Value

$this

at line line 92
$this disableExceptionOnInvalidIndex()

Disables exceptions when reading a non-existing index.

Instead, null is returned when calling PropertyAccessorInterface::getValue() on a non-existing index.

Return Value

$this

at line line 102
bool isExceptionOnInvalidIndexEnabled()

Return Value

bool whether an exception is thrown or null is returned when reading a non-existing index

at line line 114
PropertyAccessorBuilder setCacheItemPool(CacheItemPoolInterface $cacheItemPool = null)

Sets a cache system.

Parameters

CacheItemPoolInterface $cacheItemPool

Return Value

PropertyAccessorBuilder The builder object

at line line 126
CacheItemPoolInterface|null getCacheItemPool()

Gets the used cache system.

Return Value

CacheItemPoolInterface|null

at line line 136
PropertyAccessorInterface getPropertyAccessor()

Builds and returns a new PropertyAccessor object.

Return Value

PropertyAccessorInterface The built PropertyAccessor