### Question:
DelimitedDataUtils { public static String encode(Object... columns) { return encode(columns, DELIMITER); } private  DelimitedDataUtils(); static String encode(Object... columns); static String encode(Object[] columns, char delim); static String encode(CharSequence... columns); static String encode(CharSequence[] columns, char delim); static String encode(Iterable<?> columns); static String encode(Iterable<?> columns, char delim); static String[] decode(CharSequence line); static String[] decode(CharSequence line, char delim); static final char DELIMITER; }### Answer:
@Test public void testEncode() { assertEquals("", DelimitedDataUtils.encode()); assertEquals("foo", DelimitedDataUtils.encode("foo")); assertEquals("foo,bar", DelimitedDataUtils.encode("foo", "bar")); }
@Test public void testEncodeDelimiters() { assertEquals("\"foo,bing\",bar", DelimitedDataUtils.encode("foo,bing", "bar")); }
@Test public void testEncodeQuote() { assertEquals("foo,\"bar\"\"bing\"", DelimitedDataUtils.encode("foo", "bar\"bing")); }
@Test public void testVsIterable() { assertEquals(DelimitedDataUtils.encode("foo", "bar"), DelimitedDataUtils.encode(Arrays.asList("foo", "bar"))); }
@Test public void testVsObject() { assertEquals(DelimitedDataUtils.encode("3.0", "-2.0"), DelimitedDataUtils.encode(Arrays.asList(3.0, -2.0))); }