Move some String utilities to util.