VR-Forces 4.2 Class Documentation
spotReportGenerator.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2005 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
11 #pragma once
12 
13 #include "vrfobjcore/cntrlCmpnt.h"
15 #include <list>
17 #include "vrftasks/radioMsgTypes.h"
18 
24 class DtSpotReport;
25 class DtSimMessage;
26 class DtVrfObjectMessage;
27 class DtSettingsObject;
28 class DtBoolSetting;
29 
48 {
49 private:
57 public:
58 
62  DtSimManager* simManager, DtComponentDescriptor* desc=0,
63  DtReaderWriterRegistry *parentRegistry=0);
64 
67 
71  virtual bool init();
72 
75  virtual DtString type() const;
76 
80  virtual void tick();
81 
83  static void setSpotReportingCallback(DtSimMessage * msg, void * usr);
84 
85  virtual void processSetSpotReporting(DtSimMessage * msg);
86 
90  virtual void setLocalEnabled(bool on);
91 
99  virtual void setGlobalEnabledOverridingLocal();
100 
104  static DtSimComponent * creator(const DtString& name,
105  DtVrfObject* owner,
106  DtSimManager* simManager,
107  DtComponentDescriptor* desc = 0,
108  DtReaderWriterRegistry* parentRegistry = 0);
109 
110 protected:
111 
116  virtual void turnSpotReportingOn();
117  virtual void turnSpotReportingOff();
119 
121  virtual bool createPorts();
122 
128  virtual bool createPSR();
129 
131  virtual void registerRadioMessageCallbacks();
132 
143  virtual void generateAndSendSpotReports();
144 
152  virtual bool isTypeAndForceForReport(
153  DtRwSensorContactInfo* contact);
154 
159  virtual DtSpotReport* createSpotReportForContact(
160  const DtRwSensorContactInfo& contactInfo);
161 
163  virtual void updateSpotReportForContact(DtSpotReport& spotReport,
164  const DtRwSensorContactInfo& contact);
165 
170  virtual void sendSpotReport(DtSpotReport& spotReport, bool superiorOnly);
171 
177  virtual bool spotReportNeedsUpdateAndResend(const DtSpotReport& spotRep,
178  const DtRwSensorContactInfo& contact);
179 
186  virtual const DtSimReportMessageType& spotReportTypeString() const;
187 
191  static void settingConsumerCallback(const DtSettingsObject* settingsObject,
192  void* usr);
195  virtual void readGlobalEnabledSetting(const DtBoolSetting* enabledSetting);
196 
199 
200  static void hostilitiesChangedCallback(DtU8 force, void* usr);
201  virtual void processHostilitiesChanged(DtU8 force);
203 
208  virtual bool reportingEnabled() const;
209 
210 protected:
211 
220 
221 
222 
223 
224 
225 
226 
229 
232 
236 
239 
243 
247 };
248 

Document ID: Generated on Sun Nov 24 19:49:21 EST 2013 from SVN revision 133924
Copyright © 2005-2013 VT MÄK. All Rights Reserved (www.mak.com)