Android Open Source - LightControllerApp Http Post Wrapper

From Project

Back to project page LightControllerApp.


The source code is released under:

GNU General Public License

If you think the Android project LightControllerApp listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package info.androidhive.tabsswipe;
/*w w  w. j a  v a  m*/
import java.util.List;

import org.apache.http.NameValuePair;
import org.apache.http.client.HttpClient;
import org.apache.http.client.entity.UrlEncodedFormEntity;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.impl.client.DefaultHttpClient;

public class HttpPostWrapper {
    public HttpPostWrapper(final String Url, final List<NameValuePair> nameValuePair)
    Thread RequestThread = new Thread(new Runnable()
      public void run()
             HttpClient httpClient = new DefaultHttpClient();
              // Creating HTTP Post
              HttpPost httpPost = new HttpPost(Url);

              // Url Encoding the POST parameters
            httpPost.setEntity(new UrlEncodedFormEntity(nameValuePair));

              // Making HTTP Request
      catch (Exception e)

Java Source Code List