Code example for HttpPost

Methods: setEntity

	/* helper to enclose all the http-related code */ 
	private HttpResponse postEntity(MultipartEntity entity) {
		HttpClient httpclient = new DefaultHttpClient();
		HttpPost httppost = new HttpPost("");
		try { 
			HttpResponse response = httpclient.execute(httppost);
			return response;
		} catch (ClientProtocolException e) {
			Log.e(TAG, "client proto exception!", e);
		} catch (IOException e) {
			Log.e(TAG, "io exception", e);
		return null; 
	public boolean postText(String title, String body, Bundle options) {
		MultipartEntity entity = getEntityWithOptions(options);
Connect your IDE to all the code out there  Get Codota for Java