VR-Link API Documentation for DIS
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
reflectedIffListDIS.h
Go to the documentation of this file.
1 /****************************************************************************
2  * Copyright (c) 2014 VT MAK
3  * All rights reserved.
4  ****************************************************************************/
5 
9 
10 #pragma once
11 
12 #if DtDIS
13 
14 
15 #include "reflectedObjectListDIS.h"
16 #include "reflectedIffDIS.h"
17 #include "globalObjectDesignator.h"
18 #include "vl/iffSystemHashKey.h"
19 #include <list>
20 
21 
22 class DtIffAtcNavaidsPdu;
23 
24 
29 {
30 
31 public:
32 
34  DtReflectedIffList(DtExerciseConn* exConn, int numBucketsPrimeNumber = 503);
35 
37  virtual ~DtReflectedIffList();
38 
40  virtual DtReflectedIff* lookup(
41  const DtGlobalObjectDesignator& emittingEntity,
42  DtU16 systemType, DtU16 systemName, DtU8 systemDesignator) const;
43 
46  virtual DtReflectedIff* lookup(
47  const DtGlobalObjectDesignator& emittingEntity) const;
48 
50  virtual DtReflectedIff* first() const;
51  virtual DtReflectedIff* last() const;
52 
54  virtual void addIffAdditionCallback(
55  DtIffCallbackFunction cb, void* userData);
56  virtual void removeIffAdditionCallback(
57  DtIffCallbackFunction cb, void* userData);
58 
60  virtual void addEmitterAdditionCallback(
61  DtIffCallbackFunction cb, void* userData);
63  virtual void removeEmitterAdditionCallback(
64  DtIffCallbackFunction cb, void* userData);
65 
67  virtual void addIffRemovalCallback(
68  DtIffCallbackFunction cb, void* userData);
69  virtual void removeIffRemovalCallback(
70  DtIffCallbackFunction cb, void* userData);
71 
73  virtual void addEmitterRemovalCallback(
74  DtIffCallbackFunction cb, void* userData);
76  virtual void removeEmitterRemovalCallback(
77  DtIffCallbackFunction cb, void* userData);
78 
80  virtual void print();
81 
82 protected:
83 
86  const DtReflectedIffList& orig);
87 
90 
91 protected:
92 
94  virtual DtReflectedIff* newReflectedIff(
95  const DtGlobalObjectDesignator& emittingEntity,
96  DtU16 systemType, DtU16 systemName, DtU8 systemDesignator);
97 
99  virtual DtReflectedObject* newReflectedObj(const DtStateMsg& msg);
100 
102  virtual DtReflectedObject* processStateMessage(const DtStateMsg& msg);
103 
106  virtual void objectAdded(DtReflectedObject* obj);
107 
109  virtual const DtBaseHashKey&
111 
114  virtual void removeAndDelete(DtReflectedObject* obj,
115  char* msg = NULL);
116 protected:
117 
119  static void emIffCb(DtIffAtcNavaidsPdu* pdu, void* usr);
120 
122  std::map<const DtGlobalObjectDesignator, std::list<DtIFFSystemHashKey> > myIffHashMap;
123 
124 };
125 
126 #endif
127 
128 
virtual void print() const
Print the SRs of all objects.
Instances of DtReflectedObjectList are lists of instances of classes derived from DtReflectedObject...
Definition: reflectedObjectListDIS.h:38
std::map< const DtGlobalObjectDesignator, std::list< DtIFFSystemHashKey > > myIffHashMap
Definition: reflectedIffListDIS.h:122
Instances of DtReflectedIff represent Iff object simulated by remote applications.
Definition: reflectedIffDIS.h:34
Instances of DtExerciseConn are used to provide an application&#39;s interface or connection to the netwo...
Definition: exerciseConnDIS.h:61
virtual const DtBaseHashKey & hashKeyFromStateMessage(const DtStateMsg *msg)=0
Get a hash key from a state message.
#define DT_DLL_VL
Definition: vlMachineTypes.h:108
DtBaseHashKey is an abstract base class for hash keys.
Definition: vlHashKeys.h:39
This file contains typedefs used to represent objects in a protocol neutral way.
Instances of DtIffAtcNavaidsPdu are used to send information about simulated radio transponders and i...
Definition: iffAtcNavaidsPdu.h:48
DtReflectedObjectList & operator=(const DtReflectedObjectList &orig)
assignment operator – not implemented
Instances of DtReflectedObject are used to represent a simulation entity reflected across a network (...
Definition: reflectedObjectDIS.h:34
unsigned char DtU8
An eight bit unsigned integer value.
Definition: vlMachineTypes.h:137
Instances of DtIFFSystemHashKey are used as hash keys for an emitter system.
Definition: iffSystemHashKey.h:17
Instances of DtEntityIdentifier are used as a unique ID for entities in DIS.
Definition: entityIdentifier.h:31
virtual void removeAndDelete(DtReflectedObject *obj, char *msg=NULL)
Remove the remote object from the list if found and delete it.
virtual DtReflectedObject * newReflectedObj(const DtStateMsg &msg)=0
Create a new object from a state message.
Instances of this class provide a protocol independent interface to a list of reflected emitters in a...
Definition: reflectedIffListDIS.h:28
virtual void objectAdded(DtReflectedObject *object)
Called after a remote object has been added to the list.
unsigned short DtU16
A 16 bit unsigned integer value.
Definition: vlMachineTypes.h:140
void(* DtIffCallbackFunction)(DtReflectedIff *obj, void *userData)
Callback function that takes a DtReflectedObject and user data.
Definition: reflectedIffDIS.h:26
DtIFFSystemHashKey myHashKey
Definition: reflectedIffListDIS.h:121
Instances of DtStateMsg are used to represent state data communicated via the network in a DIS (as op...
Definition: stateMsgDIS.h:21
virtual DtReflectedObject * processStateMessage(const DtStateMsg &msg)
Process an incoming state message.

Document ID: Generated on Mon Apr 25 03:39:01 EDT 2022 from SVN revision 242502
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)