From e95ea0359f737a79cbca64eaf3d614912ba007c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucas=20Ple=C3=9F?= Date: Fri, 22 Jun 2012 01:30:18 +0200 Subject: [PATCH] cleanup --- .../ctdo/crashtest/domotics/BuntiClient.java | 30 ------------------- 1 file changed, 30 deletions(-) diff --git a/src/de/ctdo/crashtest/domotics/BuntiClient.java b/src/de/ctdo/crashtest/domotics/BuntiClient.java index 5fffcda..33e2b80 100644 --- a/src/de/ctdo/crashtest/domotics/BuntiClient.java +++ b/src/de/ctdo/crashtest/domotics/BuntiClient.java @@ -11,11 +11,9 @@ import java.io.*; import java.net.DatagramPacket; import java.net.DatagramSocket; import java.net.InetAddress; -import java.net.Socket; public class BuntiClient implements IBuntiClient { private final String baseAddress; - //private final HttpClient client = new DefaultHttpClient(); public BuntiClient(String server, int port) { baseAddress = "http://" + server + ":" + port + "/"; @@ -24,8 +22,6 @@ public class BuntiClient implements IBuntiClient { @Override public void setPar56(final int red, final int green, final int blue) { - System.out.println("BuntiClient: setPar56 " + red + "," + green + "," + blue); - Runnable r = new Runnable() { @Override public void run() { @@ -75,8 +71,6 @@ public class BuntiClient implements IBuntiClient { @Override public void setPar56(final int par, final int red, final int green, final int blue) { - System.out.println("BuntiClient: setPar56 par=" + par + " " + red + "," + green + "," + blue); - Runnable r = new Runnable() { @Override public void run() { @@ -147,30 +141,6 @@ public class BuntiClient implements IBuntiClient { new Thread(r).start(); - -/* try { - HttpPost post = new HttpPost(baseAddress + "/control/devices"); - post.addHeader("Content-Type", "application/json"); - - StringEntity entity = new StringEntity( - "{ \"timeStamp\": 0, \"updates\": [ {\"deviceId\": 4, \"options\": { \"red\": "+ - red+", \"green\": "+green+", \"yellow\": "+yellow+" } } ] }" , - "UTF-8"); - - post.setEntity(entity); - - HttpResponse response = client.execute(post); - System.out.println(response); - - post.abort(); - - } catch (UnsupportedEncodingException e) { - e.printStackTrace(); - } catch (ClientProtocolException e) { - e.printStackTrace(); - } catch (IOException e) { - e.printStackTrace(); - }*/ } }