Skip to content

[Reference] document configurable PropertyAccessor arguments #4517

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 7, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions components/property_access/introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,8 @@ The ``getValue`` method can also use the magic ``__get`` method::

echo $accessor->getValue($person, 'Wouter'); // array(...)

.. _components-property-access-magic-call:

Magic ``__call()`` Method
~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down
23 changes: 23 additions & 0 deletions reference/configuration/framework.rst
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ Configuration
* `profiler`_
* `collect`_
* :ref:`enabled <profiler.enabled>`
* `property_accessor`_
* `magic_call`_
* `throw_exception_on_invalid_index`_

secret
~~~~~~
Expand Down Expand Up @@ -495,6 +498,26 @@ and activate the data collectors by hand::

$profiler->enable();

property_accessor
~~~~~~~~~~~~~~~~~

magic_call
..........

**type**: ``boolean`` **default**: ``false``

When enabled, the ``property_accessor`` service uses PHP's
:ref:`magic __call() method <components-property-access-magic-call>` when
its ``getValue()`` method is called.

throw_exception_on_invalid_index
................................

**type**: ``boolean`` **default**: ``false``

When enabled, the ``property_accessor`` service throws an exception when you
try to access an invalid index of an array.

Full default Configuration
--------------------------

Expand Down