MAK Data Logger API Documentation for HLA
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
lgrDataViewComponent.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 1992-2012 VT MAK
3 ** All rights reserved.
4 ******************************************************************************/
5 
8 
9 #pragma once
10 
11 #include <lgrGui/lgrGui.h>
12 #include <lgrGui/lgrGuiComponent.h>
13 #include <lgrCore/lgrDataViewSet.h>
14 
16 
17 #include <vlutil/vlTime.h>
18 
19 class DtMutex;
20 
21 namespace MAKLogger
22 {
23  class DtLgrGuiModel;
24  class DtProgressiveLineGraph;
25 
27  {
28  Q_OBJECT
29  public:
30 
32  DtLgrDataViewComponent(DtLgrGuiModel& model, const QString& name);
33 
35  virtual ~DtLgrDataViewComponent();
36 
38  virtual void update();
39 
44  virtual double updateTime();
45 
47  virtual QWidget* initialize(QWidget* parent);
48 
50  virtual void activate();
51 
53  virtual void deactivate();
54 
58  virtual DtLgrZoomableWidget* zoomComponent();
59 
61  virtual void updateExportData(DtLgrDataViewSetSP set);
62 
64  virtual void addRunningData(const DtLgrDataViewSet& set);
65 
67  virtual DtLgrDataViewSetSP getExportData();
68 
71  virtual bool getRunningData(DtLgrDataViewSet& outputSet);
72 
74  virtual void reloadFile();
75 
76  virtual QWidget* graph();
77 
78  virtual void enableZoom();
79 
80 
81  public:
82 
83  // When updating last time, slice a bit off so that we don't export a partial of a time increment.
85 
86  // When updating first time, pad with a very small interval to skip over any time already exported.
88 
89  public slots:
90 
92  virtual void reloadFile(QString fileName);
93 
95  virtual void reloadFile(const DtLgrEditorInterface::FileDataOperations& fileOp );
96 
98  virtual void syncRunningData(DtLgrGuiModel&);
99 
101  virtual void syncExpandingData(DtLgrGuiModel&);
102 
103  protected:
104 
106  virtual void syncData();
107 
109  void toggleRunningData(const bool& running);
110 
112  void lastTimeChanged(const DtAbsoluteTime& lastTime);
113 
115  void jumpTimeChanged(const DtAbsoluteTime& jumpTime);
116 
118  void fileExpandingChanged(const bool& isExpanding);
119 
121  void followExportIntervalChanged(const double& interval);
122 
125  void updateCurrentSet(const DtString& exportType);
126 
128  virtual void adjustValue(unsigned long& value, const DtLgrDataViewSet::DataPoint& dataPoint);
129 
131  virtual double updateGraph( const DtLgrDataViewSet& aSet,double firstVisibleTime,
132  double lastVisibleTime);
133 
135  void cancelUpdateCurrentSet(const DtString& exportType);
136 
137  protected:
138 
140 
143  DtMutex* myDataMutex;
144  DtMutex* myRunningMutex;
146 
153 
160 
162 
163  // Only safely accessed via the updateDataAcrossThread and currentDataSet functions.
169 
170  // When file is expanding, the file is exported this amount of time
172 
173  DtClock myClock;
174 
175 
176  protected:
177 
178  static const int Graph_Updates = 0;
179  static const int Graph_Interactions = 1;
180  static const int Graph_Checkpoints = 2;
181 
182  };
183 
184 }
185 
static DtRelativeTime theSliceLast
Definition: lgrDataViewComponent.h:84
DtTime myNextExportTime
Definition: lgrDataViewComponent.h:161
bool myActivatedFlag
Definition: lgrDataViewComponent.h:149
Contains MAKLogger::DtLgrEditorInterface subclass of MAKLogger::DtLgrSystemInterface.
DtTime myExportInterval
Definition: lgrDataViewComponent.h:171
DtMutex * myRunningMutex
Definition: lgrDataViewComponent.h:144
Provides the base interface for Logger Application gui components.
Definition: lgrGuiComponent.h:36
DtAbsoluteTime myJumpTime
Definition: lgrDataViewComponent.h:159
bool myRecording
Definition: lgrDataViewComponent.h:150
Relative Time, an elapsed duration of time, no implied measurement, could be seconds/cycles or ticks ...
Definition: absoluteTime.h:28
A widget which can be zoomed.
Definition: lgrZoomableWidget.h:26
bool myWaitingForDataFlag
Definition: lgrDataViewComponent.h:148
size_t myRunningDataIndex
Definition: lgrDataViewComponent.h:167
DtLgrDataViewSet * myRunningDataSet
Definition: lgrDataViewComponent.h:165
Contains MAKLogger::DtLgrGuiComponent class.
The logger GUI&#39;s model.
Definition: lgrGuiModel.h:56
QWidget * myMainWidget
Definition: lgrDataViewComponent.h:142
DtAbsoluteTime myLastTimeChange
Definition: lgrDataViewComponent.h:156
DtAbsoluteTime myUpdateFirstTime
Definition: lgrDataViewComponent.h:154
DtLgrDataViewSet * myCompleteDataSet
Definition: lgrDataViewComponent.h:166
FileDataOperations
Data operation types.
Definition: lgrEditorInterface.h:36
bool myIsExpanding
Definition: lgrDataViewComponent.h:168
bool myFileLoading
Definition: lgrDataViewComponent.h:151
DtLgrGuiModel * myModel
Definition: lgrDataViewComponent.h:139
static DtRelativeTime thePadFirst
Definition: lgrDataViewComponent.h:87
DtBoost::shared_ptr< DtLgrDataViewSet > DtLgrDataViewSetSP
Definition: lgrDataViewSet.h:24
DtAbsoluteTime myPreviousLastTime
Definition: lgrDataViewComponent.h:158
Definition: lgrDataViewComponent.h:26
Data for a single data point.
Definition: lgrDataViewSet.h:35
DtMutex * myDataMutex
Definition: lgrDataViewComponent.h:143
DtClock myClock
Definition: lgrDataViewComponent.h:173
#define DT_DLL_LGRGUI
Definition: lgrGui.h:19
DtString myExporteraName
Definition: lgrDataViewComponent.h:145
DtAbsoluteTime myPreviousFirstTime
Definition: lgrDataViewComponent.h:157
DtLgrDataViewSetSP myExportedDataSet
Definition: lgrDataViewComponent.h:164
Widget which draws a line graphic where the data is progressively added over time.
Definition: progressiveLineGraph.h:32
Contains MAKLogger::DtLgrDataViewSet class.
DtProgressiveLineGraph * myGraph
Definition: lgrDataViewComponent.h:141
Defines INPORT/EXPORT macros for lgrGui library.
Collection of data values sorted by time used for data views.
Definition: lgrDataViewSet.h:30
DtAbsoluteTime myUpdateLastTime
Definition: lgrDataViewComponent.h:155
bool myDataOutOfSyncFlag
Definition: lgrDataViewComponent.h:147
bool myJumpPending
Definition: lgrDataViewComponent.h:152
Absolute Time, a particular measured instance in time, could be thought of as a set of relative times...
Definition: absoluteTime.h:82

Document ID: Generated on Mon Mar 22 15:30:17 EDT 2021 from SVN revision 226440
Copyright © 2021 MAK Technologies. All Rights Reserved (www.mak.com)