public function findProperty($class, $name)
    {
        $reflection = new ReflectionClass($class);

        while (false === $reflection->hasProperty($name)) {
            if (false === ($reflection = $reflection->getParentClass())) {
                throw new ReflectionException(sprintf(
                    'The property "%s" does not exist in the class "%s".',
                    $name,
                    is_object($class) ? get_class($class) : $class
                ));
            }
        }

        return $reflection->getProperty($name);
    }