MAK RTIspy API Documentation for HLA 4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
interactMsg.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 1998 MaK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 /*********************************************************************
6 ** $RCSfile: interactMsg.h,v $ $Revision: 1.26 $ $State: Exp $
7 *********************************************************************/
8 
11 
12 #pragma once
13 
14 #include "rtiMsConfig.h"
15 #include "rtiMsg.h"
16 #include "netParms.h"
17 
18 class DtConnectionMgr;
19 class DtInteractionMsg;
20 class DtPhvps;
22 typedef void (*DtInteractionCb)(const DtInteractionMsg& inter, void* usr);
23 
24 
27 {
28 public:
29 
31  DtInteractionMsg(DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
32 
34  virtual ~DtInteractionMsg();
35 
37  virtual void setChannel(unsigned long handleValue);
38  virtual unsigned long channel() const;
39 
41  virtual void setHandle(DtInteractionClassHandle hand) = 0;
42  virtual DtInteractionClassHandle handle() const = 0;
43 
45  virtual void setObjectHandle(DtInteractionClassHandle hand) = 0;
46  virtual DtObjectInstanceHandle objectHandle() const = 0;
47 
49  virtual void setTag(DtRtiApiTagConstRef tag, bool adjustBufferSize = true);
50  virtual DtRtiApiTagConstRef tag() const;
51 
53  virtual void setParams(const DtPhvps& theParameters, bool adjustBufferSize = true);
54 
59  virtual void getParams(DtPhvps& params, bool useMsgMemory,
60  DtInteractionClassInfo const* classInfo=NULL) const;
61 
63  virtual unsigned long numParams() const;
64 
65 public:
66 
68  static void setChannelIncluded(bool includeChannel);
69  static bool channelIncluded();
70 
71 protected:
72 
74  virtual void setTagSize(int size) = 0;
75  virtual int tagSize() const = 0;
76 
78  virtual DtNetU32* channelPtr() const=0;
79 
81  virtual char* tagPtr() = 0;
82 
84  virtual DtNetParams* netParams() = 0;
85 
88  virtual DtNetBigParams* netBigParams() = 0;
89 
92  virtual DtNetParamValue* nextNetParam(char* netParamTail) const;
93 
97  virtual DtNetBigParamValue* nextNetBigParam(char* netParamTail) const;
98 
104  virtual void fillFromNetParams(
105  const DtNetParams* netRepParams,
106  DtPhvps& params,
107  bool useMsgMemory,
108  DtInteractionClassInfo const* classInfo=NULL) const;
109 
116  virtual void fillFromNetBigParams(
117  const DtNetBigParams* netRepParams,
118  DtPhvps& params,
119  bool useMsgMemory,
120  DtInteractionClassInfo const* classInfo=NULL) const;
121 
123  virtual void fillNetParams(
124  const DtPhvps& theParameters,
125  DtNetParams* netRepParams);
127  virtual void fillNetBigParams(
128  const DtPhvps& theParameters,
129  DtNetBigParams* netRepParams);
130 
132  virtual void adjustBufferForParams(const DtPhvps& params);
133 
135  virtual unsigned long sizeNeededForNetParam(unsigned long paramOffset,
136  unsigned long paramSize) const;
137 
139  virtual unsigned long sizeNeededForNetParams(unsigned long paramOffset,
140  const DtPhvps& params) const;
141 
143  virtual int channelFieldSize() const;
144 
146  virtual int tagFieldSize() const;
147 
149  virtual int paramAlignPaddingSize(unsigned long offset) const;
150 
153  virtual DtInteractionMsg* self() const;
154 
155 protected:
156 
161  unsigned long myMaxParamSize;
162 
163 protected:
164  static bool theChannelIncluded;
165 };
166 
167 
169 {
170  return const_cast<DtInteractionMsg*>( this );
171 }
172 
174 {
175  return theChannelIncluded;
176 }
177 
int myParamHdrSize
Definition: interactMsg.h:160
Definition: netParms.h:112
DtRtiApiVariableLengthData * DtRtiApiTagPtr
Definition: rtiApiTypes.h:100
DtRtiApiTagPtr myTag
Definition: interactMsg.h:157
Definition: netParms.h:98
Format for putting interaction parameters into messages.
Definition: netParms.h:22
unsigned long myMaxParamSize
Definition: interactMsg.h:161
int myParamHdrAlignment
Definition: interactMsg.h:158
DtHandle DtInteractionClassHandle
Definition: internalTypes.h:52
DtRtiApiVariableLengthData const & DtRtiApiTagConstRef
Definition: rtiApiTypes.h:98
virtual DtInteractionMsg * self() const
Returns pointer to the serial number in the netMsg.
Definition: interactMsg.h:168
Instances of DtConnectionMgr manage the communication objects that the RTI will use to either communi...
Definition: connectMgr.h:67
DtRtiMsg is the base class for messages between RTI components.
Definition: rtiMsg.h:34
DtHandle DtObjectInstanceHandle
Definition: internalTypes.h:50
void(* DtInteractionCb)(const DtInteractionMsg &inter, void *usr)
Definition: interactMsg.h:22
Definition: netParms.h:61
int myParamListHdrSize
Definition: interactMsg.h:159
static bool theChannelIncluded
Definition: interactMsg.h:164
Definition: intClassInfo.h:40
#define DT_DLL_LRC
Definition: rtiMsConfig.h:155
Definition: pHandValSet.h:38
virtual int tagFieldSize(int encodedLength) const
Returns size of a tag field (including byte alignment adjustment) given the tag&#39;s encoded length...
DtInteractionMsg is a message type that represents an HLA Interaction.
Definition: interactMsg.h:26
static bool channelIncluded()
Definition: interactMsg.h:173

Document ID: Generated on Wed Jul 8 16:20:32 EDT 2026 from SVN revision 291616
Copyright © 2005-2025 MAK Technologies Inc. All Rights Reserved (www.mak.com)