ArrayUtil { public static boolean containsNotNull(Object[] array) { for (Object v : array) { if (v != null) { return true; } } return false; }  static void addNoExists(List<T> dest, List<T> src); static Object[] expand(Object... params); static boolean containsNotNull(Object[] array);  }
@Test public void testContainsNotNull() throws Exception { assertFalse(ArrayUtil.containsNotNull(new Object[]{})); assertFalse(ArrayUtil.containsNotNull(new Object[] {null, null})); assertFalse(ArrayUtil.containsNotNull(new Object[] {null})); assertTrue(ArrayUtil.containsNotNull(new String[] {"foo", null})); assertTrue(ArrayUtil.containsNotNull(new String[] {"foo", "bar"})); }