View Javadoc
1   package org.opentrafficsim.sim0mq.publisher;
2   
3   import org.djutils.immutablecollections.ImmutableSet;
4   import org.opentrafficsim.core.network.Node;
5   import org.opentrafficsim.core.network.Network;
6   
7   /**
8    * Transceiver for Node ids.
9    * <p>
10   * Copyright (c) 2020-2024 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved. <br>
11   * BSD-style license. See <a href="https://opentrafficsim.org/docs/license.html">OpenTrafficSim License</a>.
12   * </p>
13   * @author <a href="https://github.com/averbraeck">Alexander Verbraeck</a>
14   * @author <a href="https://tudelft.nl/staff/p.knoppers-1">Peter Knoppers</a>
15   * @author <a href="https://github.com/wjschakel">Wouter Schakel</a>
16   */
17  
18  public class NodeIdTransceiver extends AbstractIdTransceiver
19  {
20      /**
21       * Construct a new LinkIdTransceiver.
22       * @param network Network; the OTS network
23       */
24      public NodeIdTransceiver(final Network network)
25      {
26          super(network, "Node id transceiver");
27      }
28  
29      /** {@inheritDoc} */
30      @Override
31      public String toString()
32      {
33          return "NodeIdTransceiver [network=" + ", super=" + super.toString() + "]";
34      }
35  
36      /** {@inheritDoc} */
37      @Override
38      ImmutableSet<Node> getSet()
39      {
40          return (ImmutableSet<Node>) getNetwork().getNodeMap().values();
41      }
42  
43  }