FOF30\Inflector\Inflector::camelize PHP Метод

camelize() публичный Метод

Converts a word like "foo_bar" or "foo bar" to "FooBar". It will remove non alphanumeric characters from the word, so "who's online" will be converted to "WhoSOnline"
public camelize ( string $word ) : string
$word string Word to convert to camel case.
Результат string UpperCamelCasedWord
    public function camelize($word)
    {
        $word = preg_replace('/[^a-zA-Z0-9\\s]/', ' ', $word);
        $word = str_replace(' ', '', ucwords(strtolower(str_replace('_', ' ', $word))));
        return $word;
    }