MAK RTIspy API Documentation for HLA 1.3
latencyTestMgr.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 2009 MaK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 /*********************************************************************
6 ** $RCSfile: latencyTestMgr.h,v $ $Revision: 1.4 $ $State: Exp $
7 *********************************************************************/
8 
9 #ifndef latencyTestMgr_H_
10 #define latencyTestMgr_H_
11 
14 
15 #include "rtiMsConfig.h"
16 #include "assistantMgr.h"
17 #include "componentMgr.h"
18 #include "assistantInfo.h"
19 
21 class DtRtiAssistantPeer;
31 
35 {
36  Q_OBJECT
37 
38 public:
39 
41  DtAssistantLatencyTestMgr( DtBoost::shared_ptr<DtRtiAssistantServer> server,
42  DtBoost::shared_ptr<DtRtiAssistantPeer> peer,
43  DtAssistantSignalRouter& signalRouter,
44  DtBoost::shared_ptr<DtAssistantComponentMgr> compMgr,
45  DtBoost::shared_ptr<DtAssistantConnectionInfoMgr> connInfoMgr,
46  DtBoost::shared_ptr<DtAssistantFederationsInfoMgr> fedInfoMgr );
47 
49  virtual ~DtAssistantLatencyTestMgr();
50 
51 private:
52 
55 
58 
59 protected:
60 
63 
64 
66  static void processLatencyTestResults( const DtAssistantLatencyReportMsg& msg, void* usr );
67 
69  virtual void processLatencyTestResults(const DtAssistantLatencyReportMsg& msg);
70 
72  static void processTestMgrStatusUpdate( const DtAssistantTestMgrStatusMsg& msg, void* usr );
73 
76  virtual void processTestMgrStatusUpdate( const DtAssistantTestMgrStatusMsg& msg );
77 
79  static void processTestCommand( const DtAssistantChangeLatencyTestModeMsg& msg, void* usr );
80 
82  virtual void processTestCommand( const DtAssistantChangeLatencyTestModeMsg& msg );
83 
85 
87  bool getRtiexecConn( const DtAssistantMsg& msg, DtRtiConnectionInfoDataPair& exec );
88 
90  bool sendLatencyTestCommand( bool runTest, bool continuous, bool shouldHalt,
91  bool observing );
92 
94  bool verifyNewTestCanBeRun();
95 
96 signals:
97 
99  void updateLatencyTestInteractionPeriod( unsigned int );
100 
102  void updateLatencyTestNumInteractions( unsigned int );
103 
105  void updateLatencyTestPayloadBytes( unsigned int );
106 
108  void disableComponentLatencyTest( int );
109 
111  void enableComponentLatencyTest( int );
112 
113 public slots:
114 
117  void processConnectionsUpdate( const DtRtiConnectionAndConfiguration& conns );
118 
120  void processConnectionsRemoval( const DtRtiConnectionAndConfiguration& conns );
121 
123  void showLrcLatencyTestDialog( int id );
124 
126  void showRtiexecLatencyTestDialog( const DtRtiConnectionInfoDataPair&,
127  unsigned int federationHdl, const MAKRti::DtString& federationName,
128  unsigned int federateHdl);
129 
132  void processLatencyTestObserve();
133 
135  void processLatencyTestDismiss();
136 
138  void initiateLatencyTest();
139 
141  void initiateContinuousLatencyTest();
142 
145  void haltContinuousLatencyTest();
146 
148  void renameComponent( const DtAssistantComponentInfo* );
149 
151  void removeLrcComponent( const DtAssistantComponentInfo* );
152 
154  void updateFederateTestStatus( const DtRtiConnectionInfo& conn,
155  const MAKRti::DtString& federationName, unsigned federateHandle );
156 
158  void updateLatencyTestConfig( unsigned int interactionPeriod,
159  unsigned int numInteractions, unsigned int payloadBytes );
160 
161  // Updates the period between latency test interactions
162  void setLatencyTestInteractionPeriod( unsigned int );
163 
164  // Updates the number of interactions per latency test
165  void setLatencyTestNumInteractions( unsigned int );
166 
167  // Updates the size of a latency test interaction payload in bytes
168  void setLatencyTestPayloadBytes( unsigned int );
169 
170 protected:
171 
173  DtBoost::shared_ptr<DtAssistantComponentMgr> myCompMgr;
174 
176  DtBoost::shared_ptr<DtAssistantConnectionInfoMgr> myConnInfoMgr;
177 
179  DtBoost::shared_ptr<DtAssistantFederationsInfoMgr> myFedInfoMgr;
180 
183 
184  typedef std::map< DtRtiConnectionInfo, DtAssistantInfoSet > DtRtiexecToObserversMap;
188 
192 
196 
200 
203  unsigned int myFederationHdl;
204 
207  MAKRti::DtString myFederationName;
208 
211  unsigned int myInitFederateHdl;
212 
214 
215  unsigned int myInteractionPeriod;
216  unsigned int myNumInteractions;
217  unsigned int myPayloadBytes;
219 
220 };
221 
222 #endif

Document ID: Generated on Fri Mar 14 19:08:55 EDT 2014 from SVN revision 137085
Copyright © 2005-2014 VT MÄK Inc. All Rights Reserved (www.mak.com)