File: ACE_Map_Manager_Adapter.3

package info (click to toggle)
ace 5.2.1-1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 26,856 kB
  • ctags: 18,677
  • sloc: cpp: 171,831; makefile: 48,840; sh: 10,192; perl: 8,582; exp: 787; yacc: 387; lex: 140; csh: 20
file content (327 lines) | stat: -rw-r--r-- 16,170 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
.TH ACE_Map_Manager_Adapter 3 "1 Dec 2001" "ACE" \" -*- nroff -*-
.ad l
.nh
.SH NAME
ACE_Map_Manager_Adapter \- Defines a map implementation. 
.SH SYNOPSIS
.br
.PP
\fC#include <Map_T.h>\fR
.PP
Inherits \fBACE_Map< KEY,VALUE >\fR.
.PP
.SS Public Types

.in +1c
.ti -1c
.RI "typedef \fBACE_Map_Manager_Iterator_Adapter\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE>, KEY, VALUE> \fBiterator_impl\fR"
.br
.ti -1c
.RI "typedef \fBACE_Map_Manager_Reverse_Iterator_Adapter\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE>, KEY, VALUE> \fBreverse_iterator_impl\fR"
.br
.ti -1c
.RI "typedef \fBACE_Map_Manager\fR<KEY, VALUE, \fBACE_Null_Mutex\fR> \fBimplementation\fR"
.br
.in -1c
.SS Public Methods

.in +1c
.ti -1c
.RI "\fBACE_Map_Manager_Adapter\fR (\fBACE_Allocator\fR *alloc = 0)"
.br
.RI "\fIInitialize with the .\fR"
.ti -1c
.RI "\fBACE_Map_Manager_Adapter\fR (size_t size, \fBACE_Allocator\fR *alloc = 0)"
.br
.RI "\fIInitialize with <size> entries. The <size> parameter is ignored by maps for which an initialize size does not make sense.\fR"
.ti -1c
.RI "virtual \fB~ACE_Map_Manager_Adapter\fR (void)"
.br
.RI "\fIClose down and release dynamically allocated resources.\fR"
.ti -1c
.RI "virtual int \fBopen\fR (size_t length = ACE_DEFAULT_MAP_SIZE, \fBACE_Allocator\fR *alloc = 0)"
.br
.RI "\fIInitialize a <Map> with size <length>.\fR"
.ti -1c
.RI "virtual int \fBclose\fR (void)"
.br
.RI "\fIClose down a <Map> and release dynamically allocated resources.\fR"
.ti -1c
.RI "virtual int \fBbind\fR (const KEY &key, const VALUE &value)"
.br
.ti -1c
.RI "virtual int \fBbind_modify_key\fR (const VALUE &value, KEY &key)"
.br
.ti -1c
.RI "virtual int \fBcreate_key\fR (KEY &key)"
.br
.ti -1c
.RI "virtual int \fBbind_create_key\fR (const VALUE &value, KEY &key)"
.br
.ti -1c
.RI "virtual int \fBbind_create_key\fR (const VALUE &value)"
.br
.ti -1c
.RI "virtual int \fBrecover_key\fR (const KEY &modified_key, KEY &original_key)"
.br
.RI "\fIRecovers the original key potentially modified by the map during <bind_modify_key>.\fR"
.ti -1c
.RI "virtual int \fBrebind\fR (const KEY &key, const VALUE &value)"
.br
.ti -1c
.RI "virtual int \fBrebind\fR (const KEY &key, const VALUE &value, VALUE &old_value)"
.br
.ti -1c
.RI "virtual int \fBrebind\fR (const KEY &key, const VALUE &value, KEY &old_key, VALUE &old_value)"
.br
.ti -1c
.RI "virtual int \fBtrybind\fR (const KEY &key, VALUE &value)"
.br
.ti -1c
.RI "virtual int \fBfind\fR (const KEY &key, VALUE &value)"
.br
.RI "\fILocate <value> associated with <key>.\fR"
.ti -1c
.RI "virtual int \fBfind\fR (const KEY &key)"
.br
.RI "\fIIs <key> in the map?\fR"
.ti -1c
.RI "virtual int \fBunbind\fR (const KEY &key)"
.br
.RI "\fIRemove <key> from the map.\fR"
.ti -1c
.RI "virtual int \fBunbind\fR (const KEY &key, VALUE &value)"
.br
.RI "\fIRemove <key> from the map, and return the <value> associated with <key>.\fR"
.ti -1c
.RI "virtual size_t \fBcurrent_size\fR (void) const"
.br
.RI "\fIReturn the current size of the map.\fR"
.ti -1c
.RI "virtual size_t \fBtotal_size\fR (void) const"
.br
.RI "\fIReturn the total size of the map.\fR"
.ti -1c
.RI "virtual void \fBdump\fR (void) const"
.br
.RI "\fIDump the state of an object.\fR"
.ti -1c
.RI "\fBACE_Map_Manager\fR<KEY, VALUE, \fBACE_Null_Mutex\fR>& \fBimpl\fR (void)"
.br
.RI "\fIAccessor to implementation object.\fR"
.ti -1c
.RI "KEY_GENERATOR& \fBkey_generator\fR (void)"
.br
.RI "\fIAccessor to key generator.\fR"
.in -1c
.SS Protected Methods

.in +1c
.ti -1c
.RI "virtual \fBACE_Iterator_Impl\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE> >* \fBbegin_impl\fR (void)"
.br
.RI "\fIReturn forward iterator.\fR"
.ti -1c
.RI "virtual \fBACE_Iterator_Impl\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE> >* \fBend_impl\fR (void)"
.br
.ti -1c
.RI "virtual \fBACE_Reverse_Iterator_Impl\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE> >* \fBrbegin_impl\fR (void)"
.br
.RI "\fIReturn reverse iterator.\fR"
.ti -1c
.RI "virtual \fBACE_Reverse_Iterator_Impl\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE> >* \fBrend_impl\fR (void)"
.br
.in -1c
.SS Protected Attributes

.in +1c
.ti -1c
.RI "\fBACE_Map_Manager\fR<KEY, VALUE, \fBACE_Null_Mutex\fR> \fBimplementation_\fR"
.br
.RI "\fIAll implementation details are forwarded to this class.\fR"
.ti -1c
.RI "KEY_GENERATOR \fBkey_generator_\fR"
.br
.RI "\fIFunctor class used for generating key.\fR"
.in -1c
.SS Private Methods

.in +1c
.ti -1c
.RI "void \fBoperator=\fR (const ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR> &)"
.br
.ti -1c
.RI "\fBACE_Map_Manager_Adapter\fR (const ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR> &)"
.br
.in -1c
.SH DETAILED DESCRIPTION
.PP 

.SS template<class KEY, class VALUE, class KEY_GENERATOR>  template class ACE_Map_Manager_Adapter
Defines a map implementation.
.PP
.PP
 Implementation to be provided by . 
.PP
.SH MEMBER TYPEDEF DOCUMENTATION
.PP 
.SS template<classKEY, classVALUE, classKEY_GENERATOR> typedef \fBACE_Map_Manager\fR<KEY, VALUE, \fBACE_Null_Mutex\fR> ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::implementation
.PP
.SS template<classKEY, classVALUE, classKEY_GENERATOR> typedef \fBACE_Map_Manager_Iterator_Adapter\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE>, KEY, VALUE> ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::iterator_impl
.PP
.SS template<classKEY, classVALUE, classKEY_GENERATOR> typedef \fBACE_Map_Manager_Reverse_Iterator_Adapter\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE>, KEY, VALUE> ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::reverse_iterator_impl
.PP
.SH CONSTRUCTOR & DESTRUCTOR DOCUMENTATION
.PP 
.SS template<classKEY, classVALUE, classKEY_GENERATOR> ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR> (\fBACE_Allocator\fR * alloc = 0)
.PP
Initialize with the .
.PP
.SS template<classKEY, classVALUE, classKEY_GENERATOR> ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR> (size_t size, \fBACE_Allocator\fR * alloc = 0)
.PP
Initialize with <size> entries. The <size> parameter is ignored by maps for which an initialize size does not make sense.
.PP
.SS template<classKEY, classVALUE, classKEY_GENERATOR> ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::~ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR> (void)\fC [virtual]\fR
.PP
Close down and release dynamically allocated resources.
.PP
.SS template<classKEY, classVALUE, classKEY_GENERATOR> ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR> (const ACE_Map_Manager_Adapter< KEY,VALUE,KEY_GENERATOR >&)\fC [private]\fR
.PP
.SH MEMBER FUNCTION DOCUMENTATION
.PP 
.SS template<classKEY, classVALUE, classKEY_GENERATOR> \fBACE_Iterator_Impl\fR< \fBACE_Reference_Pair\fR< const KEY,VALUE > >* ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::begin_impl (void)\fC [protected, virtual]\fR
.PP
Return forward iterator.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::bind (const KEY & key, const VALUE & value)\fC [virtual]\fR
.PP
Add <key>/<value> pair to the map. If <key> is already in the map then no changes are made and 1 is returned. Returns 0 on a successful addition. This function fails for maps that do not allow user specified keys. <key> is an "in" parameter. 
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::bind_create_key (const VALUE & value)\fC [virtual]\fR
.PP
Add <value> to the map. The user does not care about the corresponding key produced by the Map. For maps that do not naturally produce keys, the map adapters will use the <KEY_GENERATOR> class to produce a key. However, the users are responsible for not jeopardizing this key production scheme by using user specified keys with keys produced by the key generator. 
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::bind_create_key (const VALUE & value, KEY & key)\fC [virtual]\fR
.PP
Add <value> to the map, and the corresponding key produced by the Map is returned through <key> which is an "out" parameter. For maps that do not naturally produce keys, the map adapters will use the <KEY_GENERATOR> class to produce a key. However, the users are responsible for not jeopardizing this key production scheme by using user specified keys with keys produced by the key generator. 
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::bind_modify_key (const VALUE & value, KEY & key)\fC [virtual]\fR
.PP
Add <key>/<value> pair to the map. <key> is an "inout" parameter and maybe modified/extended by the map to add additional information. To recover original key, call the <recover_key> method. 
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::close (void)\fC [virtual]\fR
.PP
Close down a <Map> and release dynamically allocated resources.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::create_key (KEY & key)\fC [virtual]\fR
.PP
Produce a key and return it through <key> which is an "out" parameter. For maps that do not naturally produce keys, the map adapters will use the <KEY_GENERATOR> class to produce a key. However, the users are responsible for not jeopardizing this key production scheme by using user specified keys with keys produced by the key generator. 
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> size_t ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::current_size (void) const\fC [virtual]\fR
.PP
Return the current size of the map.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> void ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::dump (void) const\fC [virtual]\fR
.PP
Dump the state of an object.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> virtual \fBACE_Iterator_Impl\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE> >* ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::end_impl (void)\fC [protected, virtual]\fR
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::find (const KEY & key)\fC [virtual]\fR
.PP
Is <key> in the map?
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::find (const KEY & key, VALUE & value)\fC [virtual]\fR
.PP
Locate <value> associated with <key>.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> \fBACE_Map_Manager\fR< KEY,VALUE,\fBACE_Null_Mutex\fR >& ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::impl (void)
.PP
Accessor to implementation object.
.PP
.SS template<classKEY, classVALUE, classKEY_GENERATOR> KEY_GENERATOR & ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::key_generator (void)
.PP
Accessor to key generator.
.PP
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::open (size_t length = ACE_DEFAULT_MAP_SIZE, \fBACE_Allocator\fR * alloc = 0)\fC [virtual]\fR
.PP
Initialize a <Map> with size <length>.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> void ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::operator= (const ACE_Map_Manager_Adapter< KEY,VALUE,KEY_GENERATOR >&)\fC [private]\fR
.PP
.SS template<classKEY, classVALUE, classKEY_GENERATOR> \fBACE_Reverse_Iterator_Impl\fR< \fBACE_Reference_Pair\fR< const KEY,VALUE > >* ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::rbegin_impl (void)\fC [protected, virtual]\fR
.PP
Return reverse iterator.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::rebind (const KEY & key, const VALUE & value, KEY & old_key, VALUE & old_value)\fC [virtual]\fR
.PP
Reassociate <key> with <value>, storing the old key and value into the "out" parameters <old_key> and <old_value>. The function fails if <key> is not in the map for maps that do not allow user specified keys. However, for maps that allow user specified keys, if the key is not in the map, a new <key>/<value> association is created. 
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::rebind (const KEY & key, const VALUE & value, VALUE & old_value)\fC [virtual]\fR
.PP
Reassociate <key> with <value>, storing the old value into the "out" parameter <old_value>. The function fails if <key> is not in the map for maps that do not allow user specified keys. However, for maps that allow user specified keys, if the key is not in the map, a new <key>/<value> association is created. 
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::rebind (const KEY & key, const VALUE & value)\fC [virtual]\fR
.PP
Reassociate <key> with <value>. The function fails if <key> is not in the map for maps that do not allow user specified keys. However, for maps that allow user specified keys, if the key is not in the map, a new <key>/<value> association is created. 
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::recover_key (const KEY & modified_key, KEY & original_key)\fC [virtual]\fR
.PP
Recovers the original key potentially modified by the map during <bind_modify_key>.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> virtual \fBACE_Reverse_Iterator_Impl\fR<\fBACE_Reference_Pair\fR<const KEY, VALUE> >* ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::rend_impl (void)\fC [protected, virtual]\fR
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> size_t ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::total_size (void) const\fC [virtual]\fR
.PP
Return the total size of the map.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::trybind (const KEY & key, VALUE & value)\fC [virtual]\fR
.PP
Associate <key> with <value> if and only if <key> is not in the map. If <key> is already in the map, then the <value> parameter is overwritten with the existing value in the map. Returns 0 if a new <key>/<value> association is created. Returns 1 if an attempt is made to bind an existing entry. This function fails for maps that do not allow user specified keys. 
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::unbind (const KEY & key, VALUE & value)\fC [virtual]\fR
.PP
Remove <key> from the map, and return the <value> associated with <key>.
.PP
Reimplemented from \fBACE_Map\fR.
.SS template<classKEY, classVALUE, classKEY_GENERATOR> int ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::unbind (const KEY & key)\fC [virtual]\fR
.PP
Remove <key> from the map.
.PP
Reimplemented from \fBACE_Map\fR.
.SH MEMBER DATA DOCUMENTATION
.PP 
.SS template<classKEY, classVALUE, classKEY_GENERATOR> \fBACE_Map_Manager\fR< KEY,VALUE,\fBACE_Null_Mutex\fR > ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::implementation_\fC [protected]\fR
.PP
All implementation details are forwarded to this class.
.PP
.SS template<classKEY, classVALUE, classKEY_GENERATOR> KEY_GENERATOR ACE_Map_Manager_Adapter<KEY, VALUE, KEY_GENERATOR>::key_generator_\fC [protected]\fR
.PP
Functor class used for generating key.
.PP


.SH AUTHOR
.PP 
Generated automatically by Doxygen for ACE from the source code.