org.eclipse.paho.client.mqttv3.internal
Class LocalNetworkModule

java.lang.Object
  extended by org.eclipse.paho.client.mqttv3.internal.LocalNetworkModule
All Implemented Interfaces:
NetworkModule

public class LocalNetworkModule
extends Object
implements NetworkModule

Special comms class that allows an MQTT client to use a non TCP / optimised mechanism to talk to an MQTT server when running in the same JRE instance as the MQTT server. This class checks for the existence of the optimised comms adatper class i.e. the one that provides the optimised communication mechanism. If not available the request to connect using the optimised mechanism is rejected. The only known server that implements this is the microbroker:- an MQTT server that ships with a number of IBM products.


Constructor Summary
LocalNetworkModule(String brokerName)
           
 
Method Summary
 InputStream getInputStream()
           
 OutputStream getOutputStream()
           
 void start()
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocalNetworkModule

public LocalNetworkModule(String brokerName)
Method Detail

start

public void start()
           throws IOException,
                  MqttException
Specified by:
start in interface NetworkModule
Throws:
IOException
MqttException

getInputStream

public InputStream getInputStream()
                           throws IOException
Specified by:
getInputStream in interface NetworkModule
Throws:
IOException

getOutputStream

public OutputStream getOutputStream()
                             throws IOException
Specified by:
getOutputStream in interface NetworkModule
Throws:
IOException

stop

public void stop()
          throws IOException
Specified by:
stop in interface NetworkModule
Throws:
IOException


Copyright © 2013. All Rights Reserved.