VR-Forces 4.2 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
include
vrfobjparam
modelSet.h
Go to the documentation of this file.
1
/*******************************************************************************
2
** Copyright (c) 2013 MAK Technologies, Inc.
3
** All rights reserved.
4
*******************************************************************************/
5
8
9
#pragma once
10
13
14
#include "
vrfutil/rwList.h
"
15
#include "
vrfutil/rwInt.h
"
16
#include <vlutil/vlString.h>
17
#include "
vrfobjparam/vrfobjparamDefines.h
"
18
19
class
DtModelSetEntry
;
20
class
DtFilename;
21
class
DtObjectType;
22
23
#define LATEST_MODEL_SET_VERSION 1
24
25
class
DT_DLL_vrfobjparam
DtModelSet
:
public
DtRwList
26
{
27
public
:
28
30
DtModelSet
();
31
32
DtModelSet
(
const
DtString
& name,
DtReaderWriterRegistry
*
33
parentRegistry = NULL);
34
36
virtual
~
DtModelSet
();
37
39
DtModelSet
(
const
DtModelSet
& orig,
40
DtReaderWriterRegistry
* parentRegistry = NULL);
41
43
DtModelSet
&
operator=
(
const
DtModelSet
& orig);
44
45
virtual
bool
load(
const
DtFilename&);
46
virtual
bool
save(
const
DtFilename&);
47
48
virtual
DtModelSetEntry
* find(
const
DtObjectType&)
const
;
49
virtual
DtModelSetEntry
* findMatchingPattern(
const
DtObjectType&)
const
;
50
virtual
DtModelSetEntry
* findByUniqueID(
const
DtString
&)
const
;
51
virtual
DtModelSetEntry
* findByLabel(
const
DtString
&)
const
;
52
53
virtual
void
setComment(
const
DtString
&);
54
virtual
const
DtString
comment()
const
;
55
56
static
DtModelSet
* create(
const
DtString
&,
DtReaderWriterRegistry
*
const
parentRegistry = NULL);
57
59
DtObjectType objectTypeFor(
const
DtString
& label)
const
;
60
62
virtual
DtModelSetEntry
* addModel(
DtModelSetEntry
*);
63
64
virtual
void
emptyList();
65
68
virtual
void
entitiesForObjectType(
const
DtObjectType& o, std::list<DtString>& list)
const
;
69
71
72
int
version()
const
;
73
75
virtual
DtString
createUniqueID(
const
DtModelSetEntry
*)
const
;
76
virtual
DtString
createUniqueID(
const
DtString
&)
const
;
77
79
virtual
DtModelSetEntry
* removeModel(
const
DtObjectType&);
80
83
virtual
void
loadFromDataFiles(
const
std::string& directory);
84
85
protected
:
88
virtual
DtlObjPtr
getData
(DtlObjPtr args,
const
DtFilename& searchPath,
89
const
DtVariableBindingsList
& variableBindings);
90
92
void
copyList(
const
DtModelSet
& orig);
94
void
clear();
95
virtual
void
writeSelf
(FILE* fp,
int
i,
bool
writeUnspecified,
96
const
DtFilename& path);
97
98
protected
:
99
DtString
myFilename
;
100
DtString
myComment
;
101
DtRwInt
myVersion
;
102
};
103
104
105
inline
int
DtModelSet::version
()
const
106
{
107
return
myVersion
;
108
}
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
)