2010-11-18 69 views

回答

0

你可以把它静态的,所有的请求使用它

client = new OkHttpClient(); // client will be static and use in all requests 

CookieManager cookieManager = new CookieManager(); 
cookieManager.setCookiePolicy(CookiePolicy.ACCEPT_ALL); 
client.setCookieHandler(cookieManager);