Changing replaceWhitespaceWith char to Character to support nulling it to replace with nothing.