<?php class Test implements Countable { private $prop1, $prop2,$prop3,$prop4; public function allProps(){ return get_object_vars($this); } } $t = new Test; echo count($t->allProps());
You have javascript disabled. You will not be able to edit any code.