PHP multi array access
1 follower

PHP multi array access


Add a dependency to your project's composer.json file if you use Composer to manage the dependencies of your project:

    "require": {
        "petrgrishin/array-access": "~1.0"

Usage examples

Basic usage array-access objects

use \PetrGrishin\ArrayAccess\ArrayAccess;
$arrayParams = array(
    'a' => array(
        'b' => 10,
$params = ArrayAccess::create($arrayParams);
$value = $params->getValue('a.b');
    ->setValue('a.b', 20)
    ->setValue('a.c', 30);
$resultArrayParams = $params->getArray();

Be the first person to leave a comment

Please to leave your comment.

Create extension