VR-Forces 4.2 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
examples
convertParamDb
extMtlParamDbReader.h
Go to the documentation of this file.
1
/*******************************************************************************
2
** Copyright (c) 2004 MAK Technologies, Inc.
3
** All rights reserved.
4
*******************************************************************************/
5
/*******************************************************************************
6
** $RCSfile: extMtlParamDbReader.h,v $ $Revision: 1.3 $ $State: Exp $
7
*******************************************************************************/
8
9
#ifndef DtExtMtlParameterDbReader_H_
10
#define DtExtMtlParameterDbReader_H_
11
12
#include "
vrfobjparam/mtlParamDbReader.h
"
13
#include "
extMtl/extDtcRead.h
"
14
#include "
vrfutil/rdrWritr.h
"
15
16
#include <map>
17
#include <string>
18
19
typedef
std::map<DtlObj*, std::string>
DtlObjStringMap
;
20
typedef
std::map<DtReaderWriter*, std::string>
DtReaderWriterCommentMap
;
21
22
class
DtReaderWriter
;
23
24
//class DtExtMtlParameterDbReader:
25
//
26
//Instances of DtExtMtlParameterDbReader extend DtMtlParameterDbReader to
27
//preserve comments when reading in a parameter database file.
28
29
class
DtExtMtlParameterDbReader
:
public
DtMtlParameterDbReader
30
{
31
public
:
32
33
//default constructor
34
DtExtMtlParameterDbReader
();
35
36
//destructor
37
virtual
~DtExtMtlParameterDbReader
();
38
39
//Returns object comment map (populated with entries from the most recent
40
//call to load().
41
virtual
const
DtReaderWriterCommentMap
&
readerWriterCommentMap
()
const
;
42
43
//Returns object comment map. Not const because it may need to be modified
44
//by the DtExtMtlParameterEntry (it has to be able to load itself on demand).
45
virtual
DtlObjStringMap
&
objectCommentMap
();
46
47
//Returns initial comment in the parameter database file. This comment
48
//is not part of the object comment map.
49
virtual
std::string
initialComment
()
const
;
50
51
public
:
52
53
static
void
postGetSelfCb
(
DtReaderWriter
* readerWriterObject, DtlObjPtr args,
54
void
* userData);
55
56
protected
:
57
58
//Load contents of legacy format parameter database file (pre-VR-Forces
59
//version 3.7 *.opd file) into DtVrfObjectParametersList object.
60
//Clears contents of object comment map before loading.
61
//The object comment map gets populated with DtlObj*/string pairs during
62
//the load.
63
virtual
bool
load
(
const
DtFilename& parameterDbFile,
64
DtVrfObjectParametersList
* objectParamList);
65
66
//copy constructor - not implemented
67
DtExtMtlParameterDbReader
(
const
DtExtMtlParameterDbReader
& orig);
68
69
//assignment operator - not implemented
70
DtExtMtlParameterDbReader
&
operator=
(
const
DtExtMtlParameterDbReader
& orig);
71
72
protected
:
73
74
std::string
myInitialComment
;
75
DtlObjStringMap
myObjectCommentMap
;
76
DtReaderWriterCommentMap
myReaderWriterCommentMap
;
77
};
78
79
#endif
Document ID: Generated on Sun Nov 24 19:49:21 EST 2013 from SVN revision 133924
Copyright © 2005-2013 VT MÄK. All Rights Reserved (
www.mak.com
)