Stride Reference Manual  1.0
RemoteSimulatorReceiver.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include "Simulator.h"
4 #include "util/TravelData.h"
5 
6 using namespace stride;
7 using namespace util;
8 
9 namespace stride {
10 
12 #ifdef MPI_USED
13 public:
14  RemoteSimulatorReceiver(Simulator* sim) : m_listening(true), m_count(1), m_sim(sim) {};
15 
16  ~RemoteSimulatorReceiver() = default;
17 
18  // Receivers listens to messages on the network (MPI)
19  void listen();
20 
21  // Stop listening to the network
22  void stopListening() { m_listening = false; }
23 
24 private:
25  bool m_listening;
26  int m_count;
27 
28  Simulator* m_sim;
29 #endif
30 #ifndef MPI_USED
31  public:
33  ~RemoteSimulatorReceiver() = default;
34 
35  void listen() {};
36  void stopListening() {};
37 #endif
38 };
39 
40 }
Time Dependent Person DataType.
Definition: NoBehaviour.h:17
Header for the Simulator class.
Main class that contains and direct the virtual world.
Definition: Simulator.h:64