![]() |
VR-Forces 4.0.4 Class Documentation
|
A DtSimCommand subclass which specifies a change to the time of day settings in the simulation engine. More...

Public Member Functions | |
| DtChangeTimeOfDayCommand () | |
| default constructor | |
| DtChangeTimeOfDayCommand (const DtString &writeName, DtReaderWriterRegistry *parentRegistry=NULL) | |
| Usual constructor. | |
| DtChangeTimeOfDayCommand (const DtString &writeName, const DtChangeTimeOfDayCommand &orig, DtReaderWriterRegistry *parentRegistry=NULL) | |
| copy constructor | |
| virtual | ~DtChangeTimeOfDayCommand () |
| destructor | |
| DtChangeTimeOfDayCommand & | operator= (const DtChangeTimeOfDayCommand &orig) |
| assignment operator | |
| int | type () const |
| virtual DtSimCommand * | clone (const DtString &name, DtReaderWriterRegistry *parentRegistry=0) const |
| virtual int | netRepSize () const |
| Returns the size in bytes of the network representation of the class. | |
| virtual bool | setFromNet (const char *contentBuffer, unsigned contentSize) |
| Sets mySubsimCommand member from the incoming contentBuffer (cast to type DtNetSimSimCommand). | |
| virtual bool | setToNet () |
| Calls netRep() to create the network buffer. | |
| virtual void | setTimeOfDay (int hour, int minute, double seconds) |
| Another method for setting time of day that takes hours, minutes, and seconds individually. | |
| virtual DtString | stringRep () const |
| Text representation of this command. | |
| virtual void | setTimeOfDay (double secondsPastMidnight) |
| The time of day, represented as the number of seconds past midnight. | |
| virtual double | timeOfDay () const |
| The time of day, represented as the number of seconds past midnight. | |
| virtual void | setTimeOfDayAdvanceSpeed (double secondsPastMidnight) |
| The time of day advance speed. | |
| virtual double | timeOfDayAdvanceSpeed () const |
| The time of day advance speed. | |
| virtual void | setGeneratedByRemoteSetter (bool value) |
| Used internally by VRF. | |
| virtual bool | generatedByRemoteSetter () const |
| Used internally by VRF. | |
Static Public Member Functions | |
| static DtSimCommand * | creator () |
Protected Attributes | |
| DtRwReal | mySecondsPastMidnight |
| DtRwReal | myToDAdvanceSpeed |
| DtRwBoolean | myGeneratedByRemoteSetter |
A DtSimCommand subclass which specifies a change to the time of day settings in the simulation engine.
default constructor
| DtChangeTimeOfDayCommand::DtChangeTimeOfDayCommand | ( | const DtString & | writeName, |
| DtReaderWriterRegistry * | parentRegistry = NULL |
||
| ) |
Usual constructor.
| DtChangeTimeOfDayCommand::DtChangeTimeOfDayCommand | ( | const DtString & | writeName, |
| const DtChangeTimeOfDayCommand & | orig, | ||
| DtReaderWriterRegistry * | parentRegistry = NULL |
||
| ) |
copy constructor
| virtual DtChangeTimeOfDayCommand::~DtChangeTimeOfDayCommand | ( | ) | [virtual] |
destructor
| DtChangeTimeOfDayCommand& DtChangeTimeOfDayCommand::operator= | ( | const DtChangeTimeOfDayCommand & | orig | ) |
assignment operator
| int DtChangeTimeOfDayCommand::type | ( | ) | const [virtual] |
Implements DtSimCommand.
| virtual DtSimCommand* DtChangeTimeOfDayCommand::clone | ( | const DtString & | name, |
| DtReaderWriterRegistry * | parentRegistry = 0 |
||
| ) | const [virtual] |
Implements DtSimCommand.
| virtual int DtChangeTimeOfDayCommand::netRepSize | ( | ) | const [virtual] |
Returns the size in bytes of the network representation of the class.
This is the size in bytes of the DtNetSimSimCommand structure. Derived classes should take into acount the size returned by this class when overriding (they should call down to this class and add the result to their additional size).
Reimplemented from DtSimCommand.
| virtual bool DtChangeTimeOfDayCommand::setFromNet | ( | const char * | contentBuffer, |
| unsigned | contentSize | ||
| ) | [virtual] |
Sets mySubsimCommand member from the incoming contentBuffer (cast to type DtNetSimSimCommand).
Derived classes should call down to this function first, and then extract their own data starting at the location contentBuffer + DtSimCommand::netRepSize().
Reimplemented from DtSimCommand.
| virtual bool DtChangeTimeOfDayCommand::setToNet | ( | ) | [virtual] |
Calls netRep() to create the network buffer.
Casts the resulting myNetRep to type DtNetSimSimCommand*, and then sets the mySubsimCommand member in the DtNetSimSimCommand from mySubsimCommand. Derived classes should call down to the base class version of setToNet() at the start of the function (before doing any processing on the network representation) They can then start to fill in their network data, starting at the location myNetRep + DtSimCommand::netRepSize().
Reimplemented from DtSimCommand.
| virtual void DtChangeTimeOfDayCommand::setTimeOfDay | ( | double | secondsPastMidnight | ) | [virtual] |
The time of day, represented as the number of seconds past midnight.
| virtual double DtChangeTimeOfDayCommand::timeOfDay | ( | ) | const [virtual] |
The time of day, represented as the number of seconds past midnight.
| virtual void DtChangeTimeOfDayCommand::setTimeOfDayAdvanceSpeed | ( | double | secondsPastMidnight | ) | [virtual] |
The time of day advance speed.
| virtual double DtChangeTimeOfDayCommand::timeOfDayAdvanceSpeed | ( | ) | const [virtual] |
The time of day advance speed.
| virtual void DtChangeTimeOfDayCommand::setTimeOfDay | ( | int | hour, |
| int | minute, | ||
| double | seconds | ||
| ) | [virtual] |
Another method for setting time of day that takes hours, minutes, and seconds individually.
| virtual void DtChangeTimeOfDayCommand::setGeneratedByRemoteSetter | ( | bool | value | ) | [virtual] |
Used internally by VRF.
This value is set to true if this command was generated by a VRF Sim engine that is not simulating the time of day, to communicate time of day changes to another sim engine. It defaults to false, and should typically be left as the default.
| virtual bool DtChangeTimeOfDayCommand::generatedByRemoteSetter | ( | ) | const [virtual] |
Used internally by VRF.
This value is set to true if this command was generated by a VRF Sim engine that is not simulating the time of day, to communicate time of day changes to another sim engine. It defaults to false, and should typically be left as the default.
| virtual DtString DtChangeTimeOfDayCommand::stringRep | ( | ) | const [virtual] |
Text representation of this command.
Implements DtSimCommand.
| static DtSimCommand* DtChangeTimeOfDayCommand::creator | ( | ) | [static] |
DtRwReal DtChangeTimeOfDayCommand::myToDAdvanceSpeed [protected] |