VR-Forces 4.1.1 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
examples
addSimCommand
addSimCommandSim
mySimCommand.h
Go to the documentation of this file.
1
/*******************************************************************************
2
** Copyright (c) 2006 MAK Technologies, Inc.
3
** All rights reserved.
4
*******************************************************************************/
5
6
7
//\file consoleMessageCommand.h
8
//\brief DtConsoleMessageCommand.
9
10
#pragma once
11
12
#include "
vrfplan/simCommand.h
"
13
#include "
vrfutil/rwString.h
"
14
#include <vlutil/vlPrint.h>
15
#include "
vrftasks/radioMsgTypes.h
"
16
17
const
DtSimCommandMessageType
MySimCommandType
=
DtString
(
"my-sim-command"
);
18
19
//\brief DtSimCommand which causes a console message to be printed.
20
//This command will simply print a message to the back-end console
21
22
class
MySimCommand
:
public
DtSimCommand
23
{
24
public
:
25
//Default constructor
26
MySimCommand
();
27
28
//Usual constructor
29
MySimCommand
(
const
DtString
& writeName,
30
DtReaderWriterRegistry
* parentRegistry = NULL);
31
32
//copy constructor
33
MySimCommand
(
const
DtString
& writeName,
const
MySimCommand
& orig,
34
DtReaderWriterRegistry
* parentRegistry = NULL);
35
36
//destructor
37
virtual
~MySimCommand
();
38
39
//assignment operator
40
MySimCommand
&
operator=
(
const
MySimCommand
& orig);
41
42
//\return MySimCommandType.
43
const
DtSimCommandMessageType
&
type
()
const
;
44
45
//\return A new instance of this class, copied from the original.
46
virtual
DtSimCommand
*
clone
(
const
DtString
&
name
,
DtReaderWriterRegistry
*
47
parentRegistry = 0)
const
;
48
49
//Message to print to console
51
virtual
DtString
messageText
()
const
;
52
virtual
void
setMessageText
(
const
DtString
& text);
54
55
//Text representation of this command.
56
virtual
DtString
stringRep
()
const
;
57
58
//\copydoc DtSimCommand::netRepSize()
59
virtual
int
netRepSize
()
const
;
60
61
//\copydoc DtSimCommand::setFromNet()
62
virtual
bool
setFromNet
(
const
char
* contentBuffer,
63
unsigned
contentSize);
64
65
//\copydoc DtSimCommand::setToNet()
66
virtual
bool
setToNet
();
67
68
//Returns a new instance of this class.
69
static
DtSimCommand
*
creator
();
70
71
protected
:
72
DtRwString
myMessageText
;
73
};
74
Document ID: Generated on Mon Apr 8 19:24:01 EDT 2013 from SVN revision 125877
Copyright © 2005-2013 VT MÄK. All Rights Reserved (
www.mak.com
)