MAK RTIspy API Documentation for HLA 4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
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 #pragma once
13 
14 #if defined(DtMOM) && (defined(DtIFSPEC1516) || defined(DtIFSPEC1516E) || defined(DtIFSPEC1516_2025))
15 
16 #include "rtiMsConfig.h"
17 #include "internalTypes.h"
18 #include "mInteraction.h"
19 #include <vlutil/vlList.h>
20 
21 class DtMomInterCbMgr;
22 class DtSetFederateSwitchesInteraction;
23 typedef void (*DtSetFederateSwitchesInteractionCb) (const DtSetFederateSwitchesInteraction& inter, void* usr);
24 
25 class DT_DLL_LRC DtSetFederateSwitchesInteraction : public DtServiceInteraction
26 {
27 public:
28 
30  DtSetFederateSwitchesInteraction();
31 
33  virtual ~DtSetFederateSwitchesInteraction();
34 
36  DtSetFederateSwitchesInteraction(const DtSetFederateSwitchesInteraction& orig);
37 
39  DtSetFederateSwitchesInteraction& operator=(const DtSetFederateSwitchesInteraction& orig);
40 
44  virtual const DtPhvps& phvps();
45 
48  virtual bool setFromPhvps(const DtPhvps& phvps);
49 
51  virtual void reset();
52 
56 
57 #define SWITCH_PARAMETER_DECLAR(lowerCaseName, upperCaseName) \
58  virtual bool lowerCaseName() const; \
59  virtual void set##upperCaseName(bool switchValue); \
60  virtual bool lowerCaseName##IsSet() const; \
61  virtual const char* lowerCaseName##Name() const;
62 
63 
65  SWITCH_PARAMETER_DECLAR(objectClassRelevanceAdvisory, ObjectClassRelevanceAdvisory)
66  SWITCH_PARAMETER_DECLAR(attributeRelevanceAdvisory, AttributeRelevanceAdvisory)
67  SWITCH_PARAMETER_DECLAR(attributeScopeAdvisory, AttributeScopeAdvisory)
68  SWITCH_PARAMETER_DECLAR(interactionRelevanceAdvisory, InteractionRelevanceAdvisory)
69  SWITCH_PARAMETER_DECLAR(conveyRegionDesignatorSets, ConveyRegionDesignatorSets)
70  SWITCH_PARAMETER_DECLAR(serviceReporting, ServiceReporting)
71  SWITCH_PARAMETER_DECLAR(exceptionReporting, ExceptionReporting)
72  SWITCH_PARAMETER_DECLAR(sendServiceReportsToFile, SendServiceReportsToFile)
73 #if defined(DtIFSPEC1516E)
74  SWITCH_PARAMETER_DECLAR(conveyProducingFederate, ConveyProducingFederate)
75 #endif
76 
78  virtual MAKRti::DtResignAction automaticResignDirective() const;
79  virtual void setAutomaticResignDirective(MAKRti::DtResignAction switchValue);
80  virtual bool automaticResignDirectiveIsSet() const;
81  virtual const char* automaticResignDirectiveName() const;
82 
84 
85 public:
87  static DtServiceInteraction* create();
88 
90  static void addCallback(DtMomInterCbMgr* callBackManager, DtSetFederateSwitchesInteractionCb cb, void* usr);
91  static void removeCallback(DtMomInterCbMgr* callBackManager, DtSetFederateSwitchesInteractionCb cb, void* usr);
92 
93 protected:
94 
96  virtual void encodeSwitch(const char* parameterName, bool switchValue);
97 
100  virtual bool decodeSwitch(const DtPhvps& parameters, int index, bool& switchValue);
101 
103  virtual void setSwitch(DtParameterHandle currentHandle, bool switchValue);
104 
106  virtual void handleDecodeError(DtParameterHandle currentHandle);
107 
109 
110  virtual void encodeAutomaticResignDirective();
112  virtual bool decodeAutomaticResignDirective(DtMomInteraction* data, const DtPhvps& parameters, int index);
114 
115 public:
116  static const char* theInteractionName;
117 
118 protected:
119 
121  bool myObjectClassRelevanceAdvisory;
122  bool myObjectClassRelevanceAdvisoryIsSet;
123  bool myAttributeRelevanceAdvisory;
124  bool myAttributeRelevanceAdvisoryIsSet;
125  bool myAttributeScopeAdvisory;
126  bool myAttributeScopeAdvisoryIsSet;
127  bool myInteractionRelevanceAdvisory;
128  bool myInteractionRelevanceAdvisoryIsSet;
129  bool myConveyRegionDesignatorSets;
130  bool myConveyRegionDesignatorSetsIsSet;
131  bool myServiceReporting;
132  bool myServiceReportingIsSet;
133  bool myExceptionReporting;
134  bool myExceptionReportingIsSet;
135  bool mySendServiceReportsToFile;
136  bool mySendServiceReportsToFileIsSet;
137  MAKRti::DtResignAction myAutomaticResignDirective;
138  bool myAutomaticResignDirectiveIsSet;
139 #if defined(DtIFSPEC1516E)
140  bool myConveyProducingFederate;
141  bool myConveyProducingFederateIsSet;
142 #endif
143 
144 };
145 
146 #endif
#define DT_DLL_LRC
Definition: rtiMsConfig.h:155
Definition: pHandValSet.h:38
The declaration of internal types.
DtHandle DtParameterHandle
Definition: internalTypes.h:56

Document ID: Generated on Sun Jul 20 16:15:30 EDT 2025 from SVN revision 277985
Copyright © 2005-2025 MAK Technologies Inc. All Rights Reserved (www.mak.com)