Class NetworkTransceiver
java.lang.Object
nl.tudelft.simulation.event.EventProducer
org.opentrafficsim.imb.transceiver.AbstractTransceiver
org.opentrafficsim.imb.transceiver.urbanstrategy.NetworkTransceiver
- All Implemented Interfaces:
Serializable,EventListener,nl.tudelft.simulation.event.EventListenerInterface,nl.tudelft.simulation.event.EventProducerInterface,Identifiable,org.opentrafficsim.imb.transceiver.EventTransceiver,org.opentrafficsim.imb.transceiver.Transceiver
public class NetworkTransceiver extends AbstractTransceiver
IMB transceiver for the network.
OTS publishes events about the Network to IMB to be able to identify the network. At the start of the OTS simulation, or when a (sub) network is added later, a NEW message is sent to IMB to identify the network's id. No CHANGE or DELETE messages are posted.
OTS publishes events about the Network to IMB to be able to identify the network. At the start of the OTS simulation, or when a (sub) network is added later, a NEW message is sent to IMB to identify the network's id. No CHANGE or DELETE messages are posted.
NEW
| Variable | Type | Comments |
|---|---|---|
| timestamp | double | time of the event, in simulation time seconds |
| networkId | String | Name of the network as used in e.g., Link messages |
CHANGE
Not sent
DELETE
Not sent
Copyright (c) 2013-2020 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
- Version:
- $Revision$, $LastChangedDate$, by $Author$, initial version Sep 16, 2016
- Author:
- Alexander Verbraeck, Peter Knoppers
- See Also:
- Serialized Form
-
Field Summary
-
Constructor Summary
Constructors Constructor Description NetworkTransceiver(org.opentrafficsim.imb.connector.Connector connector, DEVSSimulatorInterface.TimeDoubleUnit simulator, OTSNetwork network)Construct a new NetworkTransceiver. -
Method Summary
Methods inherited from class org.opentrafficsim.imb.transceiver.AbstractTransceiver
addIMBtoOTSChannel, addIMBtoOTSChannel, addOTSToIMBChannel, getConnector, getId, getSimulator, handleMessageFromIMB, notify, removeOTSToIMBChannel, toStringMethods inherited from class nl.tudelft.simulation.event.EventProducer
addListener, addListener, addListener, addListener, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, removeAllListeners, removeAllListeners, removeListener
-
Constructor Details
-
NetworkTransceiver
public NetworkTransceiver(org.opentrafficsim.imb.connector.Connector connector, DEVSSimulatorInterface.TimeDoubleUnit simulator, OTSNetwork network) throws org.opentrafficsim.imb.IMBExceptionConstruct a new NetworkTransceiver.- Parameters:
connector- Connector; the IMB connector through which this transceiver communicatessimulator- DEVSSimulatorInterface.TimeDoubleUnit; the simulator to retrieve the timestampnetwork- OTSNetwork; the OTS network- Throws:
org.opentrafficsim.imb.IMBException- when the message cannot be sentNullPointerException- in case one of the arguments is null.
-