Code example for BrowserCompatSpec

Methods: formatCookies

0
	/** 
	 * @param request 
	 */ 
	public static void addCookies(MobileRequest request) {
		if ((cookies != null) && (!cookies.isEmpty())) {
			CookieSpecBase cookieSpecBase = new BrowserCompatSpec();
			List<Cookie> cookies = new ArrayList<Cookie>();
			cookies.addAll(getCookies());
			List<Header> cookieHeader = cookieSpecBase.formatCookies(cookies);
			request.getPostRequest().setHeader((Header) cookieHeader.get(0));
		} 
	} 
 
	public static void clearCookies() { 
		if (cookies != null)
			cookies.clear();
	} 
 
	/** 
	 * @param cookiesString 
Connect your IDE to all the code out there  Get Codota for Java