creaContours_lib
Main Page
Namespaces
Classes
Files
File List
File Members
OutlineGroup.h
Go to the documentation of this file.
1
/*# ---------------------------------------------------------------------
2
#
3
# Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image
4
# pour la Sant�)
5
# Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton
6
# Previous Authors : Laurent Guigues, Jean-Pierre Roux
7
# CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil
8
#
9
# This software is governed by the CeCILL-B license under French law and
10
# abiding by the rules of distribution of free software. You can use,
11
# modify and/ or redistribute the software under the terms of the CeCILL-B
12
# license as circulated by CEA, CNRS and INRIA at the following URL
13
# http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
14
# or in the file LICENSE.txt.
15
#
16
# As a counterpart to the access to the source code and rights to copy,
17
# modify and redistribute granted by the license, users are provided only
18
# with a limited warranty and the software's author, the holder of the
19
# economic rights, and the successive licensors have only limited
20
# liability.
21
#
22
# The fact that you are presently reading this means that you have had
23
# knowledge of the CeCILL-B license and that you accept its terms.
24
# ------------------------------------------------------------------------ */
25
26
#ifndef __OTULINE_GROUP__
27
#define __OTULINE_GROUP__
28
29
30
//------------------------------------------------------------------------------------------------------------
31
// Includes
32
//------------------------------------------------------------------------------------------------------------
33
#include <iostream>
34
#include <vector>
35
36
class
OutlineGroup
{
37
38
//------------------------------------------------------------------------------------------------------------
39
// Constructors & Destructors
40
//------------------------------------------------------------------------------------------------------------
41
public
:
42
43
/*
44
* Constructs an outline group with the given name
45
* @param theName Is the name for the group
46
* @param theGroupType Is the type for the group corresponding to one of the constants of this class
47
*/
48
OutlineGroup
(std::string theName,
int
theGroupType);
49
50
/*
51
* Destroyes the outline and its dependencies
52
*/
53
~ OutlineGroup
();
54
55
//------------------------------------------------------------------------------------------------------------
56
// Methods definition
57
//------------------------------------------------------------------------------------------------------------
58
59
/*
60
* Indicates if a given name of an outline is member of the group or not
61
* @param aKeyName Is the name of an outline to search for
62
*/
63
bool
isMemberOfGroup
(std::string aKeyName);
64
65
/*
66
* Removes an outline with the given name from the group
67
* @param theNameToRemove Is the name to remove from member name list
68
* @param allOcurrencies Indicates to errase all ocurrences
69
*/
70
void
removeOutline
(std::string theNameToRemove,
bool
allOcurrencies =
true
);
71
72
/*
73
* Adds an outline with the given name to the group members list
74
* @param theNameNw Is the name to add to the group
75
*/
76
void
addOutline
(std::string theNameNw);
77
78
/*
79
* Gets the name of the group
80
* @return name Is the name of the group
81
*/
82
std::string
getName
();
83
84
/*
85
* Sets the name of the group as the given one
86
* @param name Is the new name of the group
87
*/
88
void
setName
(std::string theNwName);
89
90
/*
91
* Gets the state of visiblility (true:visible) or not of the group
92
* @return visibleGroup Is the corresponding state
93
*/
94
bool
getIfVisibleGroup
();
95
96
/*
97
* Sets state of visible (true) or not of the with the given one
98
* @param theNwVisiblity Is the corresponding state
99
*/
100
void
setIfVisibleGroup
(
bool
theNwVisiblity);
101
102
/*
103
* Gets the state of static (true:static) or not of the group
104
* @return staticGroup Is the corresponding state
105
*/
106
bool
getIfStaticGroup
();
107
108
/*
109
* Sets state of static (true) or not of the with the given one
110
* @param theNwStatic Is the corresponding state
111
*/
112
void
setIfStaticGroup
(
bool
theNwStatic);
113
114
/*
115
* Gets the state of selection (true:selected) or not of the group
116
* @return selecetedGroup Is the corresponding state
117
*/
118
bool
getIfSelectedGroup
();
119
120
/*
121
* Sets state of visible (true) or not of the with the given one
122
* @param theNwSelected Is the corresponding state
123
*/
124
void
setIfSelectedGroup
(
bool
theNwSelected);
125
126
/*
127
* Gets the state of edition (true:editing) or not of the group
128
* @return editingGroup Is the corresponding state
129
*/
130
bool
getIfEditingGroup
();
131
132
/*
133
* Sets state of editing (true) or not of the with the given one
134
* @param theNwEditing Is the corresponding state
135
*/
136
void
setIfEditingGroup
(
bool
theNwEditing);
137
138
/*
139
* Gets the total count of outlines in the group
140
* @return totalCount Is the corresponding number of elements
141
*/
142
int
getGroupType
();
143
144
/*
145
* Sets the group type
146
* @param theType Is the corresponding new type to assign
147
*/
148
void
setGroupType
(
int
theType);
149
150
/*
151
* Gets the group type
152
* @return type Is the corresponding number of elements
153
*/
154
int
getOutlinesCount
();
155
156
/*
157
* Sets the total count of outlines in the group
158
* @param theNwVisiblity Is the corresponding state
159
*/
160
void
setIfEditingGroup
(
int
theTotal);
161
162
/*
163
* Adds an outline to the group as propagation type
164
* @param theOutlineKeyName Is the name used as identifier of the outline
165
*/
166
void
addOutline_PropagationType
(std::string theOutlineKeyName);
167
168
/*
169
* Adds an outline to the group as plane section type
170
* @param theOutlineKeyName Is the name used as identifier of the outline
171
*/
172
void
addOutline_PlaneSectionType
(std::string theOutlineKeyName);
173
174
/*
175
* Adds an outline to the group as overlaped type
176
* @param theOutlineKeyName Is the name used as identifier of the outline
177
*/
178
void
addOutline_OverlapedType
(std::string theOutlineKeyName);
179
180
/*
181
* Adds an outline to the group as strip type
182
* @param theOutlineKeyName Is the name used as identifier of the outline
183
*/
184
void
addOutline_StripType
(std::string theOutlineKeyName);
185
186
/*
187
* Adds an outline to the group as manual type
188
* @param theOutlineKeyName Is the name used as identifier of the outline
189
*/
190
void
addOutline_ManualType
(std::string theOutlineKeyName);
191
192
193
/*
194
* Gets the outlines of the group
195
* @return Returns the names of the outlines that belong to the group
196
*/
197
std::vector< std::string >
getGroupOutlinesNames
( );
198
199
//------------------------------------------------------------------------------------------------------------
200
// Attributes
201
//------------------------------------------------------------------------------------------------------------
202
203
private
:
204
205
bool
acceptsRepetedOutlines
;
206
207
/*
208
* Represents the name of the group
209
*/
210
std::string
name
;
211
212
/*
213
* Represents the state of visible for the outlines in the group
214
*/
215
bool
visibleGroup
;
216
217
/*
218
* Represents the state of selection for the outlines in the group
219
*/
220
bool
selectedGroup
;
221
222
/*
223
* Represents the state of edition for the outlines in the group
224
*/
225
bool
editingGroup
;
226
227
/*
228
* Represents the state of static for the outlines in the group
229
*/
230
bool
staticGroup
;
231
232
/*
233
* Represents the type of the group
234
*/
235
int
groupType
;
236
237
/*
238
* Represents the total elements count of the group
239
*/
240
int
totalCount
;
241
242
/*
243
* Represents the outlines of the group
244
*/
245
std::vector< std::string >
outlines_keyNames
;
246
247
//------------------------------------------------------------------------------------------------------------
248
// Constants
249
//------------------------------------------------------------------------------------------------------------
250
251
public
:
252
enum
253
{
254
PROPAGATION
= 0,
255
PLANE_SECTION
= 1,
256
OVERLAPED
= 2,
257
STRIP
= 3,
258
MANUAL_GROUP
= 4,
259
};
260
261
262
};
263
#endif
creatools_source
creaContours
lib
kernel_ManagerContour_NDimensions
OutlineGroup.h
Generated by
1.8.3.1