VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
simControlEvent.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2020 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 #pragma once
6 
10 #include <vrfMsgTransport/events.h>
11 #include <vlpi/simulationAddress.h>
12 
13 namespace makVrfEvents
14 {
16  {
17  public:
19  {
20  Unknown = 0,
21  Play = 1,
22  Pause = 2
23  };
24 
25  public:
26  DtSimControlEvent() : DtEvent(SimControlEvent), mySimControl(Unknown) {};
27  DtSimControlEvent(SimControl control) : DtEvent(SimControlEvent), mySimControl(control) {};
28  DtSimControlEvent(const DtSimControlEvent& orig) : DtEvent(orig), mySimControl(orig.mySimControl), myReceiver(orig.myReceiver) {};
29  virtual~ DtSimControlEvent() {};
30 
31  virtual DtEvent* clone() const { return new DtSimControlEvent(*this); };
32 
35  virtual bool processLocally() const { return true; };
36 
37  void setReceiver(const DtSimulationAddress& addr) { myReceiver = addr; };
38  const DtSimulationAddress& receiver() const { return myReceiver; };
39 
40  void setSimControl(SimControl c) { mySimControl = c; };
41  SimControl simControl() const { return mySimControl; };
42 
43  protected:
44  SimControl mySimControl;
45  DtSimulationAddress myReceiver;
46  };
47 }
const DtSimulationAddress & receiver() const
Definition: simControlEvent.h:38
virtual DtEvent * clone() const
Definition: simControlEvent.h:31
DtSimControlEvent(SimControl control)
Definition: simControlEvent.h:27
void setSimControl(SimControl c)
Definition: simControlEvent.h:40
void setReceiver(const DtSimulationAddress &addr)
Definition: simControlEvent.h:37
Definition: event.h:13
SimControl
Definition: simControlEvent.h:18
DtSimulationAddress myReceiver
Definition: simControlEvent.h:45
Definition: simControlEvent.h:15
#define DT_DLL_vrfMsgTransport
This file is used to determine how to build Disable inconsistent dll linkage warning Visual Studio 6...
Definition: vrfCommunicationManagerDefines.h:26
SimControl simControl() const
Definition: simControlEvent.h:41
virtual bool processLocally() const
There are some events that, if sent over the network, don&#39;t want to be processed locally. Event these events (if not sent) do not want to be processed locally. Return false from this method to never process this event locally.
Definition: simControlEvent.h:35
DtSimControlEvent(const DtSimControlEvent &orig)
Definition: simControlEvent.h:28
DtSimControlEvent()
Definition: simControlEvent.h:26

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)