VR-Vantage API Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Tutorials
File List
File Members
include
vrfExtObjects
extEntSR.h
Go to the documentation of this file.
1
/*******************************************************************************
2
** Copyright (c) 2000 MAK Technologies, Inc.
3
** All rights reserved.
4
*******************************************************************************/
5
/*******************************************************************************
6
** $RCSfile: extEntSR.h,v $ $Revision: 1.13 $ $State: Exp $
7
*******************************************************************************/
8
9
#ifndef EXTENTSR_H
10
#define EXTENTSR_H
11
12
#include <vl/entitySR.h>
13
#include <
vrfExtObjects/vrfExtensions.h
>
14
15
#include <list>
16
17
// class DtExtEntityStateRepository:
18
//
19
// Instances of DtExtEntityStateRepository are
22
23
#include <
vrfExtObjects/vrfExtObjectsDefines.h
>
24
class
DT_DLL_vrfExtObjects
DtExtEntityStateRepository
:
public
DtEntityStateRepository
,
25
public
DtVrfExtensions
26
{
27
28
public
:
29
30
// default constructor
31
DtExtEntityStateRepository
();
32
33
// destructor
34
virtual
~
DtExtEntityStateRepository
();
35
36
// copy constructor
37
DtExtEntityStateRepository
(
const
DtExtEntityStateRepository
& orig);
38
39
// assignment operator
40
DtExtEntityStateRepository
&
operator=
(
const
DtExtEntityStateRepository
& orig);
41
42
// Return a copy/empty object of the same type as this.
43
virtual
DtStateRepository* clone(
bool
copy =
false
)
const
;
44
45
// Compares us against the supplied state repository and returns what's
46
// changed
47
virtual
int
compare(
const
DtExtEntityStateRepository
* rhs);
48
49
// Returns what has changed since the last time we called compare
50
virtual
int
compareToMostRecent();
51
52
// Compares articulated parts in the local copy to current values
53
// and returns a non-zero value if modified. If modified, copies current
54
// into last value
55
virtual
int
compareArtParts(
const
std::list<int>&);
56
57
// Compares each value that is valid, and, if any have changed, returns
58
// DtChanged_Other
59
virtual
int
compareArtParts(
const
DtArticulatedPart
* source,
const
DtArticulatedPart
* target);
60
61
// Returns true if our stashed location is different than our
62
// current location
63
virtual
bool
locationsDifferent(
bool
updateIfDifferent);
64
65
public
:
67
bool
needsVrfDataUpdate()
const
;
68
void
clearVrfDataNeedsUpdate();
69
71
bool
hasVrfObjectDataMessage()
const
;
72
76
void
setHasVrfObjectDataMessage(
bool
);
77
78
public
:
79
80
static
DtExtEntityStateRepository
* create();
81
82
protected
:
83
virtual
void
extensionModified
();
84
85
public
:
86
// Override to set myHasVrfObjectDataMessage to true
87
virtual
bool
setupFromVrfObjectData
(
const
DtIfVrfObjectData
& data);
88
89
protected
:
90
DtExtEntityStateRepository
*
myLastCopy
;
91
bool
myVrfObjectDataUpdated
;
92
93
// If true, a vrf object data message has been seen for this object. By default, this is false
94
bool
myHasVrfObjectDataMessage
;
95
};
96
97
inline
bool
DtExtEntityStateRepository::hasVrfObjectDataMessage
()
const
98
{
99
return
myHasVrfObjectDataMessage
;
100
}
101
102
inline
void
DtExtEntityStateRepository::setHasVrfObjectDataMessage
(
bool
b)
103
{
104
myHasVrfObjectDataMessage
= b;
105
}
106
107
inline
bool
DtExtEntityStateRepository::needsVrfDataUpdate
()
const
108
{
109
return
myVrfObjectDataUpdated
;
110
}
111
112
inline
void
DtExtEntityStateRepository::clearVrfDataNeedsUpdate
()
113
{
114
myVrfObjectDataUpdated
=
false
;
115
}
116
117
inline
void
DtExtEntityStateRepository::extensionModified
()
118
{
119
myVrfObjectDataUpdated
=
true
;
120
}
121
122
#endif
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (
www.mak.com
)