List of usage examples for org.apache.commons.text WordUtils capitalizeFully
public static String capitalizeFully(String str, final char... delimiters)
Converts all the delimiter separated words in a String into capitalized words, that is each word is made up of a titlecase character and then a series of lowercase characters.
From source file:com.redpilllinpro.mattermost.Slascommand.java
protected String createValidCamelCaseRoomName(String room) { return WordUtils.capitalizeFully(room, new char[] { '-', '_', ' ', ':' }).replaceAll("-", "") .replaceAll("_", "").replaceAll(" ", "").replaceAll(":", ""); }