VR-Link API Documentation for DIS
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
reflectedDiGuyObject.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 1992-2013 VT MAK
3 ** All rights reserved.
4 *********************************************************************/
5 
9 
10 #pragma once
11 
13 
14 #if DtHLA
15 
16 #include <vl/reflectedObjectHLA.h>
17 
18 
20 
24 typedef void (*DtDIGuyObjectCallbackFunction)(
25  DtReflectedDIGuyObject* obj, void* userData);
26 
32 {
33 public:
36  typedef DtDIGuyObjectStateRepository* (*DtStateRepCreator)();
37 
38 public:
40  DtReflectedDIGuyObject(DtHlaObject* obj, DtExerciseConn* exConn);
41 
43  virtual ~DtReflectedDIGuyObject();
44 
46  virtual DtDIGuyObjectStateRepository* dIGuyObjectStateRep() const;
47 
49  virtual DtDIGuyObjectStateRepository* dsr() const;
50 
53  virtual void setDsr(DtDIGuyObjectStateRepository* newDsr);
54 
57  virtual DtReflectedDIGuyObject* next() const;
58 
61  virtual DtReflectedDIGuyObject* prev() const;
62 
65  virtual DtReflectedDIGuyObject* wrapNext() const;
66 
69  virtual DtReflectedDIGuyObject* wrapPrev() const;
70 
73  virtual void addPostUpdateCallback(
74  DtDIGuyObjectCallbackFunction cb, void* userData);
75 
78  virtual void removePostUpdateCallback(
79  DtDIGuyObjectCallbackFunction cb, void* userData);
80 
81 public:
83  static DtStateRepCreator setStateRepCreator(DtStateRepCreator creator);
84  static DtStateRepCreator stateRepCreator();
85 
86 protected:
89 
92 
93 protected:
94 
95  DtDIGuyObjectStateRepository* myConstructedDsr;
96 
97 protected:
99  static DtStateRepCreator theStateRepCreator;
100 };
101 
102 inline DtDIGuyObjectStateRepository* DtReflectedDIGuyObject::dIGuyObjectStateRep() const
103 {
104  return (DtDIGuyObjectStateRepository*) myStateRep;
105 }
106 
107 inline DtDIGuyObjectStateRepository* DtReflectedDIGuyObject::dsr() const
108 {
109  return (DtDIGuyObjectStateRepository*) myStateRep;
110 }
111  #else
112 
113 //In DIS there is no diGuy Object. but in order to keep the state rep creators the same
114 //We are including a dummy class that creates the state Rep.
116 {
117 public:
119  typedef DtDIGuyObjectStateRepository* (*DtStateRepCreator)();
120 
121 public:
123  static DtStateRepCreator setStateRepCreator(DtStateRepCreator creator);
124  static DtStateRepCreator stateRepCreator();
125 
126 protected:
127  static DtStateRepCreator theStateRepCreator;
128 };
129 
130 #endif
Contains the DtDIGuyObjectStateRepository class declaration.
void * next() const
Return next (previous) elements on the list, or NULL if hit the end (beginning) of the list...
Definition: vlList.h:272
Instances of DtExerciseConn are used to provide an application&#39;s interface or connection to the netwo...
Definition: exerciseConnDIS.h:61
#define DT_DLL_VL
Definition: vlMachineTypes.h:108
DtReflectedObject & operator=(const DtReflectedObject &orig)
assignment operator – not implemented
Definition: reflectedDiGuyObject.h:115
Instances of DtReflectedObject are used to represent a simulation entity reflected across a network (...
Definition: reflectedObjectDIS.h:34
void * prev() const
Definition: vlList.h:277
void * wrapNext() const
Return next (previous) elements on the list, but wrap to the beginning (end) of the list when you hit...
Definition: vlList.h:282
Instances of DtDIGuyObjectStateRepository are used to store state data for DIGuyObject objects...
Definition: diGuyObjectStateRepository.h:27
void * wrapPrev() const
Definition: vlList.h:288
static DtStateRepCreator theStateRepCreator
Definition: reflectedDiGuyObject.h:127

Document ID: Generated on Tue Aug 10 00:12:31 EDT 2021 from SVN revision 232765
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)