src/Parameters.php
private function castObjectsAsArrays(array $parameters)
    {
        foreach ($parameters as $key => $value) {
            if (is_object($value)) {
                $value = (array) $value;
                $parameters[$key] = $value;
            }
            if (is_array($value)) {
                $parameters[$key] = $this->castObjectsAsArrays($value);
            }
        }
        return $parameters;
    }
private function castObjectsAsArrays(array $parameters)
    {
        foreach ($parameters as $key => $value) {
            if (is_object($value)) {
                $value = (array) $value;
                $parameters[$key] = $value;
            }
            if (is_array($value)) {
                $parameters[$key] = $this->castObjectsAsArrays($value);
            }
        }
        return $parameters;
    }
private function castObjectsAsArrays ( array $ parameters ) { foreach ( $ parameters as $ key => $ value ) { if ( is_object ( $ value ) ) { $ value = ( array ) $ value ; $ parameters [ $ key ] = $ value ; } if ( is_array ( $ value ) ) { $ parameters [ $ key ] = $ this -> castObjectsAsArrays ( $ value ) ; } } return $ parameters ; }
Ensures any object values are cast as arrays. Is recursive.

@param   array   $parameters
@return  array
Ensures any object values are cast as arrays . Is recursive .