MAK RTIspy API Documentation for HLA 1.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
joinConfMsg.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 1998 MaK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 /*********************************************************************
6 ** $RCSfile: joinConfMsg.h,v $ $Revision: 1.19 $ $State: Exp $
7 *********************************************************************/
8 
11 
12 #ifndef DtJoinConfirmMsg_H_
13 #define DtJoinConfirmMsg_H_
14 
15 #include "rtiMsg.h"
16 #include "netRtiMsgHdr.h"
17 #include "netJoinConfMsg.h"
18 #include <vlutil/vlString.h>
19 
20 class DtConnectionMgr;
21 class DtJoinConfirmMsg;
22 typedef void (*DtJoinConfirmCb)(const DtJoinConfirmMsg& inter, void* usr);
23 
25 {
26 public:
27 
29  enum errorCodes {
30  DtNoError = 0,
35  DtUnknownError};
36 
38  DtJoinConfirmMsg(DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
39 
40  DtJoinConfirmMsg( unsigned long sourceIDValue,
41  errorCodes errorCodeValue,
42  DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
43 
45  DtJoinConfirmMsg(const DtNetJoinConfirmMsg* netRepMsg,
46  DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
47 
49  virtual ~DtJoinConfirmMsg();
50 
52  virtual DtRtiMsg* clone(bool copy = true) const;
53 
55  virtual void set( unsigned long sourceIDValue,
56  errorCodes errorCodeValue);
57 
62  virtual unsigned long sourceID() const;
63  virtual void setSourceID(unsigned long sourceIDValue);
64 
67  virtual void setErrorCode( errorCodes errorCodeVal );
68  virtual errorCodes errorCode() const;
69 
71  virtual void printData(DtLogicalTimeFactory* logicalTimeFactory) const;
72 
73 public:
74 
76  static DtRtiMsg* create(const DtNetMsgHeader* initial,
77  DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
78 
80  static DtRtiMsg* create(DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
81 
83  static void addCallback(DtConnectionMgr* conn,
84  DtJoinConfirmCb cb, void* usr, bool isMomCallback=false);
85  static void removeCallback(DtConnectionMgr* conn,
86  DtJoinConfirmCb cb, void* usr, bool isMomCallback=false);
87 
88 protected:
89 
91  virtual DtNetJoinConfirmMsg* netJoinConfirmMsg();
92  virtual const DtNetJoinConfirmMsg* netJoinConfirmMsg() const;
93 
96 
98  virtual int minSize() const;
99 
101  virtual DtJoinConfirmMsg* self() const;
102 };
103 
104 
106 {
107  return const_cast<DtJoinConfirmMsg*>( this );
108 }
109 
110 #endif
111 

Document ID: Generated on Wed Mar 11 20:26:49 EDT 2015 from SVN revision 150939
Copyright © 2005-2015 VT MÄK Inc. All Rights Reserved (www.mak.com)