Package org.opentrafficsim.sim0mq.swing
Class PublisherDemo
- java.lang.Object
-
- org.opentrafficsim.sim0mq.swing.PublisherDemo
-
public final class PublisherDemo extends java.lang.ObjectExperiment with the Sim0MQPublisher.Copyright (c) 2020-2020 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.- Author:
- Alexander Verbraeck, Peter Knoppers
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidmain(java.lang.String[] args)Test code.static byte[][]readMessages(org.zeromq.ZMQ.Socket socket)Read as many messages from a ZMQ socket as are available.
-
-
-
Method Detail
-
main
public static void main(java.lang.String[] args) throws java.io.IOException, SimRuntimeException, javax.naming.NamingException, DSOLException, OTSDrawingException, Sim0MQException, SerializationException, java.lang.InterruptedExceptionTest code.- Parameters:
args- String[]; the command line arguments (not used)- Throws:
java.io.IOException- ...javax.naming.NamingException- ...SimRuntimeException- ...DSOLException- ...OTSDrawingException- ...SerializationException- ...Sim0MQException- ...java.lang.InterruptedException- ...
-
readMessages
public static byte[][] readMessages(org.zeromq.ZMQ.Socket socket)
Read as many messages from a ZMQ socket as are available. Do NOT block when there are no (more) messages to read.- Parameters:
socket- ZMQ.Socket; the socket- Returns:
- byte[][]; the read messages
-
-