Here you can find the source of addParameter(final String key, final String value, final StringBuilder url, final AtomicReference
public static void addParameter(final String key, final String value, final StringBuilder url, final AtomicReference<String> thisSeparator, final String nextSeparator)
//package com.java2s; //License from project: Apache License import java.util.concurrent.atomic.AtomicReference; public class Main { public static void addParameter(final String key, final String value, final StringBuilder url, final AtomicReference<String> thisSeparator, final String nextSeparator) { if (value != null) { url.append(thisSeparator.get()); url.append(key);// w ww.jav a2 s. co m url.append("="); url.append(value); thisSeparator.set(nextSeparator); } } }