public static String trimToEmpty(String str) {
        return str == null ? EMPTY : str.trim();
    }
@Test
  public void testTrimToEmpty() {
    Assert.assertEquals("", StringUtil.trimToEmpty(""));
    Assert.assertEquals("", StringUtil.trimToEmpty(null));
  }