3 //=============================================================================
7 * @author Irfan Pyarali <irfan@cs.wustl.edu>
9 //=============================================================================
13 #include /**/ "ace/pre.h"
15 #include "ace/Map_Manager.h"
16 #include "ace/Hash_Map_Manager_T.h"
17 #include "ace/Active_Map_Manager.h"
18 #include "ace/Pair_T.h"
20 #if !defined (ACE_LACKS_PRAGMA_ONCE)
22 #endif /* ACE_LACKS_PRAGMA_ONCE */
24 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
27 * @class ACE_Noop_Key_Generator
29 * @brief Defines a noop key generator.
32 class ACE_Noop_Key_Generator
35 /// Functor method: generates a new key.
36 int operator () (T
&);
40 * @class ACE_Incremental_Key_Generator
42 * @brief Defines a simple incremental key generator.
44 * Generates a new key of type T by incrementing current
45 * value. Requirements on T are:
46 * - Constructor that accepts 0 in the constructor.
49 * Note that a primitive types such as u_long, int, etc., are
50 * suitable for this class.
53 class ACE_Incremental_Key_Generator
57 ACE_Incremental_Key_Generator () = default;
59 /// Functor method: generates a new key.
60 int operator () (T
&t
);
62 /// Returns the current value.
63 const T
& current_value () const;
71 * @class ACE_Iterator_Impl
73 * @brief Defines a abstract iterator.
75 * Implementation to be provided by subclasses.
78 class ACE_Iterator_Impl
82 virtual ~ACE_Iterator_Impl () = default;
85 virtual ACE_Iterator_Impl
<T
> *clone () const = 0;
88 virtual int compare (const ACE_Iterator_Impl
<T
> &rhs
) const = 0;
91 virtual T
dereference () const = 0;
94 virtual void plus_plus () = 0;
97 virtual void minus_minus () = 0;
101 * @class ACE_Reverse_Iterator_Impl
103 * @brief Defines a abstract reverse iterator.
105 * Implementation to be provided by subclasses.
108 class ACE_Reverse_Iterator_Impl
112 virtual ~ACE_Reverse_Iterator_Impl () = default;
115 virtual ACE_Reverse_Iterator_Impl
<T
> *clone () const = 0;
118 virtual int compare (const ACE_Reverse_Iterator_Impl
<T
> &rhs
) const = 0;
121 virtual T
dereference () const = 0;
124 virtual void plus_plus () = 0;
127 virtual void minus_minus () = 0;
131 * @class ACE_Iterator
133 * @brief Defines the iterator interface.
135 * Implementation to be provided by forwarding.
142 typedef T value_type
;
143 typedef ACE_Iterator_Impl
<T
> implementation
;
146 ACE_Iterator (ACE_Iterator_Impl
<T
> *impl
);
148 /// Copy constructor.
149 ACE_Iterator (const ACE_Iterator
<T
> &rhs
);
154 /// Assignment operator.
155 ACE_Iterator
<T
> &operator= (const ACE_Iterator
<T
> &rhs
);
157 /// Comparison operators.
158 bool operator== (const ACE_Iterator
<T
> &rhs
) const;
159 bool operator!= (const ACE_Iterator
<T
> &rhs
) const;
161 /// Dereference operator.
162 T
operator *() const;
165 ACE_Iterator
<T
> &operator++ ();
168 ACE_Iterator
<T
> operator++ (int);
171 ACE_Iterator
<T
> &operator-- ();
174 ACE_Iterator
<T
> operator-- (int);
176 /// Accessor to implementation object.
177 ACE_Iterator_Impl
<T
> &impl ();
180 /// Implementation pointer.
181 ACE_Iterator_Impl
<T
> *implementation_
;
185 * @class ACE_Reverse_Iterator
187 * @brief Defines the reverse iterator interface.
189 * Implementation to be provided by forwarding.
192 class ACE_Reverse_Iterator
196 typedef T value_type
;
197 typedef ACE_Reverse_Iterator_Impl
<T
> implementation
;
200 ACE_Reverse_Iterator (ACE_Reverse_Iterator_Impl
<T
> *impl
);
202 /// Copy constructor.
203 ACE_Reverse_Iterator (const ACE_Reverse_Iterator
<T
> &rhs
);
206 ~ACE_Reverse_Iterator ();
208 /// Assignment operator.
209 ACE_Reverse_Iterator
<T
> &operator= (const ACE_Reverse_Iterator
<T
> &rhs
);
212 * @name Comparison Operators
214 * The usual equality operators.
217 bool operator== (const ACE_Reverse_Iterator
<T
> &rhs
) const;
218 bool operator!= (const ACE_Reverse_Iterator
<T
> &rhs
) const;
221 /// Dereference operator.
222 T
operator *() const;
225 ACE_Reverse_Iterator
<T
> &operator++ ();
228 ACE_Reverse_Iterator
<T
> operator++ (int);
231 ACE_Reverse_Iterator
<T
> &operator-- ();
234 ACE_Reverse_Iterator
<T
> operator-- (int);
236 /// Accessor to implementation object.
237 ACE_Reverse_Iterator_Impl
<T
> &impl ();
240 /// Implementation pointer.
241 ACE_Reverse_Iterator_Impl
<T
> *implementation_
;
247 * @brief Defines a map interface.
249 * Implementation to be provided by subclasses.
251 template <class KEY
, class VALUE
>
260 typedef ACE_Reference_Pair
<const KEY
, VALUE
>
262 typedef ACE_Iterator
<value_type
>
264 typedef ACE_Reverse_Iterator
<value_type
>
266 typedef ACE_Iterator_Impl
<value_type
>
267 iterator_implementation
;
268 typedef ACE_Reverse_Iterator_Impl
<value_type
>
269 reverse_iterator_implementation
;
271 /// Close down and release dynamically allocated resources.
272 virtual ~ACE_Map () = default;
274 /// Initialize a map with size @a length.
275 virtual int open (size_t length
= ACE_DEFAULT_MAP_SIZE
,
276 ACE_Allocator
*alloc
= nullptr) = 0;
278 /// Close down a <Map> and release dynamically allocated resources.
279 virtual int close () = 0;
282 * Add @a key / @a value pair to the map. If @a key is already in the
283 * map then no changes are made and 1 is returned. Returns 0 on a
284 * successful addition. This function fails for maps that do not
285 * allow user specified keys. @a key is an "in" parameter.
287 virtual int bind (const KEY
&key
,
288 const VALUE
&value
) = 0;
291 * Add @a key / @a value pair to the map. @a key is an "inout" parameter
292 * and maybe modified/extended by the map to add additional
293 * information. To recover original key, call the <recover_key>
296 virtual int bind_modify_key (const VALUE
&value
,
300 * Produce a key and return it through @a key which is an "out"
301 * parameter. For maps that do not naturally produce keys, the map
302 * adapters will use the @c KEY_GENERATOR class to produce a key.
303 * However, the users are responsible for not jeopardizing this key
304 * production scheme by using user specified keys with keys produced
305 * by the key generator.
307 virtual int create_key (KEY
&key
) = 0;
310 * Add @a value to the map, and the corresponding key produced by the
311 * Map is returned through @a key which is an "out" parameter. For
312 * maps that do not naturally produce keys, the map adapters will
313 * use the @c KEY_GENERATOR class to produce a key. However, the
314 * users are responsible for not jeopardizing this key production
315 * scheme by using user specified keys with keys produced by the key
318 virtual int bind_create_key (const VALUE
&value
,
322 * Add @a value to the map. The user does not care about the
323 * corresponding key produced by the Map. For maps that do not
324 * naturally produce keys, the map adapters will use the
325 * @c KEY_GENERATOR class to produce a key. However, the users are
326 * responsible for not jeopardizing this key production scheme by
327 * using user specified keys with keys produced by the key
330 virtual int bind_create_key (const VALUE
&value
) = 0;
332 /// Recovers the original key potentially modified by the map during
333 /// <bind_modify_key>.
334 virtual int recover_key (const KEY
&modified_key
,
335 KEY
&original_key
) = 0;
338 * Reassociate @a key with @a value. The function fails if @a key is
339 * not in the map for maps that do not allow user specified keys.
340 * However, for maps that allow user specified keys, if the key is
341 * not in the map, a new @a key / @a value association is created.
343 virtual int rebind (const KEY
&key
,
344 const VALUE
&value
) = 0;
347 * Reassociate @a key with @a value, storing the old value into the
348 * "out" parameter @a old_value. The function fails if @a key is not
349 * in the map for maps that do not allow user specified keys.
350 * However, for maps that allow user specified keys, if the key is
351 * not in the map, a new @a key / @a value association is created.
353 virtual int rebind (const KEY
&key
,
355 VALUE
&old_value
) = 0;
358 * Reassociate @a key with @a value, storing the old key and value
359 * into the "out" parameters @a old_key and @a old_value. The
360 * function fails if @a key is not in the map for maps that do not
361 * allow user specified keys. However, for maps that allow user
362 * specified keys, if the key is not in the map, a new @a key / @a value
363 * association is created.
365 virtual int rebind (const KEY
&key
,
368 VALUE
&old_value
) = 0;
371 * Associate @a key with @a value if and only if @a key is not in the
372 * map. If @a key is already in the map, then the @a value parameter
373 * is overwritten with the existing value in the map. Returns 0 if a
374 * new @a key / @a value association is created. Returns 1 if an
375 * attempt is made to bind an existing entry. This function fails
376 * for maps that do not allow user specified keys.
378 virtual int trybind (const KEY
&key
,
381 /// Locate @a value associated with @a key.
382 virtual int find (const KEY
&key
,
385 /// Is @a key in the map?
386 virtual int find (const KEY
&key
) = 0;
388 /// Remove @a key from the map.
389 virtual int unbind (const KEY
&key
) = 0;
391 /// Remove @a key from the map, and return the @a value associated with
393 virtual int unbind (const KEY
&key
,
396 /// Return the current size of the map.
397 virtual size_t current_size () const = 0;
399 /// Return the total size of the map.
400 virtual size_t total_size () const = 0;
402 /// Dump the state of an object.
403 virtual void dump () const = 0;
405 // = STL styled iterator factory functions.
407 /// Return forward iterator.
411 /// Return reverse iterator.
412 reverse_iterator
rbegin ();
413 reverse_iterator
rend ();
416 // = Protected no-op constructor.
417 ACE_Map () = default;
419 /// Return forward iterator.
420 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *begin_impl () = 0;
421 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *end_impl () = 0;
423 /// Return reverse iterator.
424 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rbegin_impl () = 0;
425 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rend_impl () = 0;
428 // = Disallow these operations.
429 void operator= (const ACE_Map
<KEY
, VALUE
> &) = delete;
430 ACE_Map (const ACE_Map
<KEY
, VALUE
> &) = delete;
434 * @class ACE_Map_Impl_Iterator_Adapter
436 * @brief Defines a iterator implementation for the Map_Impl class.
438 * Implementation to be provided by <IMPLEMENTATION>.
440 template <class T
, class IMPLEMENTATION
, class ENTRY
>
441 class ACE_Map_Impl_Iterator_Adapter
: public ACE_Iterator_Impl
<T
>
445 typedef IMPLEMENTATION
449 ACE_Map_Impl_Iterator_Adapter (const IMPLEMENTATION
&impl
);
452 virtual ~ACE_Map_Impl_Iterator_Adapter () = default;
455 virtual ACE_Iterator_Impl
<T
> *clone () const;
458 virtual int compare (const ACE_Iterator_Impl
<T
> &rhs
) const;
461 virtual T
dereference () const;
464 virtual void plus_plus ();
467 virtual void minus_minus ();
469 /// Accessor to implementation object.
470 IMPLEMENTATION
&impl ();
473 /// All implementation details are forwarded to this class.
474 IMPLEMENTATION implementation_
;
478 * @class ACE_Map_Impl_Reverse_Iterator_Adapter
480 * @brief Defines a reverse iterator implementation for the Map_Impl class.
482 * Implementation to be provided by IMPLEMENTATION.
484 template <class T
, class IMPLEMENTATION
, class ENTRY
>
485 class ACE_Map_Impl_Reverse_Iterator_Adapter
: public ACE_Reverse_Iterator_Impl
<T
>
489 typedef IMPLEMENTATION
493 ACE_Map_Impl_Reverse_Iterator_Adapter (const IMPLEMENTATION
&impl
);
496 virtual ~ACE_Map_Impl_Reverse_Iterator_Adapter ();
499 virtual ACE_Reverse_Iterator_Impl
<T
> *clone () const;
502 virtual int compare (const ACE_Reverse_Iterator_Impl
<T
> &rhs
) const;
505 virtual T
dereference () const;
508 virtual void plus_plus ();
511 virtual void minus_minus ();
513 /// Accessor to implementation object.
514 IMPLEMENTATION
&impl ();
517 /// All implementation details are forwarded to this class.
518 IMPLEMENTATION implementation_
;
522 * @class ACE_Map_Impl
524 * @brief Defines a map implementation.
526 * Implementation to be provided by <IMPLEMENTATION>.
528 template <class KEY
, class VALUE
, class IMPLEMENTATION
, class ITERATOR
, class REVERSE_ITERATOR
, class ENTRY
>
529 class ACE_Map_Impl
: public ACE_Map
<KEY
, VALUE
>
533 typedef ACE_Map_Impl_Iterator_Adapter
<typename ACE_Map
<KEY
, VALUE
>::value_type
, ITERATOR
, ENTRY
>
535 typedef ACE_Map_Impl_Reverse_Iterator_Adapter
<typename ACE_Map
<KEY
, VALUE
>::value_type
, REVERSE_ITERATOR
, ENTRY
>
536 reverse_iterator_impl
;
538 typedef IMPLEMENTATION
541 /// Initialize with the ACE_DEFAULT_MAP_SIZE.
542 ACE_Map_Impl (ACE_Allocator
*alloc
= nullptr);
544 /// Initialize with @a size entries. The @a size parameter is ignored
545 /// by maps for which an initialize size does not make sense.
546 ACE_Map_Impl (size_t size
,
547 ACE_Allocator
*alloc
= nullptr);
549 /// Close down and release dynamically allocated resources.
550 virtual ~ACE_Map_Impl ();
552 /// Initialize a <Map> with size @a length.
553 virtual int open (size_t length
= ACE_DEFAULT_MAP_SIZE
,
554 ACE_Allocator
*alloc
= nullptr);
556 /// Close down a <Map> and release dynamically allocated resources.
557 virtual int close ();
560 * Add @a key / @a value pair to the map. If @a key is already in the
561 * map then no changes are made and 1 is returned. Returns 0 on a
562 * successful addition. This function fails for maps that do not
563 * allow user specified keys. @a key is an "in" parameter.
565 virtual int bind (const KEY
&key
,
569 * Add @a key / @a value pair to the map. @a key is an "inout" parameter
570 * and maybe modified/extended by the map to add additional
571 * information. To recover original key, call the <recover_key>
574 virtual int bind_modify_key (const VALUE
&value
,
578 * Produce a key and return it through @a key which is an "out"
579 * parameter. For maps that do not naturally produce keys, the map
580 * adapters will use the @c KEY_GENERATOR class to produce a key.
581 * However, the users are responsible for not jeopardizing this key
582 * production scheme by using user specified keys with keys produced
583 * by the key generator.
585 virtual int create_key (KEY
&key
);
588 * Add @a value to the map, and the corresponding key produced by the
589 * Map is returned through @a key which is an "out" parameter. For
590 * maps that do not naturally produce keys, the map adapters will
591 * use the @c KEY_GENERATOR class to produce a key. However, the
592 * users are responsible for not jeopardizing this key production
593 * scheme by using user specified keys with keys produced by the key
596 virtual int bind_create_key (const VALUE
&value
,
600 * Add @a value to the map. The user does not care about the
601 * corresponding key produced by the Map. For maps that do not
602 * naturally produce keys, the map adapters will use the
603 * @c KEY_GENERATOR class to produce a key. However, the users are
604 * responsible for not jeopardizing this key production scheme by
605 * using user specified keys with keys produced by the key
608 virtual int bind_create_key (const VALUE
&value
);
610 /// Recovers the original key potentially modified by the map during
611 /// <bind_modify_key>.
612 virtual int recover_key (const KEY
&modified_key
,
616 * Reassociate @a key with @a value. The function fails if @a key is
617 * not in the map for maps that do not allow user specified keys.
618 * However, for maps that allow user specified keys, if the key is
619 * not in the map, a new @a key / @a value association is created.
621 virtual int rebind (const KEY
&key
,
625 * Reassociate @a key with @a value, storing the old value into the
626 * "out" parameter @a old_value. The function fails if @a key is not
627 * in the map for maps that do not allow user specified keys.
628 * However, for maps that allow user specified keys, if the key is
629 * not in the map, a new @a key / @a value association is created.
631 virtual int rebind (const KEY
&key
,
636 * Reassociate @a key with @a value, storing the old key and value
637 * into the "out" parameters @a old_key and @a old_value. The
638 * function fails if @a key is not in the map for maps that do not
639 * allow user specified keys. However, for maps that allow user
640 * specified keys, if the key is not in the map, a new @a key / @a value
641 * association is created.
643 virtual int rebind (const KEY
&key
,
649 * Associate @a key with @a value if and only if @a key is not in the
650 * map. If @a key is already in the map, then the @a value parameter
651 * is overwritten with the existing value in the map. Returns 0 if a
652 * new @a key / @a value association is created. Returns 1 if an
653 * attempt is made to bind an existing entry. This function fails
654 * for maps that do not allow user specified keys.
656 virtual int trybind (const KEY
&key
,
659 /// Locate @a value associated with @a key.
660 virtual int find (const KEY
&key
,
663 /// Is @a key in the map?
664 virtual int find (const KEY
&key
);
666 /// Remove @a key from the map.
667 virtual int unbind (const KEY
&key
);
669 /// Remove @a key from the map, and return the @a value associated with
671 virtual int unbind (const KEY
&key
,
674 /// Return the current size of the map.
675 virtual size_t current_size () const;
677 /// Return the total size of the map.
678 virtual size_t total_size () const;
680 /// Dump the state of an object.
681 virtual void dump () const;
683 /// Accessor to implementation object.
684 IMPLEMENTATION
&impl ();
687 /// All implementation details are forwarded to this class.
688 IMPLEMENTATION implementation_
;
690 // = STL styled iterator factory functions.
692 /// Return forward iterator.
693 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *begin_impl ();
694 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *end_impl ();
696 /// Return reverse iterator.
697 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rbegin_impl ();
698 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rend_impl ();
701 // = Disallow these operations.
702 void operator= (const ACE_Map_Impl
<KEY
, VALUE
, IMPLEMENTATION
, ITERATOR
, REVERSE_ITERATOR
, ENTRY
> &) = delete;
703 ACE_Map_Impl (const ACE_Map_Impl
<KEY
, VALUE
, IMPLEMENTATION
, ITERATOR
, REVERSE_ITERATOR
, ENTRY
> &) = delete;
707 * @class ACE_Active_Map_Manager_Iterator_Adapter
709 * @brief Defines a iterator implementation for the Active_Map_Manager_Adapter.
711 * Implementation to be provided by ACE_Active_Map_Manager::iterator.
713 template <class T
, class VALUE
>
714 class ACE_Active_Map_Manager_Iterator_Adapter
: public ACE_Iterator_Impl
<T
>
718 typedef typename ACE_Active_Map_Manager
<VALUE
>::iterator
722 ACE_Active_Map_Manager_Iterator_Adapter (const ACE_Map_Iterator
<ACE_Active_Map_Manager_Key
, VALUE
, ACE_Null_Mutex
> &impl
);
725 virtual ~ACE_Active_Map_Manager_Iterator_Adapter ();
728 virtual ACE_Iterator_Impl
<T
> *clone () const;
731 virtual int compare (const ACE_Iterator_Impl
<T
> &rhs
) const;
734 virtual T
dereference () const;
737 virtual void plus_plus ();
740 virtual void minus_minus ();
742 /// Accessor to implementation object.
743 ACE_Map_Iterator
<ACE_Active_Map_Manager_Key
, VALUE
, ACE_Null_Mutex
> &impl ();
746 /// All implementation details are forwarded to this class.
747 ACE_Map_Iterator
<ACE_Active_Map_Manager_Key
, VALUE
, ACE_Null_Mutex
> implementation_
;
751 * @class ACE_Active_Map_Manager_Reverse_Iterator_Adapter
753 * @brief Defines a reverse iterator implementation for the Active_Map_Manager_Adapter.
755 * Implementation to be provided by ACE_Active_Map_Manager::reverse_iterator.
757 template <class T
, class VALUE
>
758 class ACE_Active_Map_Manager_Reverse_Iterator_Adapter
: public ACE_Reverse_Iterator_Impl
<T
>
762 typedef typename ACE_Active_Map_Manager
<VALUE
>::reverse_iterator
766 ACE_Active_Map_Manager_Reverse_Iterator_Adapter (const ACE_Map_Reverse_Iterator
<ACE_Active_Map_Manager_Key
, VALUE
, ACE_Null_Mutex
> &impl
);
769 virtual ~ACE_Active_Map_Manager_Reverse_Iterator_Adapter ();
772 virtual ACE_Reverse_Iterator_Impl
<T
> *clone () const;
775 virtual int compare (const ACE_Reverse_Iterator_Impl
<T
> &rhs
) const;
778 virtual T
dereference () const;
781 virtual void plus_plus ();
784 virtual void minus_minus ();
786 /// Accessor to implementation object.
787 ACE_Map_Reverse_Iterator
<ACE_Active_Map_Manager_Key
, VALUE
, ACE_Null_Mutex
> &impl ();
790 /// All implementation details are forwarded to this class.
791 ACE_Map_Reverse_Iterator
<ACE_Active_Map_Manager_Key
, VALUE
, ACE_Null_Mutex
> implementation_
;
795 * @class ACE_Active_Map_Manager_Adapter
797 * @brief Defines a map implementation.
799 * Implementation to be provided by <ACE_Active_Map_Manager>.
801 template <class KEY
, class VALUE
, class KEY_ADAPTER
>
802 class ACE_Active_Map_Manager_Adapter
: public ACE_Map
<KEY
, VALUE
>
806 typedef std::pair
<KEY
, VALUE
>
808 typedef ACE_Active_Map_Manager_Iterator_Adapter
<ACE_Reference_Pair
<const KEY
, VALUE
>, expanded_value
>
810 typedef ACE_Active_Map_Manager_Reverse_Iterator_Adapter
<ACE_Reference_Pair
<const KEY
, VALUE
>, expanded_value
>
811 reverse_iterator_impl
;
812 typedef ACE_Active_Map_Manager
<expanded_value
>
815 /// Initialize with the ACE_DEFAULT_MAP_SIZE.
816 ACE_Active_Map_Manager_Adapter (ACE_Allocator
*alloc
= nullptr);
818 /// Initialize with @a size entries. The @a size parameter is ignored
819 /// by maps for which an initialize size does not make sense.
820 ACE_Active_Map_Manager_Adapter (size_t size
,
821 ACE_Allocator
*alloc
= nullptr);
823 /// Close down and release dynamically allocated resources.
824 virtual ~ACE_Active_Map_Manager_Adapter ();
826 /// Initialize a Map with size @a length.
827 virtual int open (size_t length
= ACE_DEFAULT_MAP_SIZE
,
828 ACE_Allocator
*alloc
= nullptr);
830 /// Close down a Map and release dynamically allocated resources.
831 virtual int close ();
834 * Add @a key / @a value pair to the map. If @a key is already in the
835 * map then no changes are made and 1 is returned. Returns 0 on a
836 * successful addition. This function fails for maps that do not
837 * allow user specified keys. @a key is an "in" parameter.
839 virtual int bind (const KEY
&key
,
843 * Add @a key / @a value pair to the map. @a key is an "inout" parameter
844 * and maybe modified/extended by the map to add additional
845 * information. To recover original key, call the recover_key()
848 virtual int bind_modify_key (const VALUE
&value
, KEY
&key
);
851 * Produce a key and return it through @a key which is an "out"
852 * parameter. For maps that do not naturally produce keys, the map
853 * adapters will use the @c KEY_GENERATOR class to produce a key.
854 * However, the users are responsible for not jeopardizing this key
855 * production scheme by using user specified keys with keys produced
856 * by the key generator.
858 virtual int create_key (KEY
&key
);
861 * Add @a value to the map, and the corresponding key produced by the
862 * Map is returned through @a key which is an "out" parameter. For
863 * maps that do not naturally produce keys, the map adapters will
864 * use the @c KEY_GENERATOR class to produce a key. However, the
865 * users are responsible for not jeopardizing this key production
866 * scheme by using user specified keys with keys produced by the key
869 virtual int bind_create_key (const VALUE
&value
,
873 * Add @a value to the map. The user does not care about the
874 * corresponding key produced by the Map. For maps that do not
875 * naturally produce keys, the map adapters will use the
876 * @c KEY_GENERATOR class to produce a key. However, the users are
877 * responsible for not jeopardizing this key production scheme by
878 * using user specified keys with keys produced by the key
881 virtual int bind_create_key (const VALUE
&value
);
883 /// Recovers the original key potentially modified by the map during
884 /// bind_modify_key().
885 virtual int recover_key (const KEY
&modified_key
,
889 * Reassociate @a key with @a value. The function fails if @a key is
890 * not in the map for maps that do not allow user specified keys.
891 * However, for maps that allow user specified keys, if the key is
892 * not in the map, a new @a key / @a value association is created.
894 virtual int rebind (const KEY
&key
,
898 * Reassociate @a key with @a value, storing the old value into the
899 * "out" parameter @a old_value. The function fails if @a key is not
900 * in the map for maps that do not allow user specified keys.
901 * However, for maps that allow user specified keys, if the key is
902 * not in the map, a new @a key / @a value association is created.
904 virtual int rebind (const KEY
&key
,
909 * Reassociate @a key with @a value, storing the old key and value
910 * into the "out" parameters @a old_key and @a old_value. The
911 * function fails if @a key is not in the map for maps that do not
912 * allow user specified keys. However, for maps that allow user
913 * specified keys, if the key is not in the map, a new @a key / @a value
914 * association is created.
916 virtual int rebind (const KEY
&key
,
922 * Associate @a key with @a value if and only if @a key is not in the
923 * map. If @a key is already in the map, then the @a value parameter
924 * is overwritten with the existing value in the map. Returns 0 if a
925 * new @a key / @a value association is created. Returns 1 if an
926 * attempt is made to bind an existing entry. This function fails
927 * for maps that do not allow user specified keys.
929 virtual int trybind (const KEY
&key
,
932 /// Locate @a value associated with @a key.
933 virtual int find (const KEY
&key
,
936 /// Is @a key in the map?
937 virtual int find (const KEY
&key
);
939 /// Remove @a key from the map.
940 virtual int unbind (const KEY
&key
);
942 /// Remove @a key from the map, and return the @a value associated with
944 virtual int unbind (const KEY
&key
,
947 /// Return the current size of the map.
948 virtual size_t current_size () const;
950 /// Return the total size of the map.
951 virtual size_t total_size () const;
953 /// Dump the state of an object.
954 virtual void dump () const;
956 /// Accessor to implementation object.
957 ACE_Active_Map_Manager
<std::pair
<KEY
, VALUE
> > &impl ();
959 /// Accessor to key adapter.
960 KEY_ADAPTER
&key_adapter ();
964 virtual int find (const KEY
&key
,
965 expanded_value
*&internal_value
);
968 virtual int unbind (const KEY
&key
,
969 expanded_value
*&internal_value
);
971 /// All implementation details are forwarded to this class.
972 ACE_Active_Map_Manager
<std::pair
<KEY
, VALUE
> > implementation_
;
974 /// Adapts between the user key and the Active_Map_Manager_Key.
975 KEY_ADAPTER key_adapter_
;
977 // = STL styled iterator factory functions.
979 /// Return forward iterator.
980 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *begin_impl ();
981 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *end_impl ();
983 /// Return reverse iterator.
984 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rbegin_impl ();
985 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rend_impl ();
988 // = Disallow these operations.
989 void operator= (const ACE_Active_Map_Manager_Adapter
<KEY
, VALUE
, KEY_ADAPTER
> &) = delete;
990 ACE_Active_Map_Manager_Adapter (const ACE_Active_Map_Manager_Adapter
<KEY
, VALUE
, KEY_ADAPTER
> &) = delete;
994 * @class ACE_Hash_Map_Manager_Ex_Iterator_Adapter
996 * @brief Defines a iterator implementation for the Hash_Map_Manager_Adapter.
998 * Implementation to be provided by ACE_Hash_Map_Manager_Ex::iterator.
1000 template <class T
, class KEY
, class VALUE
, class HASH_KEY
, class COMPARE_KEYS
>
1001 class ACE_Hash_Map_Manager_Ex_Iterator_Adapter
: public ACE_Iterator_Impl
<T
>
1005 typedef typename ACE_Hash_Map_Manager_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
>::iterator
1009 ACE_Hash_Map_Manager_Ex_Iterator_Adapter (const ACE_Hash_Map_Iterator_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
> &impl
);
1012 virtual ~ACE_Hash_Map_Manager_Ex_Iterator_Adapter ();
1015 virtual ACE_Iterator_Impl
<T
> *clone () const;
1018 virtual int compare (const ACE_Iterator_Impl
<T
> &rhs
) const;
1021 virtual T
dereference () const;
1024 virtual void plus_plus ();
1027 virtual void minus_minus ();
1029 /// Accessor to implementation object.
1030 ACE_Hash_Map_Iterator_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
> &impl ();
1033 /// All implementation details are forwarded to this class.
1034 ACE_Hash_Map_Iterator_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
> implementation_
;
1038 * @class ACE_Hash_Map_Manager_Ex_Reverse_Iterator_Adapter
1040 * @brief Defines a reverse iterator implementation for the Hash_Map_Manager_Adapter.
1042 * Implementation to be provided by ACE_Hash_Map_Manager_Ex::reverse_iterator.
1044 template <class T
, class KEY
, class VALUE
, class HASH_KEY
, class COMPARE_KEYS
>
1045 class ACE_Hash_Map_Manager_Ex_Reverse_Iterator_Adapter
: public ACE_Reverse_Iterator_Impl
<T
>
1049 typedef typename ACE_Hash_Map_Manager_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
>::reverse_iterator
1053 ACE_Hash_Map_Manager_Ex_Reverse_Iterator_Adapter (const ACE_Hash_Map_Reverse_Iterator_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
> &impl
);
1056 virtual ~ACE_Hash_Map_Manager_Ex_Reverse_Iterator_Adapter ();
1059 virtual ACE_Reverse_Iterator_Impl
<T
> *clone () const;
1062 virtual int compare (const ACE_Reverse_Iterator_Impl
<T
> &rhs
) const;
1065 virtual T
dereference () const;
1068 virtual void plus_plus ();
1071 virtual void minus_minus ();
1073 /// Accessor to implementation object.
1074 ACE_Hash_Map_Reverse_Iterator_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
> &impl ();
1077 /// All implementation details are forwarded to this class.
1078 ACE_Hash_Map_Reverse_Iterator_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
> implementation_
;
1082 * @class ACE_Hash_Map_Manager_Ex_Adapter
1084 * @brief Defines a map implementation.
1086 * Implementation to be provided by ACE_Hash_Map_Manager_Ex.
1088 template <class KEY
, class VALUE
, class HASH_KEY
, class COMPARE_KEYS
, class KEY_GENERATOR
>
1089 class ACE_Hash_Map_Manager_Ex_Adapter
: public ACE_Map
<KEY
, VALUE
>
1093 typedef ACE_Hash_Map_Manager_Ex_Iterator_Adapter
<ACE_Reference_Pair
<const KEY
, VALUE
>, KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
>
1095 typedef ACE_Hash_Map_Manager_Ex_Reverse_Iterator_Adapter
<ACE_Reference_Pair
<const KEY
, VALUE
>, KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
>
1096 reverse_iterator_impl
;
1097 typedef ACE_Hash_Map_Manager_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
>
1100 /// Initialize with the ACE_DEFAULT_MAP_SIZE.
1101 ACE_Hash_Map_Manager_Ex_Adapter (ACE_Allocator
*alloc
= nullptr);
1103 /// Initialize with @a size entries. The @a size parameter is ignored
1104 /// by maps for which an initialize size does not make sense.
1105 ACE_Hash_Map_Manager_Ex_Adapter (size_t size
,
1106 ACE_Allocator
*alloc
= nullptr);
1108 /// Close down and release dynamically allocated resources.
1109 virtual ~ACE_Hash_Map_Manager_Ex_Adapter ();
1111 /// Initialize a Map with size @a length.
1112 virtual int open (size_t length
= ACE_DEFAULT_MAP_SIZE
,
1113 ACE_Allocator
*alloc
= nullptr);
1115 /// Close down a Map and release dynamically allocated resources.
1116 virtual int close ();
1119 * Add @a key / @a value pair to the map. If @a key is already in the
1120 * map then no changes are made and 1 is returned. Returns 0 on a
1121 * successful addition. This function fails for maps that do not
1122 * allow user specified keys. @a key is an "in" parameter.
1124 virtual int bind (const KEY
&key
,
1125 const VALUE
&value
);
1128 * Add @a key / @a value pair to the map. @a key is an "inout" parameter
1129 * and maybe modified/extended by the map to add additional
1130 * information. To recover original key, call the <recover_key>
1133 virtual int bind_modify_key (const VALUE
&value
,
1137 * Produce a key and return it through @a key which is an "out"
1138 * parameter. For maps that do not naturally produce keys, the map
1139 * adapters will use the @c KEY_GENERATOR class to produce a key.
1140 * However, the users are responsible for not jeopardizing this key
1141 * production scheme by using user specified keys with keys produced
1142 * by the key generator.
1144 virtual int create_key (KEY
&key
);
1147 * Add @a value to the map, and the corresponding key produced by the
1148 * Map is returned through @a key which is an "out" parameter. For
1149 * maps that do not naturally produce keys, the map adapters will
1150 * use the @c KEY_GENERATOR class to produce a key. However, the
1151 * users are responsible for not jeopardizing this key production
1152 * scheme by using user specified keys with keys produced by the key
1155 virtual int bind_create_key (const VALUE
&value
,
1159 * Add @a value to the map. The user does not care about the
1160 * corresponding key produced by the Map. For maps that do not
1161 * naturally produce keys, the map adapters will use the
1162 * @c KEY_GENERATOR class to produce a key. However, the users are
1163 * responsible for not jeopardizing this key production scheme by
1164 * using user specified keys with keys produced by the key
1167 virtual int bind_create_key (const VALUE
&value
);
1169 /// Recovers the original key potentially modified by the map during
1170 /// bind_modify_key().
1171 virtual int recover_key (const KEY
&modified_key
,
1175 * Reassociate @a key with @a value. The function fails if @a key is
1176 * not in the map for maps that do not allow user specified keys.
1177 * However, for maps that allow user specified keys, if the key is
1178 * not in the map, a new @a key / @a value association is created.
1180 virtual int rebind (const KEY
&key
,
1181 const VALUE
&value
);
1184 * Reassociate @a key with @a value, storing the old value into the
1185 * "out" parameter @a old_value. The function fails if @a key is not
1186 * in the map for maps that do not allow user specified keys.
1187 * However, for maps that allow user specified keys, if the key is
1188 * not in the map, a new @a key / @a value association is created.
1190 virtual int rebind (const KEY
&key
,
1195 * Reassociate @a key with @a value, storing the old key and value
1196 * into the "out" parameters @a old_key and @a old_value. The
1197 * function fails if @a key is not in the map for maps that do not
1198 * allow user specified keys. However, for maps that allow user
1199 * specified keys, if the key is not in the map, a new @a key / @a value
1200 * association is created.
1202 virtual int rebind (const KEY
&key
,
1208 * Associate @a key with @a value if and only if @a key is not in the
1209 * map. If @a key is already in the map, then the @a value parameter
1210 * is overwritten with the existing value in the map. Returns 0 if a
1211 * new @a key / @a value association is created. Returns 1 if an
1212 * attempt is made to bind an existing entry. This function fails
1213 * for maps that do not allow user specified keys.
1215 virtual int trybind (const KEY
&key
,
1218 /// Locate @a value associated with @a key.
1219 virtual int find (const KEY
&key
,
1222 /// Is @a key in the map?
1223 virtual int find (const KEY
&key
);
1225 /// Remove @a key from the map.
1226 virtual int unbind (const KEY
&key
);
1228 /// Remove @a key from the map, and return the @a value associated with
1230 virtual int unbind (const KEY
&key
,
1233 /// Return the current size of the map.
1234 virtual size_t current_size () const;
1236 /// Return the total size of the map.
1237 virtual size_t total_size () const;
1239 /// Dump the state of an object.
1240 virtual void dump () const;
1242 /// Accessor to implementation object.
1243 ACE_Hash_Map_Manager_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
> &impl ();
1245 /// Accessor to key generator.
1246 KEY_GENERATOR
&key_generator ();
1249 /// All implementation details are forwarded to this class.
1250 ACE_Hash_Map_Manager_Ex
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, ACE_Null_Mutex
> implementation_
;
1252 /// Functor class used for generating key.
1253 KEY_GENERATOR key_generator_
;
1255 // = STL styled iterator factory functions.
1257 /// Return forward iterator.
1258 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *begin_impl ();
1259 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *end_impl ();
1261 /// Return reverse iterator.
1262 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rbegin_impl ();
1263 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rend_impl ();
1266 // = Disallow these operations.
1267 void operator= (const ACE_Hash_Map_Manager_Ex_Adapter
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, KEY_GENERATOR
> &) = delete;
1268 ACE_Hash_Map_Manager_Ex_Adapter (const ACE_Hash_Map_Manager_Ex_Adapter
<KEY
, VALUE
, HASH_KEY
, COMPARE_KEYS
, KEY_GENERATOR
> &) = delete;
1272 * @class ACE_Map_Manager_Iterator_Adapter
1274 * @brief Defines a iterator implementation for the Map_Manager_Adapter.
1276 * Implementation to be provided by ACE_Map_Manager::iterator.
1278 template <class T
, class KEY
, class VALUE
>
1279 class ACE_Map_Manager_Iterator_Adapter
: public ACE_Iterator_Impl
<T
>
1283 typedef typename ACE_Map_Manager
<KEY
, VALUE
, ACE_Null_Mutex
>::iterator
1287 ACE_Map_Manager_Iterator_Adapter (const ACE_Map_Iterator
<KEY
, VALUE
, ACE_Null_Mutex
> &impl
);
1290 virtual ~ACE_Map_Manager_Iterator_Adapter ();
1293 virtual ACE_Iterator_Impl
<T
> *clone () const;
1296 virtual int compare (const ACE_Iterator_Impl
<T
> &rhs
) const;
1299 virtual T
dereference () const;
1302 virtual void plus_plus ();
1305 virtual void minus_minus ();
1307 /// Accessor to implementation object.
1308 ACE_Map_Iterator
<KEY
, VALUE
, ACE_Null_Mutex
> &impl ();
1311 /// All implementation details are forwarded to this class.
1312 ACE_Map_Iterator
<KEY
, VALUE
, ACE_Null_Mutex
> implementation_
;
1316 * @class ACE_Map_Manager_Reverse_Iterator_Adapter
1318 * @brief Defines a reverse iterator implementation for the Map Manager.
1320 * Implementation to be provided by ACE_Map_Manager::reverse_iterator.
1322 template <class T
, class KEY
, class VALUE
>
1323 class ACE_Map_Manager_Reverse_Iterator_Adapter
: public ACE_Reverse_Iterator_Impl
<T
>
1327 typedef typename ACE_Map_Manager
<KEY
, VALUE
, ACE_Null_Mutex
>::reverse_iterator
1331 ACE_Map_Manager_Reverse_Iterator_Adapter (const ACE_Map_Reverse_Iterator
<KEY
, VALUE
, ACE_Null_Mutex
> &impl
);
1334 virtual ~ACE_Map_Manager_Reverse_Iterator_Adapter ();
1337 virtual ACE_Reverse_Iterator_Impl
<T
> *clone () const;
1340 virtual int compare (const ACE_Reverse_Iterator_Impl
<T
> &rhs
) const;
1343 virtual T
dereference () const;
1346 virtual void plus_plus ();
1349 virtual void minus_minus ();
1351 /// Accessor to implementation object.
1352 ACE_Map_Reverse_Iterator
<KEY
, VALUE
, ACE_Null_Mutex
> &impl ();
1355 /// All implementation details are forwarded to this class.
1356 ACE_Map_Reverse_Iterator
<KEY
, VALUE
, ACE_Null_Mutex
> implementation_
;
1360 * @class ACE_Map_Manager_Adapter
1362 * @brief Defines a map implementation.
1364 * Implementation to be provided by ACE_Map_Manager.
1366 template <class KEY
, class VALUE
, class KEY_GENERATOR
>
1367 class ACE_Map_Manager_Adapter
: public ACE_Map
<KEY
, VALUE
>
1371 typedef ACE_Map_Manager_Iterator_Adapter
<ACE_Reference_Pair
<const KEY
, VALUE
>, KEY
, VALUE
>
1373 typedef ACE_Map_Manager_Reverse_Iterator_Adapter
<ACE_Reference_Pair
<const KEY
, VALUE
>, KEY
, VALUE
>
1374 reverse_iterator_impl
;
1375 typedef ACE_Map_Manager
<KEY
, VALUE
, ACE_Null_Mutex
>
1378 /// Initialize with the ACE_DEFAULT_MAP_SIZE.
1379 ACE_Map_Manager_Adapter (ACE_Allocator
*alloc
= nullptr);
1381 /// Initialize with @a size entries. The @a size parameter is ignored
1382 /// by maps for which an initialize size does not make sense.
1383 ACE_Map_Manager_Adapter (size_t size
,
1384 ACE_Allocator
*alloc
= nullptr);
1386 /// Close down and release dynamically allocated resources.
1387 virtual ~ACE_Map_Manager_Adapter ();
1389 /// Initialize a <Map> with size @a length.
1390 virtual int open (size_t length
= ACE_DEFAULT_MAP_SIZE
,
1391 ACE_Allocator
*alloc
= nullptr);
1393 /// Close down a <Map> and release dynamically allocated resources.
1394 virtual int close ();
1397 * Add @a key / @a value pair to the map. If @a key is already in the
1398 * map then no changes are made and 1 is returned. Returns 0 on a
1399 * successful addition. This function fails for maps that do not
1400 * allow user specified keys. @a key is an "in" parameter.
1402 virtual int bind (const KEY
&key
,
1403 const VALUE
&value
);
1406 * Add @a key / @a value pair to the map. @a key is an "inout" parameter
1407 * and maybe modified/extended by the map to add additional
1408 * information. To recover original key, call the <recover_key>
1411 virtual int bind_modify_key (const VALUE
&value
,
1415 * Produce a key and return it through @a key which is an "out"
1416 * parameter. For maps that do not naturally produce keys, the map
1417 * adapters will use the @c KEY_GENERATOR class to produce a key.
1418 * However, the users are responsible for not jeopardizing this key
1419 * production scheme by using user specified keys with keys produced
1420 * by the key generator.
1422 virtual int create_key (KEY
&key
);
1425 * Add @a value to the map, and the corresponding key produced by the
1426 * Map is returned through @a key which is an "out" parameter. For
1427 * maps that do not naturally produce keys, the map adapters will
1428 * use the @c KEY_GENERATOR class to produce a key. However, the
1429 * users are responsible for not jeopardizing this key production
1430 * scheme by using user specified keys with keys produced by the key
1433 virtual int bind_create_key (const VALUE
&value
,
1437 * Add @a value to the map. The user does not care about the
1438 * corresponding key produced by the Map. For maps that do not
1439 * naturally produce keys, the map adapters will use the
1440 * @c KEY_GENERATOR class to produce a key. However, the users are
1441 * responsible for not jeopardizing this key production scheme by
1442 * using user specified keys with keys produced by the key
1445 virtual int bind_create_key (const VALUE
&value
);
1447 /// Recovers the original key potentially modified by the map during
1448 /// <bind_modify_key>.
1449 virtual int recover_key (const KEY
&modified_key
,
1453 * Reassociate @a key with @a value. The function fails if @a key is
1454 * not in the map for maps that do not allow user specified keys.
1455 * However, for maps that allow user specified keys, if the key is
1456 * not in the map, a new @a key / @a value association is created.
1458 virtual int rebind (const KEY
&key
,
1459 const VALUE
&value
);
1462 * Reassociate @a key with @a value, storing the old value into the
1463 * "out" parameter @a old_value. The function fails if @a key is not
1464 * in the map for maps that do not allow user specified keys.
1465 * However, for maps that allow user specified keys, if the key is
1466 * not in the map, a new @a key / @a value association is created.
1468 virtual int rebind (const KEY
&key
,
1473 * Reassociate @a key with @a value, storing the old key and value
1474 * into the "out" parameters @a old_key and @a old_value. The
1475 * function fails if @a key is not in the map for maps that do not
1476 * allow user specified keys. However, for maps that allow user
1477 * specified keys, if the key is not in the map, a new @a key / @a value
1478 * association is created.
1480 virtual int rebind (const KEY
&key
,
1486 * Associate @a key with @a value if and only if @a key is not in the
1487 * map. If @a key is already in the map, then the @a value parameter
1488 * is overwritten with the existing value in the map. Returns 0 if a
1489 * new @a key / @a value association is created. Returns 1 if an
1490 * attempt is made to bind an existing entry. This function fails
1491 * for maps that do not allow user specified keys.
1493 virtual int trybind (const KEY
&key
,
1496 /// Locate @a value associated with @a key.
1497 virtual int find (const KEY
&key
,
1500 /// Is @a key in the map?
1501 virtual int find (const KEY
&key
);
1503 /// Remove @a key from the map.
1504 virtual int unbind (const KEY
&key
);
1506 /// Remove @a key from the map, and return the @a value associated with
1508 virtual int unbind (const KEY
&key
,
1511 /// Return the current size of the map.
1512 virtual size_t current_size () const;
1514 /// Return the total size of the map.
1515 virtual size_t total_size () const;
1517 /// Dump the state of an object.
1518 virtual void dump () const;
1520 /// Accessor to implementation object.
1521 ACE_Map_Manager
<KEY
, VALUE
, ACE_Null_Mutex
> &impl ();
1523 /// Accessor to key generator.
1524 KEY_GENERATOR
&key_generator ();
1527 /// All implementation details are forwarded to this class.
1528 ACE_Map_Manager
<KEY
, VALUE
, ACE_Null_Mutex
> implementation_
;
1530 /// Functor class used for generating key.
1531 KEY_GENERATOR key_generator_
;
1533 // = STL styled iterator factory functions.
1535 /// Return forward iterator.
1536 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *begin_impl ();
1537 virtual ACE_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *end_impl ();
1539 /// Return reverse iterator.
1540 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rbegin_impl ();
1541 virtual ACE_Reverse_Iterator_Impl
<ACE_Reference_Pair
<const KEY
, VALUE
> > *rend_impl ();
1544 // = Disallow these operations.
1545 void operator= (const ACE_Map_Manager_Adapter
<KEY
, VALUE
, KEY_GENERATOR
> &) = delete;
1546 ACE_Map_Manager_Adapter (const ACE_Map_Manager_Adapter
<KEY
, VALUE
, KEY_GENERATOR
> &) = delete;
1549 ACE_END_VERSIONED_NAMESPACE_DECL
1551 #if defined (__ACE_INLINE__)
1552 #include "ace/Map_T.inl"
1553 #endif /* __ACE_INLINE__ */
1555 #include "ace/Map_T.cpp"
1557 #include /**/ "ace/post.h"
1558 #endif /* ACE_MAP_T_H */