private function generateReplacement($originalClassName)
    {
        $parts = explode('_', $originalClassName);

        $tokensArray = [];
        while (!empty($parts)) {
            $tokensArray[] = new Token([T_STRING, array_shift($parts)]);
            if (!empty($parts)) {
                $tokensArray[] = new Token([T_NS_SEPARATOR, '\\']);
            }
        }

        return Tokens::fromArray($tokensArray);
    }
private function generateReplacement($originalClassName)
    {
        $parts = explode('_', $originalClassName);

        $tokensArray = [];
        while (!empty($parts)) {
            $tokensArray[] = new Token([T_STRING, array_shift($parts)]);
            if (!empty($parts)) {
                $tokensArray[] = new Token([T_NS_SEPARATOR, '\\']);
            }
        }

        return Tokens::fromArray($tokensArray);
    }
private function generateReplacement ( $ originalClassName ) { $ parts = explode ( '_' , $ originalClassName ) ; $ tokensArray = [ ] ; while ( ! empty ( $ parts ) ) { $ tokensArray [ ] = new Token ( [ T_STRING , array_shift ( $ parts ) ] ) ; if ( ! empty ( $ parts ) ) { $ tokensArray [ ] = new Token ( [ T_NS_SEPARATOR , '\\' ] ) ; } } return Tokens :: fromArray ( $ tokensArray ) ; }
@param string $originalClassName

@return Tokens
@param string $originalClassName