public static function generateDeprecatedMessage($class, string $oldStuff, string $newStuff): void
    {
        if (is_object($class)) {
            $class = get_class($class);
        }

        user_error(sprintf('%1$s::%2$s is deprecated, use %1$s::%3$s instead!',
            $class, $oldStuff, $newStuff), E_USER_DEPRECATED);
    }