MAK RTIspy API Documentation for HLA 1.3
setFederateSwitches.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 2004 MAK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 /*********************************************************************
6 ** $RCSfile: setFederateSwitches.h,v $ $Revision: 1.6 $ $State: Exp $
7 *********************************************************************/
8 
11 
12 #ifndef DtSetFederateSwitchesInteraction_H_
13 #define DtSetFederateSwitchesInteraction_H_
14 
15 #ifdef DtMOM
16 #if defined(DtIFSPEC1516) || defined(DtIFSPEC1516E)
17 
18 #include "rtiMsConfig.h"
19 #include "internalTypes.h"
20 #include "mInteraction.h"
21 #include <vlutil/vlList.h>
22 
23 class DtMomInterCbMgr;
24 class DtSetFederateSwitchesInteraction;
25 typedef void (*DtSetFederateSwitchesInteractionCb)
26  (const DtSetFederateSwitchesInteraction& inter, void* usr);
27 
28 class DT_DLL_LRC DtSetFederateSwitchesInteraction :
29  public DtServiceInteraction
30 {
31 public:
32 
34  DtSetFederateSwitchesInteraction();
35 
37  virtual ~DtSetFederateSwitchesInteraction();
38 
40  DtSetFederateSwitchesInteraction(
41  const DtSetFederateSwitchesInteraction& orig);
42 
44  DtSetFederateSwitchesInteraction& operator=(
45  const DtSetFederateSwitchesInteraction& orig);
46 
49  virtual const DtPhvps& phvps();
50 
53  virtual bool setFromPhvps(const DtPhvps& phvps);
54 
56  virtual bool conveyRegions() const;
57  virtual void setConveyRegions(bool data);
58 
60  virtual bool receivedConveyRegions() const;
61 
62 #ifdef DtIFSPEC1516E
63 
64  virtual bool conveyProducingFederate() const;
65  virtual void setConveyProducingFederate(bool data);
66 
68  virtual bool receivedConveyProducingFederate() const;
69 #endif
70 
71 public:
73  static DtServiceInteraction* create();
74 
76  static void addCallback(DtMomInterCbMgr* callBackManager,
77  DtSetFederateSwitchesInteractionCb cb, void* usr);
78  static void removeCallback(DtMomInterCbMgr* callBackManager,
79  DtSetFederateSwitchesInteractionCb cb, void* usr);
80 
81 protected:
82 
84  virtual void encodeConveyRegions(
85  const DtMomInteraction& data,
86  DtPhvps* parameters,
87  DtParameterHandle parameterHandle);
88 
90  virtual void decodeConveyRegions(
91  DtMomInteraction* data,
92  const DtPhvps& parameters,
93  int index);
94 
95 #ifdef DtIFSPEC1516E
96 
97  virtual void encodeConveyProducingFederate(
98  const DtMomInteraction& data,
99  DtPhvps* parameters,
100  DtParameterHandle parameterHandle);
101 
103  virtual void decodeConveyProducingFederate(
104  DtMomInteraction* data,
105  const DtPhvps& parameters,
106  int index);
107 #endif
108 
109 public:
110  static const char* theInteractionName;
111 
112 protected:
114  bool myConveyRegions;
115 
116  bool myReceivedConveyRegions;
117 
118  const char *CONVEY_REGIONS_PARAMETER_NAME;
119 
120 #ifdef DtIFSPEC1516E
121  bool myConveyProducingFederate;
122 
123  bool myReceivedConveyProducingFederate;
124 
125  const char *CONVEY_PRODUCING_FEDERATE_PARAMETER_NAME;
126 #endif
127 
128 };
129 
130 #endif
131 #endif
132 #endif

Document ID: Generated on Tue May 7 16:26:47 EDT 2013 from SVN revision 126903
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (www.mak.com)