[java] Remove last character of a StringBuilder?