VR-Forces 4.1.1 Class Documentation
DtVrfSpotReportManager.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2011 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
17 
18 #pragma once
19 
20 #include <vrfGuiCore/vrfGuiCore.h>
24 #include <vrvUtil/signalslib.h>
25 
27 #include <vrvCore/DtEntityState.h>
28 
29 #include <boost/signal.hpp>
30 
31 class DtVrfObjectMessage;
32 
33 namespace makVrv
34 {
35  class DtDe;
36  class DtRecordSettingsBackupInterface;
37  class DtObjectDictionary;
38  class DtSharedSettingsManager;
39  class DtElementDefinitionNew;
40  class DtVisualizerDefinition;
41 }
42 
43 namespace makVrf
44 {
45  class DtSpotReportDataHandlerCreatorInterface;
46  class DtSpotReportVisualHandlerCreatorInterface;
47  class DtVrfSelectionFilter;
48  class DtVrfSpotReportVisualizer;
49 
51 
54  {
55  public:
57  virtual ~DtVrfSpotReportManager();
58 
60  static DtVrfSpotReportManager& instance(makVrv::DtDe& de);
61 
62  void setAutoSave(bool b);
63  bool autoSave() const;
64 
65  virtual void getRecord(DtVrfSpotReportsSettingsRecord& rec) const;
66 
68  virtual void setFromRecord(const DtVrfSpotReportsSettingsRecord& rec);
69 
70  public:
71  //{@
74  void setDisplayReportingName(bool);
75  bool displayReportingName() const;
76 
77  void setDisplayObservedName(bool);
78  bool displayObservedName() const;
79 
80  void setDisplayLastContact(bool);
81  bool displayLastContact() const;
82 
83  void setDisplayLocation(bool);
84  bool displayLocation() const;
85 
86  void setDisplayVelocity(bool);
87  bool displayVelocity() const;
88 
89  void setDisplayHeading(bool);
90  bool displayHeading() const;
91 
92  void setDisplayEntityType(bool);
93  bool displayEntityType() const;
94 
95  void setDisplayHeadingIndicator(bool);
96  bool displayHeadingIndicator() const;
97 
98  void setDisplayVelocityIndicator(bool);
99  bool displayVelocityIndicator() const;
100 
101  void setApplyToEnvironmentals(bool);
102  bool applyToEnvironmentals() const;
103 
104  const std::vector<int>& certaintyLevels() const;
105  void setCertaintyLevels(const std::vector<int>&);
106  void setCertaintyLevel(int level, int time);
107 
111  virtual bool showSpotReportsForForce(int) const;
112  virtual bool showGroundTruthForForce(int) const;
113 
115  virtual void addShowSpotReportFor(int);
116  virtual void removeShowSpotReportFor(int);
117  void setShowSpotReportsForForce(const std::vector<int>&);
118  const std::vector<int> spotReportsFor() const;
119 
120  virtual void addShowGroundTruthFor(int);
121  virtual void removeShowGroundTruthFor(int);
122  void setShowGroundTruthForForce(const std::vector<int>&);
123  const std::vector<int> groundTruthFor() const;
124 
126  virtual void setDisplayFlag(int, bool);
127 
130  virtual void setSpotReportsGloballyEnabled(bool enabled);
131 
135  void setSystemEnabled(bool);
136  bool systemEnabled() const;
138 
139  public:
141  virtual void loadDefaults(bool fromFactory = false);
142 
144  virtual void saveAsDefaults();
145 
146  const makVrv::DtRecordSettingsBackupInterface* settingsBackup() const
147  {
148  return mySettingsBackup;
149  }
150 
152  {
153  return mySettingsBackup;
154  }
155 
157  void exportSettings(const std::string& fileName);
158 
160  void importSettings(const std::string& fileName);
161 
162  virtual void processReceiveSpotReport(const DtVrfObjectMessage* msg);
163 
168  virtual std::string addOrUpdateSpotReport(const std::string& type, void*, const std::string& key = "");
169 
170  public:
173  virtual void addFogOfWarFilter(const DtVrfSelectionFilter&);
174 
177  virtual void removeFogOfWarFilter(const std::string&);
178 
180  virtual bool passesFogOfWarFilters(const makVrv::DtVrlinkSimulatedBaseState*) const;
181 
183  virtual bool blockSignals(bool);
184 
185  public:
188  virtual void addSpotReportDataHandler(const std::string& s, DtSpotReportDataHandlerCreatorInterface*);
189 
190  virtual void removeSpotReportDataHandler(const std::string& s);
191 
193  virtual void setSpotReportsSelectable(bool);
194  virtual bool spotReportsSelectable() const;
195 
196  public:
199  virtual void addSpotReportVisualHandler(const std::string& s, DtSpotReportVisualHandlerCreatorInterface*);
200 
201  virtual void removeSpotReportVisualHandler(const std::string& s);
202 
203  public:
205  boost::signal<void (const DtVrfSpotReportsSettingsRecord&)> signal_spotReportOptionsChanged;
206 
208  boost::signal<void (bool)> signal_spotReportsSelectableChanged;
209 
211  boost::signal<void (DtVrfSpotReportVisualizer*)> signal_spotReportCreated;
212 
213  protected:
216  virtual void constructSpotReportDictionary();
217 
221  virtual bool upgradeFromDictionary(makVrv::DtElementDefinitionTypeManager::ElementDefinitionType dictType,
222  bool force = false);
223 
225  virtual void mergeItemsFrom(const makVrv::DtElementDefinitionNew* source, makVrv::DtElementDefinitionNew* spotReport,
226  const std::vector<int>& supportedSets);
227 
228  virtual bool isUnusedVisualizer(const makVrv::DtVisualizerDefinition*) const;
229 
230  protected:
235 
237  };
238 }

Document ID: Generated on Mon Apr 8 19:24:01 EDT 2013 from SVN revision 125877
Copyright © 2005-2013 VT MÄK. All Rights Reserved (www.mak.com)