public static function generateName($class)
    {
        $name = ClassUtils::classToName($class, '.', '_');

        // Remove suffix
        if (substr($name, -1 * strlen(self::IGNORED_SUFFIX)) === self::IGNORED_SUFFIX) {
            $name = substr($name, 0, -1 * strlen(self::IGNORED_SUFFIX));
            $name = rtrim($name, '._');
        }

        return $name;
    }