- var_dump: documentation ( source)
<?php
class A extends \ArrayObject {}
$a = new A;
$a->offsetSet('test', 'testValue');
$reflection = new \ReflectionObject($a);
$properties = $reflection->getProperties();
$c = count($properties);
echo $c . PHP_EOL;
if ($c) {
var_dump($properties[0]->getValue($a));
}