Code example for AndroidHttpClient

Methods: execute

0
					HttpPost post = new HttpPost(url);
					StringEntity entity = new StringEntity(json);
					post.setEntity(entity);
					post.setHeader("Accept", "application/json");
					post.setHeader("Content-type", "application/json");
					return client.execute(post, new BasicResponseHandler());
				} 
			}); 
		}catch(Exception e){
			setOnLineMode(OnLineMode.OFF);
			throw new ComunicationException(e);
		} 
	} 
	 
	public void sendMessage(ExternalResourceType type, String resource, final String json){
		sendMessage(type, resource, json, null);
	} 
	 
	public void sendMessage(ExternalResourceType type, String resource, String[] attributes){
		if(mode == OnLineMode.OFF) return;
		findResource(type, resource, null);