MAK Data Logger API Documentation for HLA
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
lgrRecordInterface.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 1992-2010 VT MAK
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #ifndef lgrRecordInterface_H_
11 #define lgrRecordInterface_H_
12 
13 #include "lgrTimeInterface.h"
14 #include <lgrUtil/absoluteTime.h>
15 #include "lgrCheckpointPolicy.h"
16 #include <vlutil/vlString.h>
17 
18 namespace MAKLogger
19 {
20 
21  class DtLogger;
22  class DtLgrRecordDriver;
23  class DtLgrRecordCommandFactory;
24 
29  {
30 
31  public:
32 
34 
37  static DtLgrRecordInterface* create(DtLogger&);
38 
41  static DtLgrRecordInterface* createNonThreadsafe(DtLogger& logger,
42  const DtLgrRecordDriver& driver);
43 
44  protected:
45 
47  DtLgrRecordInterface(DtLogger& logger,const DtLgrRecordDriver& driver);
48 
49 
50  public:
51  virtual ~DtLgrRecordInterface();
52 
54  virtual void startNewFile(const DtString& filename, const DtString& description, bool overwrite) const;
55 
57  virtual void recordToMultipleFiles(const DtString& filename, const DtString& description) const;
58 
61  virtual void closeFile() const;
62 
65  {
73  StopOnDurationOrSize
74  };
75 
77  virtual void setStopCondition(StopCondition,bool close) const;
78 
82  virtual void setStopDuration(DtRelativeTime duration) const;
83 
87  virtual void setStopSize(DtU64 filesize) const;
88 
90  virtual void setPauseOnRecordAs(bool record) const;
91 
93  virtual bool isFileLoaded() const;
94 
96  virtual bool isFileEmpty() const;
97 
99  virtual const DtString& filename() const;
100 
102  virtual bool isRecording() const;
103 
105  virtual bool isPaused() const;
106 
108  virtual bool isStopped() const;
109 
111  virtual bool pauseOnRecordAs() const;
112 
114  virtual void record() const;
115 
117  virtual void pause() const;
118 
120  virtual void unpause() const;
121 
123  virtual void stop(bool closeAndOpenForPlayback) const;
124 
126  virtual void setCheckpointParameters(DtCheckpointPolicy::Policy policy,
127  int size,int count,DtAbsoluteTime time, bool checkpointInteractions) const;
128 
130  virtual void cancelRecording() const;
131 
134  virtual void saveRecordedData(const DtString& filename, const DtString& description,
135  bool onlySinceLastSaveData, double outputDuration) const;
136 
138  virtual void setRecordToMultipleFilesSettings(double duration,
139  const DtString& namingConvention) const;
140 
142  int checkpointPolicyId() const;
143 
145  int checkpointCount() const;
146 
148  int checkpointSize() const;
149 
151  DtAbsoluteTime checkpointTime() const;
152 
154  bool interactionsCheckpointed() const;
155 
157  double multipleFileDuration() const;
158 
160  const DtString& multipleFileNamingConvention() const;
161 
163  void newFileOpened(DtResponse);
164  void newFileFailed(DtResponse);
165  void newFileClosed(DtResponse);
166  void recordingChanged(DtResponse);
167  void recordingPausedChanged(DtResponse);
168  void pauseOnRecordAsChanged(DtResponse);
169  void checkpointParametersChanged(DtResponse);
170  void fileEmptyChanged(DtResponse);
171  void recordToMultipleFilesChanged(DtResponse);
172 
178 
179  protected:
180 
181  void connectResponseHandler(DtLgrCommandId id,
182  void (DtLgrRecordInterface::* function)(DtResponse));
183 
196 
199 
200  };
201 
202 }
203 
204 #endif

Document ID: Generated on Thu Apr 7 20:50:59 EDT 2016 from SVN revision 163818
Copyright © 2005-2012 VT MÄK. All Rights Reserved (www.mak.com)