| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (1.8.0_101) on Thu Sep 01 13:59:14 BST 2016 --> |
| <title>MqttAsyncClient</title> |
| <meta name="date" content="2016-09-01"> |
| <link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style"> |
| <script type="text/javascript" src="../../../../../script.js"></script> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| try { |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="MqttAsyncClient"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":9,"i15":10,"i16":10,"i17":10,"i18":10,"i19":10,"i20":10,"i21":10,"i22":10,"i23":10,"i24":10,"i25":10,"i26":10,"i27":10,"i28":10,"i29":10,"i30":10,"i31":10,"i32":10,"i33":10,"i34":10,"i35":10,"i36":10,"i37":10,"i38":10,"i39":10,"i40":10,"i41":10,"i42":10,"i43":10}; |
| var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]}; |
| var altColor = "altColor"; |
| var rowColor = "rowColor"; |
| var tableTab = "tableTab"; |
| var activeTableTab = "activeTableTab"; |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a name="navbar.top"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.top.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/MqttAsyncClient.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../../index-files/index-1.html">Index</a></li> |
| <li><a href="../../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../../index.html?org/eclipse/paho/client/mqttv3/MqttAsyncClient.html" target="_top">Frames</a></li> |
| <li><a href="MqttAsyncClient.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_top"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.top"> |
| <!-- --> |
| </a></div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <div class="subTitle">org.eclipse.paho.client.mqttv3</div> |
| <h2 title="Class MqttAsyncClient" class="title">Class MqttAsyncClient</h2> |
| </div> |
| <div class="contentContainer"> |
| <ul class="inheritance"> |
| <li>java.lang.Object</li> |
| <li> |
| <ul class="inheritance"> |
| <li>org.eclipse.paho.client.mqttv3.MqttAsyncClient</li> |
| </ul> |
| </li> |
| </ul> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt>All Implemented Interfaces:</dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></dd> |
| </dl> |
| <hr> |
| <br> |
| <pre>public class <span class="typeNameLabel">MqttAsyncClient</span> |
| extends java.lang.Object |
| implements <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></pre> |
| <div class="block">Lightweight client for talking to an MQTT server using non-blocking methods |
| that allow an operation to run in the background. |
| |
| <p>This class implements the non-blocking <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3"><code>IMqttAsyncClient</code></a> client interface |
| allowing applications to initiate MQTT actions and then carry on working while the |
| MQTT action completes on a background thread. |
| This implementation is compatible with all Java SE runtimes from 1.4.2 and up. |
| </p> |
| <p>An application can connect to an MQTT server using: |
| <ul> |
| <li>A plain TCP socket |
| <li>A secure SSL/TLS socket |
| </ul> |
| </p> |
| <p>To enable messages to be delivered even across network and client restarts |
| messages need to be safely stored until the message has been delivered at the requested |
| quality of service. A pluggable persistence mechanism is provided to store the messages. |
| </p> |
| <p>By default <a href="../../../../../org/eclipse/paho/client/mqttv3/persist/MqttDefaultFilePersistence.html" title="class in org.eclipse.paho.client.mqttv3.persist"><code>MqttDefaultFilePersistence</code></a> is used to store messages to a file. |
| If persistence is set to null then messages are stored in memory and hence can be lost |
| if the client, Java runtime or device shuts down. |
| </p> |
| <p>If connecting with <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setCleanSession-boolean-"><code>MqttConnectOptions.setCleanSession(boolean)</code></a> set to true it |
| is safe to use memory persistence as all state is cleared when a client disconnects. If |
| connecting with cleanSession set to false in order to provide reliable message delivery |
| then a persistent message store such as the default one should be used. |
| </p> |
| <p>The message store interface is pluggable. Different stores can be used by implementing |
| the <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttClientPersistence.html" title="interface in org.eclipse.paho.client.mqttv3"><code>MqttClientPersistence</code></a> interface and passing it to the clients constructor. |
| </p></div> |
| <dl> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3"><code>IMqttAsyncClient</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor.summary"> |
| <!-- --> |
| </a> |
| <h3>Constructor Summary</h3> |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation"> |
| <caption><span>Constructors</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colOne" scope="col">Constructor and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colOne"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#MqttAsyncClient-java.lang.String-java.lang.String-">MqttAsyncClient</a></span>(java.lang.String serverURI, |
| java.lang.String clientId)</code> |
| <div class="block">Create an MqttAsyncClient that is used to communicate with an MQTT server.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colOne"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#MqttAsyncClient-java.lang.String-java.lang.String-org.eclipse.paho.client.mqttv3.MqttClientPersistence-">MqttAsyncClient</a></span>(java.lang.String serverURI, |
| java.lang.String clientId, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttClientPersistence.html" title="interface in org.eclipse.paho.client.mqttv3">MqttClientPersistence</a> persistence)</code> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colOne"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#MqttAsyncClient-java.lang.String-java.lang.String-org.eclipse.paho.client.mqttv3.MqttClientPersistence-org.eclipse.paho.client.mqttv3.MqttPingSender-">MqttAsyncClient</a></span>(java.lang.String serverURI, |
| java.lang.String clientId, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttClientPersistence.html" title="interface in org.eclipse.paho.client.mqttv3">MqttClientPersistence</a> persistence, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPingSender.html" title="interface in org.eclipse.paho.client.mqttv3">MqttPingSender</a> pingSender)</code> |
| <div class="block">Create an MqttAsyncClient that is used to communicate with an MQTT server.</div> |
| </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> |
| <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Method and Description</th> |
| </tr> |
| <tr id="i0" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#checkPing-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">checkPing</a></span>(java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> </td> |
| </tr> |
| <tr id="i1" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#close--">close</a></span>()</code> |
| <div class="block">Close the client |
| Releases all resource associated with the client.</div> |
| </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#connect--">connect</a></span>()</code> |
| <div class="block">Connects to an MQTT server using the default options.</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-">connect</a></span>(<a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html" title="class in org.eclipse.paho.client.mqttv3">MqttConnectOptions</a> options)</code> |
| <div class="block">Connects to an MQTT server using the provided connect options.</div> |
| </td> |
| </tr> |
| <tr id="i4" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">connect</a></span>(<a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html" title="class in org.eclipse.paho.client.mqttv3">MqttConnectOptions</a> options, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Connects to an MQTT server using the specified options.</div> |
| </td> |
| </tr> |
| <tr id="i5" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#connect-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">connect</a></span>(java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Connects to an MQTT server using the default options.</div> |
| </td> |
| </tr> |
| <tr id="i6" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#deleteBufferedMessage-int-">deleteBufferedMessage</a></span>(int bufferIndex)</code> </td> |
| </tr> |
| <tr id="i7" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#disconnect--">disconnect</a></span>()</code> |
| <div class="block">Disconnects from the server.</div> |
| </td> |
| </tr> |
| <tr id="i8" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#disconnect-long-">disconnect</a></span>(long quiesceTimeout)</code> |
| <div class="block">Disconnects from the server.</div> |
| </td> |
| </tr> |
| <tr id="i9" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#disconnect-long-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">disconnect</a></span>(long quiesceTimeout, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Disconnects from the server.</div> |
| </td> |
| </tr> |
| <tr id="i10" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#disconnect-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">disconnect</a></span>(java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Disconnects from the server.</div> |
| </td> |
| </tr> |
| <tr id="i11" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#disconnectForcibly--">disconnectForcibly</a></span>()</code> |
| <div class="block">Disconnects from the server forcibly to reset all the states.</div> |
| </td> |
| </tr> |
| <tr id="i12" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#disconnectForcibly-long-">disconnectForcibly</a></span>(long disconnectTimeout)</code> |
| <div class="block">Disconnects from the server forcibly to reset all the states.</div> |
| </td> |
| </tr> |
| <tr id="i13" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#disconnectForcibly-long-long-">disconnectForcibly</a></span>(long quiesceTimeout, |
| long disconnectTimeout)</code> |
| <div class="block">Disconnects from the server forcibly to reset all the states.</div> |
| </td> |
| </tr> |
| <tr id="i14" class="altColor"> |
| <td class="colFirst"><code>static java.lang.String</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#generateClientId--">generateClientId</a></span>()</code> |
| <div class="block">Returns a randomly generated client identifier based on the the fixed prefix (paho) |
| and the system time.</div> |
| </td> |
| </tr> |
| <tr id="i15" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3">MqttMessage</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#getBufferedMessage-int-">getBufferedMessage</a></span>(int bufferIndex)</code> </td> |
| </tr> |
| <tr id="i16" class="altColor"> |
| <td class="colFirst"><code>int</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#getBufferedMessageCount--">getBufferedMessageCount</a></span>()</code> </td> |
| </tr> |
| <tr id="i17" class="rowColor"> |
| <td class="colFirst"><code>java.lang.String</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#getClientId--">getClientId</a></span>()</code> |
| <div class="block">Returns the client ID used by this client.</div> |
| </td> |
| </tr> |
| <tr id="i18" class="altColor"> |
| <td class="colFirst"><code>java.lang.String</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#getCurrentServerURI--">getCurrentServerURI</a></span>()</code> |
| <div class="block">Returns the currently connected Server URI |
| Implemented due to: https://bugs.eclipse.org/bugs/show_bug.cgi?id=481097 |
| |
| Where getServerURI only returns the URI that was provided in |
| MqttAsyncClient's constructor, getCurrentServerURI returns the URI of the |
| Server that the client is currently connected to.</div> |
| </td> |
| </tr> |
| <tr id="i19" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/util/Debug.html" title="class in org.eclipse.paho.client.mqttv3.util">Debug</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#getDebug--">getDebug</a></span>()</code> |
| <div class="block">Return a debug object that can be used to help solve problems.</div> |
| </td> |
| </tr> |
| <tr id="i20" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a>[]</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#getPendingDeliveryTokens--">getPendingDeliveryTokens</a></span>()</code> |
| <div class="block">Returns the delivery tokens for any outstanding publish operations.</div> |
| </td> |
| </tr> |
| <tr id="i21" class="rowColor"> |
| <td class="colFirst"><code>java.lang.String</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#getServerURI--">getServerURI</a></span>()</code> |
| <div class="block">Returns the address of the server used by this client.</div> |
| </td> |
| </tr> |
| <tr id="i22" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#isConnected--">isConnected</a></span>()</code> |
| <div class="block">Determines if this client is currently connected to the server.</div> |
| </td> |
| </tr> |
| <tr id="i23" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#messageArrivedComplete-int-int-">messageArrivedComplete</a></span>(int messageId, |
| int qos)</code> |
| <div class="block">Indicate that the application has completed processing the message with id messageId.</div> |
| </td> |
| </tr> |
| <tr id="i24" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#publish-java.lang.String-byte:A-int-boolean-">publish</a></span>(java.lang.String topic, |
| byte[] payload, |
| int qos, |
| boolean retained)</code> |
| <div class="block">Publishes a message to a topic on the server.</div> |
| </td> |
| </tr> |
| <tr id="i25" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#publish-java.lang.String-byte:A-int-boolean-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">publish</a></span>(java.lang.String topic, |
| byte[] payload, |
| int qos, |
| boolean retained, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Publishes a message to a topic on the server.</div> |
| </td> |
| </tr> |
| <tr id="i26" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-">publish</a></span>(java.lang.String topic, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3">MqttMessage</a> message)</code> |
| <div class="block">Publishes a message to a topic on the server.</div> |
| </td> |
| </tr> |
| <tr id="i27" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">publish</a></span>(java.lang.String topic, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3">MqttMessage</a> message, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Publishes a message to a topic on the server.</div> |
| </td> |
| </tr> |
| <tr id="i28" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#reconnect--">reconnect</a></span>()</code> |
| <div class="block">User triggered attempt to reconnect</div> |
| </td> |
| </tr> |
| <tr id="i29" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#setBufferOpts-org.eclipse.paho.client.mqttv3.DisconnectedBufferOptions-">setBufferOpts</a></span>(<a href="../../../../../org/eclipse/paho/client/mqttv3/DisconnectedBufferOptions.html" title="class in org.eclipse.paho.client.mqttv3">DisconnectedBufferOptions</a> bufferOpts)</code> |
| <div class="block">Sets the DisconnectedBufferOptions for this client</div> |
| </td> |
| </tr> |
| <tr id="i30" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#setCallback-org.eclipse.paho.client.mqttv3.MqttCallback-">setCallback</a></span>(<a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3">MqttCallback</a> callback)</code> |
| <div class="block">Sets a callback listener to use for events that happen asynchronously.</div> |
| </td> |
| </tr> |
| <tr id="i31" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#setManualAcks-boolean-">setManualAcks</a></span>(boolean manualAcks)</code> |
| <div class="block">If manualAcks is set to true, then on completion of the messageArrived callback |
| the MQTT acknowledgements are not sent.</div> |
| </td> |
| </tr> |
| <tr id="i32" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#subscribe-java.lang.String:A-int:A-">subscribe</a></span>(java.lang.String[] topicFilters, |
| int[] qos)</code> |
| <div class="block">Subscribe to multiple topics, each of which may include wildcards.</div> |
| </td> |
| </tr> |
| <tr id="i33" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#subscribe-java.lang.String:A-int:A-org.eclipse.paho.client.mqttv3.IMqttMessageListener:A-">subscribe</a></span>(java.lang.String[] topicFilters, |
| int[] qos, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttMessageListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttMessageListener</a>[] messageListeners)</code> |
| <div class="block">Subscribe to multiple topics, each of which may include wildcards.</div> |
| </td> |
| </tr> |
| <tr id="i34" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">subscribe</a></span>(java.lang.String[] topicFilters, |
| int[] qos, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Subscribes to multiple topics, each of which may include wildcards.</div> |
| </td> |
| </tr> |
| <tr id="i35" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-org.eclipse.paho.client.mqttv3.IMqttMessageListener:A-">subscribe</a></span>(java.lang.String[] topicFilters, |
| int[] qos, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttMessageListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttMessageListener</a>[] messageListeners)</code> |
| <div class="block">Subscribe to multiple topics, each of which may include wildcards.</div> |
| </td> |
| </tr> |
| <tr id="i36" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#subscribe-java.lang.String-int-">subscribe</a></span>(java.lang.String topicFilter, |
| int qos)</code> |
| <div class="block">Subscribe to a topic, which may include wildcards.</div> |
| </td> |
| </tr> |
| <tr id="i37" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#subscribe-java.lang.String-int-org.eclipse.paho.client.mqttv3.IMqttMessageListener-">subscribe</a></span>(java.lang.String topicFilter, |
| int qos, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttMessageListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttMessageListener</a> messageListener)</code> |
| <div class="block">Subscribe to a topic, which may include wildcards.</div> |
| </td> |
| </tr> |
| <tr id="i38" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#subscribe-java.lang.String-int-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">subscribe</a></span>(java.lang.String topicFilter, |
| int qos, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Subscribe to a topic, which may include wildcards.</div> |
| </td> |
| </tr> |
| <tr id="i39" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#subscribe-java.lang.String-int-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-org.eclipse.paho.client.mqttv3.IMqttMessageListener-">subscribe</a></span>(java.lang.String topicFilter, |
| int qos, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttMessageListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttMessageListener</a> messageListener)</code> |
| <div class="block">Subscribe to a topic, which may include wildcards.</div> |
| </td> |
| </tr> |
| <tr id="i40" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#unsubscribe-java.lang.String-">unsubscribe</a></span>(java.lang.String topicFilter)</code> |
| <div class="block">Requests the server unsubscribe the client from a topic.</div> |
| </td> |
| </tr> |
| <tr id="i41" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#unsubscribe-java.lang.String:A-">unsubscribe</a></span>(java.lang.String[] topicFilters)</code> |
| <div class="block">Requests the server unsubscribe the client from one or more topics.</div> |
| </td> |
| </tr> |
| <tr id="i42" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#unsubscribe-java.lang.String:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">unsubscribe</a></span>(java.lang.String[] topicFilters, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Requests the server unsubscribe the client from one or more topics.</div> |
| </td> |
| </tr> |
| <tr id="i43" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#unsubscribe-java.lang.String-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">unsubscribe</a></span>(java.lang.String topicFilter, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback)</code> |
| <div class="block">Requests the server unsubscribe the client from a topics.</div> |
| </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.java.lang.Object"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class java.lang.Object</h3> |
| <code>equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor.detail"> |
| <!-- --> |
| </a> |
| <h3>Constructor Detail</h3> |
| <a name="MqttAsyncClient-java.lang.String-java.lang.String-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>MqttAsyncClient</h4> |
| <pre>public MqttAsyncClient(java.lang.String serverURI, |
| java.lang.String clientId) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block">Create an MqttAsyncClient that is used to communicate with an MQTT server. |
| <p> |
| The address of a server can be specified on the constructor. Alternatively |
| a list containing one or more servers can be specified using the |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setServerURIs-java.lang.String:A-"><code>setServerURIs</code></a> method |
| on MqttConnectOptions. |
| |
| <p>The <code>serverURI</code> parameter is typically used with the |
| the <code>clientId</code> parameter to form a key. The key |
| is used to store and reference messages while they are being delivered. |
| Hence the serverURI specified on the constructor must still be specified even if a list |
| of servers is specified on an MqttConnectOptions object. |
| The serverURI on the constructor must remain the same across |
| restarts of the client for delivery of messages to be maintained from a given |
| client to a given server or set of servers. |
| |
| <p>The address of the server to connect to is specified as a URI. Two types of |
| connection are supported <code>tcp://</code> for a TCP connection and |
| <code>ssl://</code> for a TCP connection secured by SSL/TLS. |
| For example: |
| <ul> |
| <li><code>tcp://localhost:1883</code></li> |
| <li><code>ssl://localhost:8883</code></li> |
| </ul> |
| If the port is not specified, it will |
| default to 1883 for <code>tcp://</code>" URIs, and 8883 for <code>ssl://</code> URIs. |
| </p> |
| |
| <p> |
| A client identifier <code>clientId</code> must be specified and be less that 65535 characters. |
| It must be unique across all clients connecting to the same |
| server. The clientId is used by the server to store data related to the client, |
| hence it is important that the clientId remain the same when connecting to a server |
| if durable subscriptions or reliable messaging are required. |
| <p>A convenience method is provided to generate a random client id that |
| should satisfy this criteria - <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#generateClientId--"><code>generateClientId()</code></a>. As the client identifier |
| is used by the server to identify a client when it reconnects, the client must use the |
| same identifier between connections if durable subscriptions or reliable |
| delivery of messages is required. |
| </p> |
| <p> |
| In Java SE, SSL can be configured in one of several ways, which the |
| client will use in the following order: |
| </p> |
| <ul> |
| <li><strong>Supplying an <code>SSLSocketFactory</code></strong> - applications can |
| use <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setSocketFactory-javax.net.SocketFactory-"><code>MqttConnectOptions.setSocketFactory(SocketFactory)</code></a> to supply |
| a factory with the appropriate SSL settings.</li> |
| <li><strong>SSL Properties</strong> - applications can supply SSL settings as a |
| simple Java Properties using <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setSSLProperties-java.util.Properties-"><code>MqttConnectOptions.setSSLProperties(Properties)</code></a>.</li> |
| <li><strong>Use JVM settings</strong> - There are a number of standard |
| Java system properties that can be used to configure key and trust stores.</li> |
| </ul> |
| |
| <p>In Java ME, the platform settings are used for SSL connections.</p> |
| |
| <p>An instance of the default persistence mechanism <a href="../../../../../org/eclipse/paho/client/mqttv3/persist/MqttDefaultFilePersistence.html" title="class in org.eclipse.paho.client.mqttv3.persist"><code>MqttDefaultFilePersistence</code></a> |
| is used by the client. To specify a different persistence mechanism or to turn |
| off persistence, use the <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#MqttAsyncClient-java.lang.String-java.lang.String-org.eclipse.paho.client.mqttv3.MqttClientPersistence-"><code>MqttAsyncClient(String, String, MqttClientPersistence)</code></a> |
| constructor.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>serverURI</code> - the address of the server to connect to, specified as a URI. Can be overridden using |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setServerURIs-java.lang.String:A-"><code>MqttConnectOptions.setServerURIs(String[])</code></a></dd> |
| <dd><code>clientId</code> - a client identifier that is unique on the server being connected to</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code>java.lang.IllegalArgumentException</code> - if the URI does not start with |
| "tcp://", "ssl://" or "local://".</dd> |
| <dd><code>java.lang.IllegalArgumentException</code> - if the clientId is null or is greater than 65535 characters in length</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if any other problem was encountered</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="MqttAsyncClient-java.lang.String-java.lang.String-org.eclipse.paho.client.mqttv3.MqttClientPersistence-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>MqttAsyncClient</h4> |
| <pre>public MqttAsyncClient(java.lang.String serverURI, |
| java.lang.String clientId, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttClientPersistence.html" title="interface in org.eclipse.paho.client.mqttv3">MqttClientPersistence</a> persistence) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <dl> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="MqttAsyncClient-java.lang.String-java.lang.String-org.eclipse.paho.client.mqttv3.MqttClientPersistence-org.eclipse.paho.client.mqttv3.MqttPingSender-"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>MqttAsyncClient</h4> |
| <pre>public MqttAsyncClient(java.lang.String serverURI, |
| java.lang.String clientId, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttClientPersistence.html" title="interface in org.eclipse.paho.client.mqttv3">MqttClientPersistence</a> persistence, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPingSender.html" title="interface in org.eclipse.paho.client.mqttv3">MqttPingSender</a> pingSender) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block">Create an MqttAsyncClient that is used to communicate with an MQTT server. |
| <p> |
| The address of a server can be specified on the constructor. Alternatively |
| a list containing one or more servers can be specified using the |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setServerURIs-java.lang.String:A-"><code>setServerURIs</code></a> method |
| on MqttConnectOptions. |
| |
| <p>The <code>serverURI</code> parameter is typically used with the |
| the <code>clientId</code> parameter to form a key. The key |
| is used to store and reference messages while they are being delivered. |
| Hence the serverURI specified on the constructor must still be specified even if a list |
| of servers is specified on an MqttConnectOptions object. |
| The serverURI on the constructor must remain the same across |
| restarts of the client for delivery of messages to be maintained from a given |
| client to a given server or set of servers. |
| |
| <p>The address of the server to connect to is specified as a URI. Two types of |
| connection are supported <code>tcp://</code> for a TCP connection and |
| <code>ssl://</code> for a TCP connection secured by SSL/TLS. |
| For example: |
| <ul> |
| <li><code>tcp://localhost:1883</code></li> |
| <li><code>ssl://localhost:8883</code></li> |
| </ul> |
| If the port is not specified, it will |
| default to 1883 for <code>tcp://</code>" URIs, and 8883 for <code>ssl://</code> URIs. |
| </p> |
| |
| <p> |
| A client identifier <code>clientId</code> must be specified and be less that 65535 characters. |
| It must be unique across all clients connecting to the same |
| server. The clientId is used by the server to store data related to the client, |
| hence it is important that the clientId remain the same when connecting to a server |
| if durable subscriptions or reliable messaging are required. |
| <p>A convenience method is provided to generate a random client id that |
| should satisfy this criteria - <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#generateClientId--"><code>generateClientId()</code></a>. As the client identifier |
| is used by the server to identify a client when it reconnects, the client must use the |
| same identifier between connections if durable subscriptions or reliable |
| delivery of messages is required. |
| </p> |
| <p> |
| In Java SE, SSL can be configured in one of several ways, which the |
| client will use in the following order: |
| </p> |
| <ul> |
| <li><strong>Supplying an <code>SSLSocketFactory</code></strong> - applications can |
| use <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setSocketFactory-javax.net.SocketFactory-"><code>MqttConnectOptions.setSocketFactory(SocketFactory)</code></a> to supply |
| a factory with the appropriate SSL settings.</li> |
| <li><strong>SSL Properties</strong> - applications can supply SSL settings as a |
| simple Java Properties using <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setSSLProperties-java.util.Properties-"><code>MqttConnectOptions.setSSLProperties(Properties)</code></a>.</li> |
| <li><strong>Use JVM settings</strong> - There are a number of standard |
| Java system properties that can be used to configure key and trust stores.</li> |
| </ul> |
| |
| <p>In Java ME, the platform settings are used for SSL connections.</p> |
| <p> |
| A persistence mechanism is used to enable reliable messaging. |
| For messages sent at qualities of service (QoS) 1 or 2 to be reliably delivered, |
| messages must be stored (on both the client and server) until the delivery of the message |
| is complete. If messages are not safely stored when being delivered then |
| a failure in the client or server can result in lost messages. A pluggable |
| persistence mechanism is supported via the <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttClientPersistence.html" title="interface in org.eclipse.paho.client.mqttv3"><code>MqttClientPersistence</code></a> |
| interface. An implementer of this interface that safely stores messages |
| must be specified in order for delivery of messages to be reliable. In |
| addition <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setCleanSession-boolean-"><code>MqttConnectOptions.setCleanSession(boolean)</code></a> must be set |
| to false. In the event that only QoS 0 messages are sent or received or |
| cleanSession is set to true then a safe store is not needed. |
| </p> |
| <p>An implementation of file-based persistence is provided in |
| class <a href="../../../../../org/eclipse/paho/client/mqttv3/persist/MqttDefaultFilePersistence.html" title="class in org.eclipse.paho.client.mqttv3.persist"><code>MqttDefaultFilePersistence</code></a> which will work in all Java SE based |
| systems. If no persistence is needed, the persistence parameter |
| can be explicitly set to <code>null</code>.</p></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>serverURI</code> - the address of the server to connect to, specified as a URI. Can be overridden using |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setServerURIs-java.lang.String:A-"><code>MqttConnectOptions.setServerURIs(String[])</code></a></dd> |
| <dd><code>clientId</code> - a client identifier that is unique on the server being connected to</dd> |
| <dd><code>persistence</code> - the persistence class to use to store in-flight message. If null then the |
| default persistence mechanism is used</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code>java.lang.IllegalArgumentException</code> - if the URI does not start with |
| "tcp://", "ssl://" or "local://"</dd> |
| <dd><code>java.lang.IllegalArgumentException</code> - if the clientId is null or is greater than 65535 characters in length</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if any other problem was encountered</dd> |
| </dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ============ METHOD DETAIL ========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a name="connect-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>connect</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> connect(java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttSecurityException.html" title="class in org.eclipse.paho.client.mqttv3">MqttSecurityException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Connects to an MQTT server using the default options. |
| <p>The default options are specified in <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html" title="class in org.eclipse.paho.client.mqttv3"><code>MqttConnectOptions</code></a> class. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">connect</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when the connect completes. Use |
| null if not required.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the connect to complete. The token |
| will be passed to any callback that has been set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttSecurityException.html" title="class in org.eclipse.paho.client.mqttv3">MqttSecurityException</a></code> - for security related problems</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for non security related problems</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.connect(MqttConnectOptions, Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="connect--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>connect</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> connect() |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttSecurityException.html" title="class in org.eclipse.paho.client.mqttv3">MqttSecurityException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect--">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Connects to an MQTT server using the default options. |
| <p>The default options are specified in <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html" title="class in org.eclipse.paho.client.mqttv3"><code>MqttConnectOptions</code></a> class. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect--">connect</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the connect to complete. The token |
| will be passed to the callback methods if a callback is set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttSecurityException.html" title="class in org.eclipse.paho.client.mqttv3">MqttSecurityException</a></code> - for security related problems</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for non security related problems</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.connect(MqttConnectOptions, Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>connect</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> connect(<a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html" title="class in org.eclipse.paho.client.mqttv3">MqttConnectOptions</a> options) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttSecurityException.html" title="class in org.eclipse.paho.client.mqttv3">MqttSecurityException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Connects to an MQTT server using the provided connect options. |
| <p>The connection will be established using the options specified in the |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html" title="class in org.eclipse.paho.client.mqttv3"><code>MqttConnectOptions</code></a> parameter. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-">connect</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>options</code> - a set of connection parameters that override the defaults.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the connect to complete. The token |
| will be passed to any callback that has been set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttSecurityException.html" title="class in org.eclipse.paho.client.mqttv3">MqttSecurityException</a></code> - for security related problems</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for non security related problems</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.connect(MqttConnectOptions, Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>connect</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> connect(<a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html" title="class in org.eclipse.paho.client.mqttv3">MqttConnectOptions</a> options, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttSecurityException.html" title="class in org.eclipse.paho.client.mqttv3">MqttSecurityException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Connects to an MQTT server using the specified options. |
| <p>The server to connect to is specified on the constructor. |
| It is recommended to call <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#setCallback-org.eclipse.paho.client.mqttv3.MqttCallback-"><code>IMqttAsyncClient.setCallback(MqttCallback)</code></a> prior to |
| connecting in order that messages destined for the client can be accepted |
| as soon as the client is connected. |
| </p> |
| <p>The method returns control before the connect completes. Completion can |
| be tracked by: |
| <ul> |
| <li>Waiting on the returned token <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html#waitForCompletion--"><code>IMqttToken.waitForCompletion()</code></a> or</li> |
| <li>Passing in a callback <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3"><code>IMqttActionListener</code></a></li> |
| </ul> |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#connect-org.eclipse.paho.client.mqttv3.MqttConnectOptions-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">connect</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>options</code> - a set of connection parameters that override the defaults.</dd> |
| <dd><code>userContext</code> - optional object for used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when the connect completes. Use |
| null if not required.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the connect to complete. The token |
| will be passed to any callback that has been set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttSecurityException.html" title="class in org.eclipse.paho.client.mqttv3">MqttSecurityException</a></code> - for security related problems</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for non security related problems including communication errors</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="disconnect-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>disconnect</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> disconnect(java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Disconnects from the server. |
| <p>An attempt is made to quiesce the client allowing outstanding |
| work to complete before disconnecting. It will wait |
| for a maximum of 30 seconds for work to quiesce before disconnecting. |
| This method must not be called from inside <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3"><code>MqttCallback</code></a> methods. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">disconnect</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when the disconnect completes. Use |
| null if not required.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the disconnect to complete. The token |
| will be passed to any callback that has been set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for problems encountered while disconnecting</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect-long-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.disconnect(long, Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="disconnect--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>disconnect</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> disconnect() |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect--">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Disconnects from the server. |
| <p>An attempt is made to quiesce the client allowing outstanding |
| work to complete before disconnecting. It will wait |
| for a maximum of 30 seconds for work to quiesce before disconnecting. |
| This method must not be called from inside <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3"><code>MqttCallback</code></a> methods. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect--">disconnect</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for disconnect to complete. The token |
| will be passed to any callback that has been set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for problems encountered while disconnecting</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect-long-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.disconnect(long, Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="disconnect-long-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>disconnect</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> disconnect(long quiesceTimeout) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect-long-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Disconnects from the server. |
| <p>An attempt is made to quiesce the client allowing outstanding |
| work to complete before disconnecting. It will wait |
| for a maximum of the specified quiesce time for work to complete before disconnecting. |
| This method must not be called from inside <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3"><code>MqttCallback</code></a> methods. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect-long-">disconnect</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>quiesceTimeout</code> - the amount of time in milliseconds to allow for |
| existing work to finish before disconnecting. A value of zero or less |
| means the client will not quiesce.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for disconnect to complete. The token |
| will be passed to the callback methods if a callback is set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for problems encountered while disconnecting</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect-long-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.disconnect(long, Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="disconnect-long-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>disconnect</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> disconnect(long quiesceTimeout, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect-long-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Disconnects from the server. |
| <p> |
| The client will wait for <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3"><code>MqttCallback</code></a> methods to |
| complete. It will then wait for up to the quiesce timeout to allow for |
| work which has already been initiated to complete. For instance when a QoS 2 |
| message has started flowing to the server but the QoS 2 flow has not completed.It |
| prevents new messages being accepted and does not send any messages that have |
| been accepted but not yet started delivery across the network to the server. When |
| work has completed or after the quiesce timeout, the client will disconnect from |
| the server. If the cleanSession flag was set to false and is set to false the |
| next time a connection is made QoS 1 and 2 messages that |
| were not previously delivered will be delivered.</p> |
| <p>This method must not be called from inside <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3"><code>MqttCallback</code></a> methods.</p> |
| <p>The method returns control before the disconnect completes. Completion can |
| be tracked by: |
| <ul> |
| <li>Waiting on the returned token <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html#waitForCompletion--"><code>IMqttToken.waitForCompletion()</code></a> or</li> |
| <li>Passing in a callback <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3"><code>IMqttActionListener</code></a></li> |
| </ul> |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnect-long-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">disconnect</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>quiesceTimeout</code> - the amount of time in milliseconds to allow for |
| existing work to finish before disconnecting. A value of zero or less |
| means the client will not quiesce.</dd> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when the disconnect completes. Use |
| null if not required.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the connect to complete. The token |
| will be passed to any callback that has been set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for problems encountered while disconnecting</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="disconnectForcibly--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>disconnectForcibly</h4> |
| <pre>public void disconnectForcibly() |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnectForcibly--">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Disconnects from the server forcibly to reset all the states. Could be useful when disconnect attempt failed. |
| <p> |
| Because the client is able to establish the TCP/IP connection to a none MQTT server and it will certainly fail to |
| send the disconnect packet. It will wait for a maximum of 30 seconds for work to quiesce before disconnecting and |
| wait for a maximum of 10 seconds for sending the disconnect packet to server.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnectForcibly--">disconnectForcibly</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if any unexpected error</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="disconnectForcibly-long-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>disconnectForcibly</h4> |
| <pre>public void disconnectForcibly(long disconnectTimeout) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnectForcibly-long-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Disconnects from the server forcibly to reset all the states. Could be useful when disconnect attempt failed. |
| <p> |
| Because the client is able to establish the TCP/IP connection to a none MQTT server and it will certainly fail to |
| send the disconnect packet. It will wait for a maximum of 30 seconds for work to quiesce before disconnecting.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnectForcibly-long-">disconnectForcibly</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>disconnectTimeout</code> - the amount of time in milliseconds to allow send disconnect packet to server.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if any unexpected error</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="disconnectForcibly-long-long-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>disconnectForcibly</h4> |
| <pre>public void disconnectForcibly(long quiesceTimeout, |
| long disconnectTimeout) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnectForcibly-long-long-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Disconnects from the server forcibly to reset all the states. Could be useful when disconnect attempt failed. |
| <p> |
| Because the client is able to establish the TCP/IP connection to a none MQTT server and it will certainly fail to |
| send the disconnect packet.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#disconnectForcibly-long-long-">disconnectForcibly</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>quiesceTimeout</code> - the amount of time in milliseconds to allow for existing work to finish before |
| disconnecting. A value of zero or less means the client will not quiesce.</dd> |
| <dd><code>disconnectTimeout</code> - the amount of time in milliseconds to allow send disconnect packet to server.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if any unexpected error</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isConnected--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isConnected</h4> |
| <pre>public boolean isConnected()</pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#isConnected--">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Determines if this client is currently connected to the server.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#isConnected--">isConnected</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if connected, <code>false</code> otherwise.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getClientId--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getClientId</h4> |
| <pre>public java.lang.String getClientId()</pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#getClientId--">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Returns the client ID used by this client. |
| <p>All clients connected to the |
| same server or server farm must have a unique ID. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#getClientId--">getClientId</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the client ID used by this client.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getServerURI--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getServerURI</h4> |
| <pre>public java.lang.String getServerURI()</pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#getServerURI--">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Returns the address of the server used by this client. |
| <p>The format of the returned String is the same as that used on the constructor. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#getServerURI--">getServerURI</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the server's address, as a URI String.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttAsyncClient.html#MqttAsyncClient-java.lang.String-java.lang.String-"><code>MqttAsyncClient(String, String)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getCurrentServerURI--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getCurrentServerURI</h4> |
| <pre>public java.lang.String getCurrentServerURI()</pre> |
| <div class="block">Returns the currently connected Server URI |
| Implemented due to: https://bugs.eclipse.org/bugs/show_bug.cgi?id=481097 |
| |
| Where getServerURI only returns the URI that was provided in |
| MqttAsyncClient's constructor, getCurrentServerURI returns the URI of the |
| Server that the client is currently connected to. This would be different in scenarios |
| where multiple server URIs have been provided to the MqttConnectOptions.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the currently connected server URI</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="checkPing-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>checkPing</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> checkPing(java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <dl> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="subscribe-java.lang.String-int-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>subscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> subscribe(java.lang.String topicFilter, |
| int qos, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String-int-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Subscribe to a topic, which may include wildcards.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String-int-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">subscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilter</code> - the topic to subscribe to, which can include wildcards.</dd> |
| <dd><code>qos</code> - the maximum quality of service at which to subscribe. Messages |
| published at a lower quality of service will be received at the published |
| QoS. Messages published at a higher quality of service will be received using |
| the QoS specified on the subscribe.</dd> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when subscribe |
| has completed</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the subscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error registering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.subscribe(String[], int[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="subscribe-java.lang.String-int-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>subscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> subscribe(java.lang.String topicFilter, |
| int qos) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String-int-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Subscribe to a topic, which may include wildcards.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String-int-">subscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilter</code> - the topic to subscribe to, which can include wildcards.</dd> |
| <dd><code>qos</code> - the maximum quality of service at which to subscribe. Messages |
| published at a lower quality of service will be received at the published |
| QoS. Messages published at a higher quality of service will be received using |
| the QoS specified on the subscribe.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the subscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error registering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.subscribe(String[], int[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="subscribe-java.lang.String:A-int:A-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>subscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> subscribe(java.lang.String[] topicFilters, |
| int[] qos) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Subscribe to multiple topics, each of which may include wildcards. |
| |
| <p>Provides an optimized way to subscribe to multiple topics compared to |
| subscribing to each one individually.</p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-">subscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilters</code> - one or more topics to subscribe to, which can include wildcards</dd> |
| <dd><code>qos</code> - the maximum quality of service at which to subscribe. Messages |
| published at a lower quality of service will be received at the published |
| QoS. Messages published at a higher quality of service will be received using |
| the QoS specified on the subscribe.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the subscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error registering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.subscribe(String[], int[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>subscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> subscribe(java.lang.String[] topicFilters, |
| int[] qos, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Subscribes to multiple topics, each of which may include wildcards. |
| <p>Provides an optimized way to subscribe to multiple topics compared to |
| subscribing to each one individually.</p> |
| <p>The <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#setCallback-org.eclipse.paho.client.mqttv3.MqttCallback-"><code>IMqttAsyncClient.setCallback(MqttCallback)</code></a> method |
| should be called before this method, otherwise any received messages |
| will be discarded. |
| </p> |
| <p> |
| If (@link MqttConnectOptions#setCleanSession(boolean)} was set to true |
| when when connecting to the server then the subscription remains in place |
| until either: |
| <ul> |
| <li>The client disconnects</li> |
| <li>An unsubscribe method is called to un-subscribe the topic</li> |
| </li> |
| </p> |
| <p> |
| If (@link MqttConnectOptions#setCleanSession(boolean)} was set to false |
| when connecting to the server then the subscription remains in place |
| until either: |
| <ul> |
| <li>An unsubscribe method is called to unsubscribe the topic</li> |
| <li>The next time the client connects with cleanSession set to true</ul> |
| </li> |
| With cleanSession set to false the MQTT server will store messages on |
| behalf of the client when the client is not connected. The next time the |
| client connects with the <bold>same client ID</bold> the server will |
| deliver the stored messages to the client. |
| </p> |
| |
| <p>The "topic filter" string used when subscribing |
| may contain special characters, which allow you to subscribe to multiple topics |
| at once.</p> |
| <p>The topic level separator is used to introduce structure into the topic, and |
| can therefore be specified within the topic for that purpose. The multi-level |
| wildcard and single-level wildcard can be used for subscriptions, but they |
| cannot be used within a topic by the publisher of a message. |
| <dl> |
| <dt>Topic level separator</dt> |
| <dd>The forward slash (/) is used to separate each level within |
| a topic tree and provide a hierarchical structure to the topic space. The |
| use of the topic level separator is significant when the two wildcard characters |
| are encountered in topics specified by subscribers.</dd> |
| |
| <dt>Multi-level wildcard</dt> |
| <dd><p>The number sign (#) is a wildcard character that matches |
| any number of levels within a topic. For example, if you subscribe to |
| <span><span class="filepath">finance/stock/ibm/#</span></span>, you receive |
| messages on these topics: |
| <pre> finance/stock/ibm<br /> finance/stock/ibm/closingprice<br /> finance/stock/ibm/currentprice</pre> |
| </p> |
| <p>The multi-level wildcard |
| can represent zero or more levels. Therefore, <em>finance/#</em> can also match |
| the singular <em>finance</em>, where <em>#</em> represents zero levels. The topic |
| level separator is meaningless in this context, because there are no levels |
| to separate.</p> |
| |
| <p>The <span>multi-level</span> wildcard can |
| be specified only on its own or next to the topic level separator character. |
| Therefore, <em>#</em> and <em>finance/#</em> are both valid, but <em>finance#</em> is |
| not valid. <span>The multi-level wildcard must be the last character |
| used within the topic tree. For example, <em>finance/#</em> is valid but |
| <em>finance/#/closingprice</em> is not valid.</span></p></dd> |
| |
| <dt>Single-level wildcard</dt> |
| <dd><p>The plus sign (+) is a wildcard character that matches only one topic |
| level. For example, <em>finance/stock/+</em> matches |
| <em>finance/stock/ibm</em> and <em>finance/stock/xyz</em>, |
| but not <em>finance/stock/ibm/closingprice</em>. Also, because the single-level |
| wildcard matches only a single level, <em>finance/+</em> does not match <em>finance</em>.</p> |
| |
| <p>Use |
| the single-level wildcard at any level in the topic tree, and in conjunction |
| with the multilevel wildcard. Specify the single-level wildcard next to the |
| topic level separator, except when it is specified on its own. Therefore, |
| <em>+</em> and <em>finance/+</em> are both valid, but <em>finance+</em> is |
| not valid. <span>The single-level wildcard can be used at the end of the |
| topic tree or within the topic tree. |
| For example, <em>finance/+</em> and <em>finance/+/ibm</em> are both valid.</span></p> |
| </dd> |
| </dl> |
| </p> |
| <p>The method returns control before the subscribe completes. Completion can |
| be tracked by: |
| <ul> |
| <li>Waiting on the supplied token <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttToken.html#waitForCompletion--"><code>MqttToken.waitForCompletion()</code></a> or</li> |
| <li>Passing in a callback <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3"><code>IMqttActionListener</code></a> to this method</li> |
| </ul> |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">subscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilters</code> - one or more topics to subscribe to, which can include wildcards</dd> |
| <dd><code>qos</code> - the maximum quality of service to subscribe each topic at.Messages |
| published at a lower quality of service will be received at the published |
| QoS. Messages published at a higher quality of service will be received using |
| the QoS specified on the subscribe.</dd> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when subscribe |
| has completed</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the subscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error registering the subscription.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="subscribe-java.lang.String-int-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-org.eclipse.paho.client.mqttv3.IMqttMessageListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>subscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> subscribe(java.lang.String topicFilter, |
| int qos, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttMessageListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttMessageListener</a> messageListener) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String-int-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-org.eclipse.paho.client.mqttv3.IMqttMessageListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Subscribe to a topic, which may include wildcards.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String-int-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-org.eclipse.paho.client.mqttv3.IMqttMessageListener-">subscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilter</code> - the topic to subscribe to, which can include wildcards.</dd> |
| <dd><code>qos</code> - the maximum quality of service at which to subscribe. Messages |
| published at a lower quality of service will be received at the published |
| QoS. Messages published at a higher quality of service will be received using |
| the QoS specified on the subscribe.</dd> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when subscribe |
| has completed</dd> |
| <dd><code>messageListener</code> - a callback to handle incoming messages</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the subscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error registering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.subscribe(String[], int[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="subscribe-java.lang.String-int-org.eclipse.paho.client.mqttv3.IMqttMessageListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>subscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> subscribe(java.lang.String topicFilter, |
| int qos, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttMessageListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttMessageListener</a> messageListener) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String-int-org.eclipse.paho.client.mqttv3.IMqttMessageListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Subscribe to a topic, which may include wildcards.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String-int-org.eclipse.paho.client.mqttv3.IMqttMessageListener-">subscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilter</code> - the topic to subscribe to, which can include wildcards.</dd> |
| <dd><code>qos</code> - the maximum quality of service at which to subscribe. Messages |
| published at a lower quality of service will be received at the published |
| QoS. Messages published at a higher quality of service will be received using |
| the QoS specified on the subscribe.</dd> |
| <dd><code>messageListener</code> - a callback to handle incoming messages</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the subscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error registering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.subscribe(String[], int[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="subscribe-java.lang.String:A-int:A-org.eclipse.paho.client.mqttv3.IMqttMessageListener:A-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>subscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> subscribe(java.lang.String[] topicFilters, |
| int[] qos, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttMessageListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttMessageListener</a>[] messageListeners) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-org.eclipse.paho.client.mqttv3.IMqttMessageListener:A-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Subscribe to multiple topics, each of which may include wildcards. |
| |
| <p>Provides an optimized way to subscribe to multiple topics compared to |
| subscribing to each one individually.</p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-org.eclipse.paho.client.mqttv3.IMqttMessageListener:A-">subscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilters</code> - one or more topics to subscribe to, which can include wildcards</dd> |
| <dd><code>qos</code> - the maximum quality of service at which to subscribe. Messages |
| published at a lower quality of service will be received at the published |
| QoS. Messages published at a higher quality of service will be received using |
| the QoS specified on the subscribe.</dd> |
| <dd><code>messageListeners</code> - one or more callbacks to handle incoming messages</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the subscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error registering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.subscribe(String[], int[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-org.eclipse.paho.client.mqttv3.IMqttMessageListener:A-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>subscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> subscribe(java.lang.String[] topicFilters, |
| int[] qos, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttMessageListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttMessageListener</a>[] messageListeners) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-org.eclipse.paho.client.mqttv3.IMqttMessageListener:A-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Subscribe to multiple topics, each of which may include wildcards. |
| |
| <p>Provides an optimized way to subscribe to multiple topics compared to |
| subscribing to each one individually.</p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-org.eclipse.paho.client.mqttv3.IMqttMessageListener:A-">subscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilters</code> - one or more topics to subscribe to, which can include wildcards</dd> |
| <dd><code>qos</code> - the maximum quality of service at which to subscribe. Messages |
| published at a lower quality of service will be received at the published |
| QoS. Messages published at a higher quality of service will be received using |
| the QoS specified on the subscribe.</dd> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when subscribe |
| has completed</dd> |
| <dd><code>messageListeners</code> - one or more callbacks to handle incoming messages</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the subscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error registering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#subscribe-java.lang.String:A-int:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.subscribe(String[], int[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="unsubscribe-java.lang.String-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>unsubscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> unsubscribe(java.lang.String topicFilter, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Requests the server unsubscribe the client from a topics.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">unsubscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilter</code> - the topic to unsubscribe from. It must match a topicFilter |
| specified on an earlier subscribe.</dd> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when unsubscribe |
| has completed</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the unsubscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error unregistering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.unsubscribe(String[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="unsubscribe-java.lang.String-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>unsubscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> unsubscribe(java.lang.String topicFilter) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Requests the server unsubscribe the client from a topic.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String-">unsubscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilter</code> - the topic to unsubscribe from. It must match a topicFilter |
| specified on an earlier subscribe.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the unsubscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error unregistering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.unsubscribe(String[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="unsubscribe-java.lang.String:A-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>unsubscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> unsubscribe(java.lang.String[] topicFilters) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String:A-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Requests the server unsubscribe the client from one or more topics.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String:A-">unsubscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilters</code> - one or more topics to unsubscribe from. Each topicFilter |
| must match one specified on an earlier subscribe. *</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the unsubscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error unregistering the subscription.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.unsubscribe(String[], Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="unsubscribe-java.lang.String:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>unsubscribe</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttToken</a> unsubscribe(java.lang.String[] topicFilters, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Requests the server unsubscribe the client from one or more topics. |
| <p> |
| Unsubcribing is the opposite of subscribing. When the server receives the |
| unsubscribe request it looks to see if it can find a matching subscription for the |
| client and then removes it. After this point the server will send no more |
| messages to the client for this subscription. |
| </p> |
| <p>The topic(s) specified on the unsubscribe must match the topic(s) |
| specified in the original subscribe request for the unsubscribe to succeed |
| </p> |
| <p>The method returns control before the unsubscribe completes. Completion can |
| be tracked by: |
| <ul> |
| <li>Waiting on the returned token <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttToken.html#waitForCompletion--"><code>MqttToken.waitForCompletion()</code></a> or</li> |
| <li>Passing in a callback <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3"><code>IMqttActionListener</code></a> to this method</li> |
| </ul> |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#unsubscribe-java.lang.String:A-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">unsubscribe</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topicFilters</code> - one or more topics to unsubscribe from. Each topicFilter |
| must match one specified on an earlier subscribe.</dd> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when unsubscribe |
| has completed</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the unsubscribe to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if there was an error unregistering the subscription.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setCallback-org.eclipse.paho.client.mqttv3.MqttCallback-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setCallback</h4> |
| <pre>public void setCallback(<a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3">MqttCallback</a> callback)</pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#setCallback-org.eclipse.paho.client.mqttv3.MqttCallback-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Sets a callback listener to use for events that happen asynchronously. |
| <p>There are a number of events that the listener will be notified about. |
| These include: |
| <ul> |
| <li>A new message has arrived and is ready to be processed</li> |
| <li>The connection to the server has been lost</li> |
| <li>Delivery of a message to the server has completed</li> |
| </ul> |
| </p> |
| <p>Other events that track the progress of an individual operation such |
| as connect and subscribe can be tracked using the <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttToken.html" title="class in org.eclipse.paho.client.mqttv3"><code>MqttToken</code></a> returned from |
| each non-blocking method or using setting a <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3"><code>IMqttActionListener</code></a> on the |
| non-blocking method.<p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#setCallback-org.eclipse.paho.client.mqttv3.MqttCallback-">setCallback</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>callback</code> - which will be invoked for certain asynchronous events</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3"><code>MqttCallback</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setManualAcks-boolean-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setManualAcks</h4> |
| <pre>public void setManualAcks(boolean manualAcks)</pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#setManualAcks-boolean-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">If manualAcks is set to true, then on completion of the messageArrived callback |
| the MQTT acknowledgements are not sent. You must call messageArrivedComplete |
| to send those acknowledgements. This allows finer control over when the acks are |
| sent. The default behaviour, when manualAcks is false, is to send the MQTT |
| acknowledgements automatically at the successful completion of the messageArrived |
| callback method.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#setManualAcks-boolean-">setManualAcks</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="messageArrivedComplete-int-int-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>messageArrivedComplete</h4> |
| <pre>public void messageArrivedComplete(int messageId, |
| int qos) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#messageArrivedComplete-int-int-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Indicate that the application has completed processing the message with id messageId. |
| This will cause the MQTT acknowledgement to be sent to the server.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#messageArrivedComplete-int-int-">messageArrivedComplete</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>messageId</code> - the MQTT message id to be acknowledged</dd> |
| <dd><code>qos</code> - the MQTT QoS of the message to be acknowledged</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="generateClientId--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>generateClientId</h4> |
| <pre>public static java.lang.String generateClientId()</pre> |
| <div class="block">Returns a randomly generated client identifier based on the the fixed prefix (paho) |
| and the system time. |
| <p>When cleanSession is set to false, an application must ensure it uses the |
| same client identifier when it reconnects to the server to resume state and maintain |
| assured message delivery.</p></div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a generated client identifier</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttConnectOptions.html#setCleanSession-boolean-"><code>MqttConnectOptions.setCleanSession(boolean)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getPendingDeliveryTokens--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getPendingDeliveryTokens</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a>[] getPendingDeliveryTokens()</pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#getPendingDeliveryTokens--">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Returns the delivery tokens for any outstanding publish operations. |
| <p>If a client has been restarted and there are messages that were in the |
| process of being delivered when the client stopped this method |
| returns a token for each in-flight message enabling the delivery to be tracked |
| Alternately the <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html#deliveryComplete-org.eclipse.paho.client.mqttv3.IMqttDeliveryToken-"><code>MqttCallback.deliveryComplete(IMqttDeliveryToken)</code></a> |
| callback can be used to track the delivery of outstanding messages. |
| </p> |
| <p>If a client connects with cleanSession true then there will be no |
| delivery tokens as the cleanSession option deletes all earlier state. |
| For state to be remembered the client must connect with cleanSession |
| set to false</P></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#getPendingDeliveryTokens--">getPendingDeliveryTokens</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>zero or more delivery tokens</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="publish-java.lang.String-byte:A-int-boolean-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>publish</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a> publish(java.lang.String topic, |
| byte[] payload, |
| int qos, |
| boolean retained, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPersistenceException.html" title="class in org.eclipse.paho.client.mqttv3">MqttPersistenceException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-byte:A-int-boolean-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Publishes a message to a topic on the server. |
| <p>A convenience method, which will |
| create a new <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3"><code>MqttMessage</code></a> object with a byte array payload and the |
| specified QoS, and then publish it. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-byte:A-int-boolean-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">publish</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topic</code> - to deliver the message to, for example "finance/stock/ibm".</dd> |
| <dd><code>payload</code> - the byte array to use as the payload</dd> |
| <dd><code>qos</code> - the Quality of Service to deliver the message at. Valid values are 0, 1 or 2.</dd> |
| <dd><code>retained</code> - whether or not this message should be retained by the server.</dd> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when message delivery |
| hsa completed to the requested quality of service</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the publish to complete. The token |
| will be passed to any callback that has been set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPersistenceException.html" title="class in org.eclipse.paho.client.mqttv3">MqttPersistenceException</a></code> - when a problem occurs storing the message</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for other errors encountered while publishing the message. |
| For instance client not connected.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.publish(String, MqttMessage, Object, IMqttActionListener)</code></a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html#setQos-int-"><code>MqttMessage.setQos(int)</code></a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html#setRetained-boolean-"><code>MqttMessage.setRetained(boolean)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="publish-java.lang.String-byte:A-int-boolean-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>publish</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a> publish(java.lang.String topic, |
| byte[] payload, |
| int qos, |
| boolean retained) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPersistenceException.html" title="class in org.eclipse.paho.client.mqttv3">MqttPersistenceException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-byte:A-int-boolean-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Publishes a message to a topic on the server. |
| <p>A convenience method, which will |
| create a new <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3"><code>MqttMessage</code></a> object with a byte array payload and the |
| specified QoS, and then publish it. |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-byte:A-int-boolean-">publish</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topic</code> - to deliver the message to, for example "finance/stock/ibm".</dd> |
| <dd><code>payload</code> - the byte array to use as the payload</dd> |
| <dd><code>qos</code> - the Quality of Service to deliver the message at. Valid values are 0, 1 or 2.</dd> |
| <dd><code>retained</code> - whether or not this message should be retained by the server.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the publish to complete. The token |
| will be passed to any callback that has been set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPersistenceException.html" title="class in org.eclipse.paho.client.mqttv3">MqttPersistenceException</a></code> - when a problem occurs storing the message</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for other errors encountered while publishing the message. |
| For instance if too many messages are being processed.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.publish(String, MqttMessage, Object, IMqttActionListener)</code></a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html#setQos-int-"><code>MqttMessage.setQos(int)</code></a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html#setRetained-boolean-"><code>MqttMessage.setRetained(boolean)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>publish</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a> publish(java.lang.String topic, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3">MqttMessage</a> message) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPersistenceException.html" title="class in org.eclipse.paho.client.mqttv3">MqttPersistenceException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Publishes a message to a topic on the server. |
| Takes an <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3"><code>MqttMessage</code></a> message and delivers it to the server at the |
| requested quality of service.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-">publish</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topic</code> - to deliver the message to, for example "finance/stock/ibm".</dd> |
| <dd><code>message</code> - to deliver to the server</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the publish to complete. The token |
| will be passed to any callback that has been set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPersistenceException.html" title="class in org.eclipse.paho.client.mqttv3">MqttPersistenceException</a></code> - when a problem occurs storing the message</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for other errors encountered while publishing the message. |
| For instance client not connected.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"><code>IMqttAsyncClient.publish(String, MqttMessage, Object, IMqttActionListener)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>publish</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttDeliveryToken.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttDeliveryToken</a> publish(java.lang.String topic, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3">MqttMessage</a> message, |
| java.lang.Object userContext, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttActionListener</a> callback) |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a>, |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPersistenceException.html" title="class in org.eclipse.paho.client.mqttv3">MqttPersistenceException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Publishes a message to a topic on the server. |
| <p> |
| Once this method has returned cleanly, the message has been accepted for publication by the |
| client and will be delivered on a background thread. |
| In the event the connection fails or the client stops. Messages will be delivered to the |
| requested quality of service once the connection is re-established to the server on condition that: |
| <ul> |
| <li>The connection is re-established with the same clientID |
| <li>The original connection was made with (@link MqttConnectOptions#setCleanSession(boolean)} |
| set to false |
| <li>The connection is re-established with (@link MqttConnectOptions#setCleanSession(boolean)} |
| set to false |
| <li>Depending when the failure occurs QoS 0 messages may not be delivered. |
| </ul> |
| </p> |
| |
| <p>When building an application, |
| the design of the topic tree should take into account the following principles |
| of topic name syntax and semantics:</p> |
| |
| <ul> |
| <li>A topic must be at least one character long.</li> |
| <li>Topic names are case sensitive. For example, <em>ACCOUNTS</em> and <em>Accounts</em> are |
| two different topics.</li> |
| <li>Topic names can include the space character. For example, <em>Accounts |
| payable</em> is a valid topic.</li> |
| <li>A leading "/" creates a distinct topic. For example, <em>/finance</em> is |
| different from <em>finance</em>. <em>/finance</em> matches "+/+" and "/+", but |
| not "+".</li> |
| <li>Do not include the null character (Unicode <samp class="codeph">\x0000</samp>) in |
| any topic.</li> |
| </ul> |
| |
| <p>The following principles apply to the construction and content of a topic |
| tree:</p> |
| |
| <ul> |
| <li>The length is limited to 64k but within that there are no limits to the |
| number of levels in a topic tree.</li> |
| <li>There can be any number of root nodes; that is, there can be any number |
| of topic trees.</li> |
| </ul> |
| </p> |
| <p>The method returns control before the publish completes. Completion can |
| be tracked by: |
| <ul> |
| <li>Setting an <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#setCallback-org.eclipse.paho.client.mqttv3.MqttCallback-"><code>IMqttAsyncClient.setCallback(MqttCallback)</code></a> where the |
| <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html#deliveryComplete-org.eclipse.paho.client.mqttv3.IMqttDeliveryToken-"><code>MqttCallback.deliveryComplete(IMqttDeliveryToken)</code></a> |
| method will be called.</li> |
| <li>Waiting on the returned token <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttToken.html#waitForCompletion--"><code>MqttToken.waitForCompletion()</code></a> or</li> |
| <li>Passing in a callback <a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttActionListener.html" title="interface in org.eclipse.paho.client.mqttv3"><code>IMqttActionListener</code></a> to this method</li> |
| </ul> |
| </p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#publish-java.lang.String-org.eclipse.paho.client.mqttv3.MqttMessage-java.lang.Object-org.eclipse.paho.client.mqttv3.IMqttActionListener-">publish</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>topic</code> - to deliver the message to, for example "finance/stock/ibm".</dd> |
| <dd><code>message</code> - to deliver to the server</dd> |
| <dd><code>userContext</code> - optional object used to pass context to the callback. Use |
| null if not required.</dd> |
| <dd><code>callback</code> - optional listener that will be notified when message delivery |
| has completed to the requested quality of service</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>token used to track and wait for the publish to complete. The token |
| will be passed to callback methods if set.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttPersistenceException.html" title="class in org.eclipse.paho.client.mqttv3">MqttPersistenceException</a></code> - when a problem occurs storing the message</dd> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - for other errors encountered while publishing the message. |
| For instance client not connected.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3"><code>MqttMessage</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="reconnect--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>reconnect</h4> |
| <pre>public void reconnect() |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block">User triggered attempt to reconnect</div> |
| <dl> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setBufferOpts-org.eclipse.paho.client.mqttv3.DisconnectedBufferOptions-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setBufferOpts</h4> |
| <pre>public void setBufferOpts(<a href="../../../../../org/eclipse/paho/client/mqttv3/DisconnectedBufferOptions.html" title="class in org.eclipse.paho.client.mqttv3">DisconnectedBufferOptions</a> bufferOpts)</pre> |
| <div class="block">Sets the DisconnectedBufferOptions for this client</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>bufferOpts</code> - </dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getBufferedMessageCount--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getBufferedMessageCount</h4> |
| <pre>public int getBufferedMessageCount()</pre> |
| </li> |
| </ul> |
| <a name="getBufferedMessage-int-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getBufferedMessage</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttMessage.html" title="class in org.eclipse.paho.client.mqttv3">MqttMessage</a> getBufferedMessage(int bufferIndex)</pre> |
| </li> |
| </ul> |
| <a name="deleteBufferedMessage-int-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>deleteBufferedMessage</h4> |
| <pre>public void deleteBufferedMessage(int bufferIndex)</pre> |
| </li> |
| </ul> |
| <a name="close--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>close</h4> |
| <pre>public void close() |
| throws <a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#close--">IMqttAsyncClient</a></code></span></div> |
| <div class="block">Close the client |
| Releases all resource associated with the client. After the client has |
| been closed it cannot be reused. For instance attempts to connect will fail.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html#close--">close</a></code> in interface <code><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttAsyncClient.html" title="interface in org.eclipse.paho.client.mqttv3">IMqttAsyncClient</a></code></dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttException.html" title="class in org.eclipse.paho.client.mqttv3">MqttException</a></code> - if the client is not disconnected.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getDebug--"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>getDebug</h4> |
| <pre>public <a href="../../../../../org/eclipse/paho/client/mqttv3/util/Debug.html" title="class in org.eclipse.paho.client.mqttv3.util">Debug</a> getDebug()</pre> |
| <div class="block">Return a debug object that can be used to help solve problems.</div> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| </div> |
| <!-- ========= END OF CLASS DATA ========= --> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a name="navbar.bottom"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.bottom.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/MqttAsyncClient.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../../index-files/index-1.html">Index</a></li> |
| <li><a href="../../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../../org/eclipse/paho/client/mqttv3/IMqttToken.html" title="interface in org.eclipse.paho.client.mqttv3"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../../../org/eclipse/paho/client/mqttv3/MqttCallback.html" title="interface in org.eclipse.paho.client.mqttv3"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../../index.html?org/eclipse/paho/client/mqttv3/MqttAsyncClient.html" target="_top">Frames</a></li> |
| <li><a href="MqttAsyncClient.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| </body> |
| </html> |