VR-Forces 4.10 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
timeKeeperPSR.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2004 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 /*******************************************************************************
6 ** $RCSfile: timeKeeperPSR.h,v $ $Revision: 1.2 $ $State: Exp $
7 *******************************************************************************/
8 
9 #ifndef DtTimeKeeperPSR_H_
10 #define DtTimeKeeperPSR_H_
11 
13 #include <readerWriter/rwReal.h>
14 
15 //class DtTimeKeeperPSR:
16 //
17 //This is a sample Process State Repository which has only one value
18 //which is elapsed time. This data will be written to and read from
19 //the OOB file when a scenario checkpoint is saved and loaded.
20 
21 extern const char* TimeKeeperPSRType;
22 
24 {
25 public:
26 
27  //constructor
28  DtTimeKeeperPSR(DtVrfObject* vrfObject,
29  const DtString& rwName = DtString::nullString(),
30  DtReaderWriterRegistry* parentRegistry = 0);
31 
32  //copy constructor
33  DtTimeKeeperPSR(const DtTimeKeeperPSR& orig,
34  const DtString& rwName = DtString::nullString(),
35  DtReaderWriterRegistry* parentRegistry = 0);
36 
37  //destructor
38  virtual ~DtTimeKeeperPSR();
39 
40  //assignment operator
42 
43  //returns a newly created copy of this object
45  const DtString& rwName = DtString::nullString(),
46  DtReaderWriterRegistry* parentRegistry = 0) const;
47 
48  //Returns the string type of this process state repository.
49  virtual DtString type() const;
50 
51  //Get / Set the elapsed time state variable.
52  virtual void setElapsedTime(double time);
53  virtual double elapsedTime() const;
54 
55 public:
56 
57  //Returns a newly created instance of this class.
58  static DtVrfProcessStateRepository* creator (const DtString& rwName,
59  DtVrfObject* vrfObject, DtReaderWriterRegistry* parentRegistry);
60 
61 protected:
62 
64 };
65 
66 #endif
DtVrfObject is used to represent any type of simulated object (entities, aggregate, control objects) in a VR-Forces application.
Definition: vrfObject.h:215
DtTimeKeeperPSR(DtVrfObject *vrfObject, const DtString &rwName=DtString::nullString(), DtReaderWriterRegistry *parentRegistry=0)
static DtVrfProcessStateRepository * creator(const DtString &rwName, DtVrfObject *vrfObject, DtReaderWriterRegistry *parentRegistry)
DtRwReal myElapsedTime
Definition: timeKeeperPSR.h:63
Definition: readerWriterRegistry.h:39
virtual DtVrfProcessStateRepository * clone(const DtString &rwName=DtString::nullString(), DtReaderWriterRegistry *parentRegistry=0) const
virtual void setElapsedTime(double time)
const char * TimeKeeperPSRType
Description: Readable, Writable DtReal (double)
Definition: rwReal.h:27
Class DtVrfProcessStateRepository: Abstract base class for all process state repositories.
Definition: vrfProcessStateRepository.h:43
virtual ~DtTimeKeeperPSR()
DtTimeKeeperPSR & operator=(const DtTimeKeeperPSR &orig)
virtual double elapsedTime() const
virtual DtString type() const
Returns the string type of the repository, as defined in procSRTypes.h.
Definition: timeKeeperPSR.h:23

Document ID: Generated on Tue Sep 21 17:42:52 EDT 2021 from SVN revision 234861
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)