StringUtils { public static boolean containsAnEmpty(String[] strings) { for (String str : strings) { if (StringUtils.isEmpty(str)) { return true; } } return false; }  static boolean isEmpty(String str); static boolean containsAnEmpty(String[] strings);  }
@Test public void testContainsAnEmpty() { assertTrue(StringUtils.containsAnEmpty(new String[] {"abc", "", "def"})); assertTrue(StringUtils.containsAnEmpty(new String[] {""})); assertTrue(StringUtils.containsAnEmpty(new String[] {"abc", "def", " "})); assertTrue(StringUtils.containsAnEmpty(new String[] {"abc", "def", null})); }