MAK RTIspy API Documentation for HLA 1.3
rtiExecConnectionState.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 2006 MaK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 /*********************************************************************
6 ** $RCSfile: rtiExecConnectionState.h,v $ $Revision: 1.6 $ $State: Exp $
7 *********************************************************************/
10 
11 #ifndef DtRtiExecConnectionState22_H_
12 #define DtRtiExecConnectionState22_H_
13 
14 #include <vlutil/vlList.h>
15 #include <vlutil/vlString.h>
16 #include <list>
17 #include "rtiMsConfig.h"
18 #include <assert.h>
19 #include <vlutil/vlPrint.h>
20 #include <vlutil/vlTime.h>
21 
22 class DtTcpMsgSocket;
23 
24 //Singleton Class.
25 //Container class for connection information/status about the rtiExec.
27 {
28 private:
29 
32  DtRtiExecConnectionState& operator=(const DtRtiExecConnectionState& orig);
33 
34 public:
35 
50 
52  {
56  DtReconnectFailed
57  };
58 
59  //Creation and destruction
60  DtRtiExecConnectionState(bool reconnectEnabled, MAKRti::DtTime rtiExecReconnectTimeout);
62 
64  unsigned int rtiExecConnID() const;
65 
68  const DtTcpMsgSocket* rtiExecSock() const;
69 
71  bool rtiExecAvailable() const;
72 
74  bool rtiExecIsLocalConnection() const;
75 
78  bool noConnectionAvailable() const;
79 
81  bool isWaitingForReconnect() const;
82 
83  //rather than storing a DtRidParameters object in its entirety, we simply store the one
85  bool reconnectEnabled() const;
86 
90  bool hasTimeElapsed() const;
91 
95  void resetRtiExecConnID();
96 
98  MAKRti::DtString hostName() const;
99 
100  //State transition functions, filter will notify us of events and we'll respond appropriately.
101 
102  bool rtiExecTimedOutReconnect();
103 
104  bool rtiExecDisconnected();
105 
106  bool rtiExecDisconnectMsgReceived();
107 
108  bool rtiExecConnected(unsigned int newConnectionID,
109  const DtTcpMsgSocket* execSock,
110  const MAKRti::DtString& hostName );
111 
112  bool rtiExecReconnected(unsigned int newConnectionID,
113  const DtTcpMsgSocket* execSock,
114  const MAKRti::DtString& hostName );
115 
118  bool testRtiExecConnectionStatus();
119 
120 protected:
121 
126  //void setRtiExecConnID(unsigned int newConnectionID);
127 
128 
129 
130 protected:
133  unsigned int myRtiExecConnID;
138  MAKRti::DtClock myTimer;
139  MAKRti::DtClock myPingTimer;
140  MAKRti::DtString myExecHostname;
141 
142 };
143 
144 
145 
146 #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)