cmlabs::CommunicationRecorder Class Reference

#include <CommunicationRecorder.h>

Inheritance diagram for cmlabs::CommunicationRecorder:

Inheritance graph
[legend]
Collaboration diagram for cmlabs::CommunicationRecorder:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 CommunicationRecorder (const JString &storage, bool overwrite=false)
virtual ~CommunicationRecorder ()
Objectclone () const
bool unitTest ()
bool initReading ()
bool initWriting ()
void run ()
bool setNewStorageLocation (const JString &storage)
bool startRecording ()
bool pauseRecording ()
bool restartRecording ()
bool startPlayback ()
bool pausePlayback ()
bool restartPlayback ()
long getCurrentOffset ()
JTime getStartTime ()
JTime calcOriginalTime (const JTime &time)
JTime calcCurrentTime (const JTime &originalTime)
int getMessageCount ()
int getSampleCount ()
JTime getFirstMessageTime ()
JTime getLastMessageTime ()
JTime getFirstSampleTime ()
JTime getLastSampleTime ()
long getFirstMessageOffset ()
long getLastMessageOffset ()
long getFirstSampleOffset ()
long getLastSampleOffset ()
bool addNewMessage (Message *msg)
bool addNewSample (DataSample *sample)
MessageretrieveMessage (int n)
DataSampleretrieveSample (int n)
MessageretrieveNextMessage (const JTime &time)
DataSampleretrieveNextSample (const JTime &time)
bool finishWriting (int timeout)
bool isInitialised ()
bool isWriter ()
bool isReader ()
bool isPaused ()
bool wasReset ()

Static Public Member Functions

static InfoItemgetRecordingInfo (const JString &storage)
static InfoItemgetIndexFileInfo (const JString &location, const JString &indexfile)

Private Member Functions

bool saveSegment (int start, int end)
bool loadSegment (int start, int end)
MessageloadMessage (const JString &filename)
DataSampleloadSample (const JString &filename)
bool saveMessage (const JString &filename, Message *msg)
bool saveSample (const JString &filename, DataSample *sample)
bool saveIndexFile ()
bool loadIndexFile ()

Private Attributes

bool resetFlag
bool paused
bool shouldContinue
bool overwriteRecording
JString storage
JString indexFilename
int accessType
int masterOffset
JTime originalStartTime
JTime currentStartTime
ObjectQueue msgQueue
ObjectQueue sampleQueue
ObjectTable storedMessageIndex
ObjectTable storedSampleIndex
int preloadStartIndex
int preloadEndIndex
int lastMsgIndex
int lastSampleIndex


Detailed Description

Definition at line 47 of file CommunicationRecorder.h.


Constructor & Destructor Documentation

cmlabs::CommunicationRecorder::CommunicationRecorder ( const JString storage,
bool  overwrite = false 
)

Definition at line 33 of file CommunicationRecorder.cpp.

cmlabs::CommunicationRecorder::~CommunicationRecorder (  )  [virtual]

Definition at line 49 of file CommunicationRecorder.cpp.


Member Function Documentation

InfoItem * cmlabs::CommunicationRecorder::getRecordingInfo ( const JString storage  )  [static]

Definition at line 72 of file CommunicationRecorder.cpp.

InfoItem * cmlabs::CommunicationRecorder::getIndexFileInfo ( const JString location,
const JString indexfile 
) [static]

Definition at line 505 of file CommunicationRecorder.cpp.

Object * cmlabs::CommunicationRecorder::clone (  )  const [virtual]

Implements cmlabs::Object.

Definition at line 56 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::unitTest (  ) 

Reimplemented from cmlabs::JThread.

Definition at line 555 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::initReading (  ) 

Definition at line 60 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::initWriting (  ) 

Definition at line 97 of file CommunicationRecorder.cpp.

void cmlabs::CommunicationRecorder::run (  )  [virtual]

Reimplemented from cmlabs::JThread.

Definition at line 127 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::setNewStorageLocation ( const JString storage  ) 

Definition at line 193 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::startRecording (  ) 

Definition at line 208 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::pauseRecording (  ) 

Definition at line 213 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::restartRecording (  ) 

Definition at line 218 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::startPlayback (  ) 

Definition at line 226 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::pausePlayback (  ) 

Definition at line 231 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::restartPlayback (  ) 

Definition at line 236 of file CommunicationRecorder.cpp.

long cmlabs::CommunicationRecorder::getCurrentOffset (  ) 

Definition at line 246 of file CommunicationRecorder.cpp.

JTime cmlabs::CommunicationRecorder::getStartTime (  ) 

Reimplemented from cmlabs::JThread.

Definition at line 250 of file CommunicationRecorder.cpp.

JTime cmlabs::CommunicationRecorder::calcOriginalTime ( const JTime time  ) 

Definition at line 254 of file CommunicationRecorder.cpp.

JTime cmlabs::CommunicationRecorder::calcCurrentTime ( const JTime originalTime  ) 

Definition at line 258 of file CommunicationRecorder.cpp.

int cmlabs::CommunicationRecorder::getMessageCount (  ) 

Definition at line 262 of file CommunicationRecorder.cpp.

int cmlabs::CommunicationRecorder::getSampleCount (  ) 

Definition at line 266 of file CommunicationRecorder.cpp.

JTime cmlabs::CommunicationRecorder::getFirstMessageTime (  ) 

Definition at line 270 of file CommunicationRecorder.cpp.

JTime cmlabs::CommunicationRecorder::getLastMessageTime (  ) 

Definition at line 275 of file CommunicationRecorder.cpp.

JTime cmlabs::CommunicationRecorder::getFirstSampleTime (  ) 

Definition at line 280 of file CommunicationRecorder.cpp.

JTime cmlabs::CommunicationRecorder::getLastSampleTime (  ) 

Definition at line 285 of file CommunicationRecorder.cpp.

long cmlabs::CommunicationRecorder::getFirstMessageOffset (  ) 

Definition at line 290 of file CommunicationRecorder.cpp.

long cmlabs::CommunicationRecorder::getLastMessageOffset (  ) 

Definition at line 295 of file CommunicationRecorder.cpp.

long cmlabs::CommunicationRecorder::getFirstSampleOffset (  ) 

Definition at line 300 of file CommunicationRecorder.cpp.

long cmlabs::CommunicationRecorder::getLastSampleOffset (  ) 

Definition at line 305 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::addNewMessage ( Message msg  ) 

Definition at line 311 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::addNewSample ( DataSample sample  ) 

Definition at line 318 of file CommunicationRecorder.cpp.

Message * cmlabs::CommunicationRecorder::retrieveMessage ( int  n  ) 

Definition at line 326 of file CommunicationRecorder.cpp.

DataSample * cmlabs::CommunicationRecorder::retrieveSample ( int  n  ) 

Definition at line 330 of file CommunicationRecorder.cpp.

Message * cmlabs::CommunicationRecorder::retrieveNextMessage ( const JTime time  ) 

Definition at line 334 of file CommunicationRecorder.cpp.

DataSample * cmlabs::CommunicationRecorder::retrieveNextSample ( const JTime time  ) 

Definition at line 339 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::finishWriting ( int  timeout  ) 

Definition at line 480 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::isInitialised (  ) 

Definition at line 179 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::isWriter (  ) 

Definition at line 183 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::isReader (  ) 

Definition at line 187 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::isPaused (  ) 

Definition at line 175 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::wasReset (  ) 

Definition at line 168 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::saveSegment ( int  start,
int  end 
) [private]

Definition at line 352 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::loadSegment ( int  start,
int  end 
) [private]

Definition at line 356 of file CommunicationRecorder.cpp.

Message * cmlabs::CommunicationRecorder::loadMessage ( const JString filename  )  [private]

Definition at line 363 of file CommunicationRecorder.cpp.

DataSample * cmlabs::CommunicationRecorder::loadSample ( const JString filename  )  [private]

Definition at line 397 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::saveMessage ( const JString filename,
Message msg 
) [private]

Definition at line 423 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::saveSample ( const JString filename,
DataSample sample 
) [private]

Definition at line 463 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::saveIndexFile (  )  [private]

Definition at line 496 of file CommunicationRecorder.cpp.

bool cmlabs::CommunicationRecorder::loadIndexFile (  )  [private]

Definition at line 531 of file CommunicationRecorder.cpp.


Member Data Documentation

Definition at line 124 of file CommunicationRecorder.h.

Definition at line 125 of file CommunicationRecorder.h.

Definition at line 126 of file CommunicationRecorder.h.

Definition at line 127 of file CommunicationRecorder.h.

Definition at line 128 of file CommunicationRecorder.h.

Definition at line 129 of file CommunicationRecorder.h.

Definition at line 130 of file CommunicationRecorder.h.

Definition at line 131 of file CommunicationRecorder.h.

Definition at line 133 of file CommunicationRecorder.h.

Definition at line 134 of file CommunicationRecorder.h.

Definition at line 136 of file CommunicationRecorder.h.

Definition at line 137 of file CommunicationRecorder.h.

Definition at line 139 of file CommunicationRecorder.h.

Definition at line 140 of file CommunicationRecorder.h.

Definition at line 141 of file CommunicationRecorder.h.

Definition at line 142 of file CommunicationRecorder.h.

Definition at line 143 of file CommunicationRecorder.h.

Definition at line 144 of file CommunicationRecorder.h.


The documentation for this class was generated from the following files:

Generated on Tue Jul 7 16:22:37 2009 for CoreLibrary by  doxygen 1.5.6