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 MAK Technologies, Inc
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 
82  virtual void restoreConstructedDsr();
83 
84 public:
86  static DtStateRepCreator setStateRepCreator(DtStateRepCreator creator);
87  static DtStateRepCreator stateRepCreator();
88 
89 protected:
92 
95 
96 protected:
97 
98  DtDIGuyObjectStateRepository* myConstructedDsr;
99 
100 protected:
102  static DtStateRepCreator theStateRepCreator;
103 };
104 
105 inline DtDIGuyObjectStateRepository* DtReflectedDIGuyObject::dIGuyObjectStateRep() const
106 {
107  return (DtDIGuyObjectStateRepository*) myStateRep;
108 }
109 
110 inline DtDIGuyObjectStateRepository* DtReflectedDIGuyObject::dsr() const
111 {
112  return (DtDIGuyObjectStateRepository*) myStateRep;
113 }
114  #else
115 
116 //In DIS there is no diGuy Object. but in order to keep the state rep creators the same
117 //We are including a dummy class that creates the state Rep.
119 {
120 public:
122  typedef DtDIGuyObjectStateRepository* (*DtStateRepCreator)();
123 
124 public:
126  static DtStateRepCreator setStateRepCreator(DtStateRepCreator creator);
127  static DtStateRepCreator stateRepCreator();
128 
129 protected:
130  static DtStateRepCreator theStateRepCreator;
131 };
132 
133 #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:62
#define DT_DLL_VL
Definition: vlMachineTypes.h:108
DtReflectedObject & operator=(const DtReflectedObject &orig)
assignment operator – not implemented
Definition: reflectedDiGuyObject.h:118
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:31
void * wrapPrev() const
Definition: vlList.h:288
static DtStateRepCreator theStateRepCreator
Definition: reflectedDiGuyObject.h:130

Document ID: Generated on Thu Sep 19 02:12:35 EDT 2024 from SVN revision 269601
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)