MAK RTIspy API Documentation for HLA 1.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
federatePub.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 2001 MAK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 /*********************************************************************
6 ** $RCSfile: federatePub.h,v $ $Revision: 1.16 $ $State: Exp $
7 *********************************************************************/
8 #ifdef DtMOM
9 
12 #ifndef DtMomFederatePublisher_H_
13 #define DtMomFederatePublisher_H_
14 
15 #include "momPublisher.h"
16 #include "momNetParam.h"
17 #include "momElement.h"
18 #include "federateSR.h"
19 
20 #include <vlutil/vlTime.h>
21 
22 class DtMomFederateSR;
23 class DtMomInspector;
24 
25 class DT_DLL_LRC DtMomFederatePublisher : public DtMomPublisher
26 {
27 public:
28 
30  DtMomFederatePublisher(DtConnectionMgr* connMgrPtr, DtFomModuleManager* fomMgrPtr,
31  DtObjectMgr* objMgrPtr, DtMomInspector* servicePtr,
32  DtFederateHandle fedHandle, int defaultInterval =0);
33 
35  virtual ~DtMomFederatePublisher();
36 
38  virtual void setTiming(unsigned long interval);
39 
41  virtual void updateInitial();
42 
44  virtual void updateTimeConstrained();
45 
47  virtual void updateTimeRegulating();
48 
50  virtual void updateAsynchronousDelivery();
51 
53  virtual void updateFederateState();
54 
56  virtual void updateTimeState();
57 
59  virtual void updateConveyRegion();
60 
62  virtual void updateConveyProducingFederate();
63 
65  virtual void updateReportInterval(int newInterval);
66 
67 
69  virtual void tick();
70 
71 protected:
72 
74  DtMomFederatePublisher(const DtMomFederatePublisher& orig);
75 
77  DtMomFederatePublisher& operator=(const DtMomFederatePublisher& orig);
78 
80  virtual void checkSwitches();
81 
83  inline void checkSwitch(DtAttributeHandleSet& attrSet, bool& pubValue, bool repValue, DtMomElement element);
84 
85 protected:
86 
89  unsigned long myInterval;
90 
92  MAKRti::DtTime myNextReport;
93 
94  DtMomFederateSR* myFederateSR;
95 
97  bool myTimeConstrained;
98  bool myTimeRegulating;
99  bool myAsynchronousDelivery;
100  DtMomFederateStates myFederateState;
101  DtMomTimeManagerStates myTimeManagerState;
102 
103 
105  bool myConveyRegionSwitch;
106  bool myConveyProducingFederateSwitch;
107  bool myObjectClassRelevanceAdvisorySwitch;
108  bool myAttributeRelevanceAdvisorySwitch;
109  bool myAttributeScopeAdvisorySwitch;
110  bool myInteractionRelevanceAdvisorySwitch;
111  bool myConveyRegionDesignatorSetsSwitch;
112  bool myServiceReportingSwitch;
113  bool myExceptionReportingSwitch;
114  bool mySendServiceReportsToFileSwitch;
115  DtResignAction myAutomaticResignDirectiveSwitch;
116 
117  /* Shouldn't need these as they are static
118  virtual bool getAdvisoriesUseKnownClassSwitch() const;
119  virtual bool getAllowRelaxedDDMSwitch() const;
120  virtual bool getNonRegulatedGrantSwitch() const;
121  */
122 
123 };
124 
125 inline void DtMomFederatePublisher::checkSwitch(DtAttributeHandleSet& attrSet, bool& pubValue, bool repValue, DtMomElement element)
126 {
127  if (pubValue != repValue)
128  {
129  attrSet.add(myFederateSR->attribute(element));
130  pubValue = repValue;
131  }
132 }
133 
134 #endif
135 #endif
virtual Boolean tick(TickTime minimum, TickTime maximum)
virtual void add(DtAttributeHandle h)
Add new value.
Defines the internal representation of attribute/parameter handle sets.
Definition: attrHandSet.h:30
Instances of DtConnectionMgr manage the communication objects that the RTI will use to either communi...
Definition: connectMgr.h:67
DtHandle DtFederateHandle
Definition: internalTypes.h:46
The object manager class processes the object management services.
Definition: objMgr.h:81
#define DT_DLL_LRC
Definition: rtiMsConfig.h:155
Definition: fomModuleManager.h:39

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)