Code examples for StringEntity

Codota analyzed 7,668,838 open source code samples to find the most common, credible and clear examples.
You can now enable Codota on your own code to easily search and navigate your Java codebase.
80:	entity = new StringEntity(httpResponseBody); 
-
84:	httpResponse.setEntity(entity); 
Full Snippet Info
7
CodeRank
79:	entity = new StringEntity(postBody); 
-
86:	Header header = entity.getContentType(); 
Full Snippet Info
6
CodeRank
318:	put.setEntity(new StringEntity(data)); 
Full Snippet Info
6
CodeRank
547:	entity = new StringEntity(body, CHARSET); 
-
552:	entity.setContentType(contentType); 
553:	request.setEntity(entity); 
Full Snippet Info
6
CodeRank
55:	response.setEntity(new StringEntity(uri)); 
Full Snippet Info
6
CodeRank
43:	AbstractHttpEntity entity = new StringEntity("401 Unauthorized"); 
44:	entity.setContentType("text/plain"); 
45:	response.setEntity(entity); 
Full Snippet Info
6
CodeRank
92:	return new StringEntity(content,UTF_8_ENCODING); 
-
108:	se.setContentType(new BasicHeader(HTTP.CONTENT_TYPE, MIME_TYPE_JSON)); 
Full Snippet Info
6
CodeRank
57:	StringEntity postEntity = new StringEntity("{\"action\":\"" + action + "\",\"method\":\"" + method 
Full Snippet Info
6
CodeRank
207:	StringEntity outgoing = new StringEntity("No content"); 
208:	response.setEntity(outgoing); 
Full Snippet Info
5
CodeRank
34:	stringdata = new StringEntity(l.getJSON()); 
-
40:	SimpleHttp.put(putURL, data); 
Full Snippet Info
5
CodeRank
121:	StringEntity se = new StringEntity(contents); 
122:	se.setContentType(new BasicHeader(HTTP.CONTENT_TYPE, "application/json")); 
-
124:	client.put(null, url, se, "application/json", handler); 
Full Snippet Info
5
CodeRank
218:	entity = new StringEntity(data, DEFAULT_ENCODING); 
Full Snippet Info
5
CodeRank
86:	when(request.getEntity()).thenReturn(new StringEntity("stuff")); 
Full Snippet Info
5
CodeRank
26:	postEntity = new StringEntity(content); 
27:	((HttpPost) method).setEntity(postEntity); 
Full Snippet Info
5
CodeRank
66:	r.setEntity(new StringEntity(request.getPayload().toString(), "UTF-8")); 
Full Snippet Info
5
CodeRank
86:	when(response.getEntity()).thenReturn(new StringEntity("stuff")); 
Full Snippet Info
5
CodeRank
260:	return params.getRawBody() == null ? null : new StringEntity(params.getRawBody(), HTTP.UTF_8); 
Full Snippet Info
5
CodeRank
46:	StringEntity se = new StringEntity(outboundJStr); 
47:	se.setContentEncoding( 
-
50:	se.writeTo(out); 
Full Snippet Info
5
CodeRank
69:	StringEntity paramEntity = new StringEntity(postArg); 
70:	paramEntity.setChunked(false); 
71:	paramEntity.setContentType("application/x-www-form-urlencoded"); 
Full Snippet Info
5
CodeRank
55:	response.setEntity(new StringEntity(uri)); 
Full Snippet Info
5
CodeRank