8.11.2019 MQTT finished
This commit is contained in:
parent
a4563def38
commit
797d29281b
0
JavaSample-tcp19216865151883/.lck
Normal file
0
JavaSample-tcp19216865151883/.lck
Normal file
@ -8,13 +8,10 @@ import java.awt.event.ActionListener;
|
|||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.sql.SQLException;
|
import java.sql.SQLException;
|
||||||
import java.text.DateFormat;
|
import java.text.DateFormat;
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.GregorianCalendar;
|
import java.util.GregorianCalendar;
|
||||||
|
|
||||||
public class mqtt {
|
public class mqtt {
|
||||||
|
|
||||||
ArrayList<String> mylist = new ArrayList<>();
|
|
||||||
int index = 0;
|
|
||||||
|
|
||||||
public mqtt() {
|
public mqtt() {
|
||||||
|
|
||||||
@ -74,7 +71,6 @@ public class mqtt {
|
|||||||
|
|
||||||
if (temp != null) {
|
if (temp != null) {
|
||||||
transmitmessageAbfallart(temp);
|
transmitmessageAbfallart(temp);
|
||||||
notifymessage();
|
|
||||||
} else {
|
} else {
|
||||||
Log.debug("NO Connection");
|
Log.debug("NO Connection");
|
||||||
}
|
}
|
||||||
@ -84,7 +80,6 @@ public class mqtt {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -10,8 +10,6 @@ import org.eclipse.paho.client.mqttv3.persist.MemoryPersistence;
|
|||||||
|
|
||||||
public class mqtttransmitter {
|
public class mqtttransmitter {
|
||||||
|
|
||||||
private String messagedatabase;
|
|
||||||
|
|
||||||
public mqtttransmitter() {
|
public mqtttransmitter() {
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -23,8 +21,6 @@ public class mqtttransmitter {
|
|||||||
String clientId = "JavaSample";
|
String clientId = "JavaSample";
|
||||||
MemoryPersistence persistence = new MemoryPersistence();
|
MemoryPersistence persistence = new MemoryPersistence();
|
||||||
|
|
||||||
System.out.println("HI");
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
MqttClient sampleClient = new MqttClient(broker, clientId, persistence);
|
MqttClient sampleClient = new MqttClient(broker, clientId, persistence);
|
||||||
MqttConnectOptions connOpts = new MqttConnectOptions();
|
MqttConnectOptions connOpts = new MqttConnectOptions();
|
||||||
@ -50,5 +46,4 @@ public class mqtttransmitter {
|
|||||||
me.printStackTrace();
|
me.printStackTrace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user