@Test public void joinWithWriterListPairNameSepsQuoteNameValuesShouldJoinParamsAccordingly() throws IOException { StringWriter actual = new StringWriter(); Pairs.join(actual, PAIRS, 's', 'e', true, true); assertEquals("\"p1\"e\"v1\"s\"p2\"e\"v2\"", actual.toString()); actual = new StringWriter(); Pairs.join(actual, PAIRS, 's', 'e', false, true); assertEquals("p1e\"v1\"sp2e\"v2\"", actual.toString()); actual = new StringWriter(); Pairs.join(actual, PAIRS, 's', 'e', true, false); assertEquals("\"p1\"ev1s\"p2\"ev2", actual.toString()); actual = new StringWriter(); Pairs.join(actual, PAIRS, 's', 'e', false, false); assertEquals("p1ev1sp2ev2", actual.toString()); }
public static String join(List<? extends EncodedPair> pairs, char pairSep){ return join(pairs, pairSep, '=', false, false); }
Pairs { public static String join(List<? extends EncodedPair> pairs, char pairSep){ return join(pairs, pairSep, '=', false, false); } }
Pairs { public static String join(List<? extends EncodedPair> pairs, char pairSep){ return join(pairs, pairSep, '=', false, false); } private  Pairs(); }
Pairs { public static String join(List<? extends EncodedPair> pairs, char pairSep){ return join(pairs, pairSep, '=', false, false); } private  Pairs(); static EncodedPair toPreEncodedPair(String name, String value); static EncodedPair toPair(String nameToEncode, String valueToEncode, Charset charset); static EncodedPair toPair(String name, String value, Charset charset, boolean encoded); static List<EncodedPair> fromUrlEncoded(String urlEncoded); static List<EncodedPair> sortByNameAndValues(List<? extends EncodedPair> pairs); static String join(List<? extends EncodedPair> pairs, char pairSep); static String join(List<? extends EncodedPair> pairs, char pairSep, char nameValSep); static String join(List<? extends EncodedPair> pairs, char pairSep, char nameValSep, boolean quoteName, boolean quoteVal); static String join(Iterator<? extends EncodedPair> pairs, char pairSep); static String join(Iterator<? extends EncodedPair> pairs, char pairSep, char nameValSep); static String join(Iterator<? extends EncodedPair> pairs, char pairSep, char nameValSep, boolean quoteName, boolean quoteVal); static void join(Writer writer, List<? extends EncodedPair> pairs, char pairSep); static void join(Writer writer, List<? extends EncodedPair> pairs, char pairSep, char nameValSep); static void join(Writer writer, List<? extends EncodedPair> pairs, char pairSep, char nameValSep, boolean quoteName, boolean quoteVal); static void join(Writer writer, Iterator<? extends EncodedPair> pairs, char pairSep); static void join(Writer writer, Iterator<? extends EncodedPair> pairs, char pairSep, char nameValSep); static void join(Writer writer, Iterator<? extends EncodedPair> pairs, char pairSep, char nameValSep, boolean quoteName, boolean quoteVal); }
Pairs { public static String join(List<? extends EncodedPair> pairs, char pairSep){ return join(pairs, pairSep, '=', false, false); } private  Pairs(); static EncodedPair toPreEncodedPair(String name, String value); static EncodedPair toPair(String nameToEncode, String valueToEncode, Charset charset); static EncodedPair toPair(String name, String value, Charset charset, boolean encoded); static List<EncodedPair> fromUrlEncoded(String urlEncoded); static List<EncodedPair> sortByNameAndValues(List<? extends EncodedPair> pairs); static String join(List<? extends EncodedPair> pairs, char pairSep); static String join(List<? extends EncodedPair> pairs, char pairSep, char nameValSep); static String join(List<? extends EncodedPair> pairs, char pairSep, char nameValSep, boolean quoteName, boolean quoteVal); static String join(Iterator<? extends EncodedPair> pairs, char pairSep); static String join(Iterator<? extends EncodedPair> pairs, char pairSep, char nameValSep); static String join(Iterator<? extends EncodedPair> pairs, char pairSep, char nameValSep, boolean quoteName, boolean quoteVal); static void join(Writer writer, List<? extends EncodedPair> pairs, char pairSep); static void join(Writer writer, List<? extends EncodedPair> pairs, char pairSep, char nameValSep); static void join(Writer writer, List<? extends EncodedPair> pairs, char pairSep, char nameValSep, boolean quoteName, boolean quoteVal); static void join(Writer writer, Iterator<? extends EncodedPair> pairs, char pairSep); static void join(Writer writer, Iterator<? extends EncodedPair> pairs, char pairSep, char nameValSep); static void join(Writer writer, Iterator<? extends EncodedPair> pairs, char pairSep, char nameValSep, boolean quoteName, boolean quoteVal);  }