VR-Forces 4.1.1 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
include
vrfmodel
systemSwitcher.h
Go to the documentation of this file.
1
/*******************************************************************************
2
** Copyright (c) 2012 MAK Technologies, Inc.
3
** All rights reserved.
4
*******************************************************************************/
5
10
13
14
#pragma once
15
16
#include "
vrfobjcore/singleTaskControllerComponent.h
"
17
#include "
vrfobjcore/simRadio.h
"
18
19
class
DtComponentSystem
;
20
class
DtSwitchSystemComponentPSR
;
21
class
DtSimComponentNetwork
;
22
23
#include "
vrfmodel/vrfmodelDefines.h
"
24
class
DT_DLL_vrfmodel
DtSystemSwitcherComponent
:
public
DtControllerComponent
25
{
26
public
:
27
29
DtSystemSwitcherComponent
(
const
DtString
& name,
DtVrfObject
* owner,
30
DtSimManager
* simManager,
DtComponentDescriptor
* desc = NULL,
31
DtReaderWriterRegistry
* parentRegistry = 0);
32
34
virtual
~
DtSystemSwitcherComponent
();
35
37
virtual
bool
init
();
38
41
virtual
DtString
type
()
const
;
42
43
virtual
void
tick
();
44
47
virtual
void
enable
();
48
51
virtual
void
disable
();
52
53
virtual
bool
transitionIsComplete()
const
;
54
55
virtual
void
onTransitionComplete();
56
57
public
:
58
59
static
void
setSwitchSystemsCallback(
DtSimMessage
* msg,
void
* usrData);
60
61
63
static
DtSimComponent
* creator(
const
DtString
& name,
DtVrfObject
* owner,
64
DtSimManager
* simManager,
DtComponentDescriptor
* desc,
65
DtReaderWriterRegistry
* parentRegistry);
66
67
protected
:
68
70
DtSystemSwitcherComponent
(
const
DtSystemSwitcherComponent
& orig);
71
73
DtSystemSwitcherComponent
&
operator=
(
const
DtSystemSwitcherComponent
& orig);
74
76
virtual
void
setRadio
(
DtSimRadio
* radio);
77
78
virtual
bool
createPSR();
79
82
virtual
void
addSetDataCallbacks();
83
86
void
removeSetDataCallbacks();
87
88
virtual
void
processSetSwitchSystems(
DtSimMessage
* msg);
89
92
virtual
bool
switchSystems();
93
96
void
enableComponentSystem(
DtComponentSystem
* activateSystem);
97
void
disableComponentSystem(
DtComponentSystem
* deactivateSystem);
98
void
enableSimComponent(
DtSimComponent
* simComponent);
99
void
disableSimComponent(
DtSimComponent
* simComponent);
101
104
virtual
bool
allowedToTransition()
const
;
105
106
protected
:
107
108
DtSimComponentNetwork
*
myComponentNetwork
;
109
DtComponentSystem
*
mySystemToDeactivate
;
110
DtComponentSystem
*
mySystemToActivate
;
111
112
DtSwitchSystemComponentPSR
*
myProcessState
;
113
114
bool
mySwitchingSystems
;
115
};
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
)